public int getRootId() { if ( super.isActiveTxn() ) return super.getDataState().getRoot() ; else return rootIdx ; }
@Override protected void _commit(TxnId txnId, BptTxnState state) { if ( isWriteTxn() ) { rootIdx = state.getRoot() ; stateManager.sync(); } }
public int getRootId() { if ( super.isActiveTxn() ) return super.getDataState().getRoot() ; else return rootIdx ; }
@Override protected void _commit(TxnId txnId, BptTxnState state) { if ( isWriteTxn() ) { rootIdx = state.getRoot() ; stateManager.sync(); } }
private BPTreeNode getRootRead() { if ( isTransactional() ) { super.checkTxn() ; int rootId = super.getDataState().getRoot() ; return nodeManager.getRead(rootId, BPlusTreeParams.RootParent) ; } return nodeManager.getRead(rootIdx, BPlusTreeParams.RootParent) ; }
private BPTreeNode getRootWrite() { if ( isTransactional() ) { super.checkWriteTxn() ; int rootId = super.getDataState().getRoot() ; return nodeManager.getRead(rootId, BPlusTreeParams.RootParent) ; } return nodeManager.getRead(rootIdx, BPlusTreeParams.RootParent) ; }
private BPTreeNode getRootWrite() { if ( isTransactional() ) { super.checkWriteTxn() ; int rootId = super.getDataState().getRoot() ; return nodeManager.getRead(rootId, BPlusTreeParams.RootParent) ; } return nodeManager.getRead(rootIdx, BPlusTreeParams.RootParent) ; }
private BPTreeNode getRootRead() { if ( isTransactional() ) { super.checkTxn() ; int rootId = super.getDataState().getRoot() ; return nodeManager.getRead(rootId, BPlusTreeParams.RootParent) ; } return nodeManager.getRead(rootIdx, BPlusTreeParams.RootParent) ; }
@Override protected ByteBuffer _commitPrepare(TxnId txnId, BptTxnState state) { nodeManager.getBlockMgr().sync(); recordsMgr.getBlockMgr().sync(); long nodeLimit = nodeManager.allocLimit() ; long recordsLimit = recordsMgr.allocLimit() ; // But don't write it yet. stateManager.setState(state.getRoot(), nodeLimit, recordsLimit); return stateManager.getState() ; }
@Override protected ByteBuffer _commitPrepare(TxnId txnId, BptTxnState state) { nodeManager.getBlockMgr().sync(); recordsMgr.getBlockMgr().sync(); long nodeLimit = nodeManager.allocLimit() ; long recordsLimit = recordsMgr.allocLimit() ; // But don't write it yet. stateManager.setState(state.getRoot(), nodeLimit, recordsLimit); return stateManager.getState() ; }