|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
public interface IAtomicStore
Interface for low-level operations on a store supporting an atomic commit. Persistent implementations of this interface are restart-safe.
| Field Summary |
|---|
| Fields inherited from interface com.bigdata.rawstore.IAddressManager |
|---|
NULL |
| Method Summary | |
|---|---|
void |
abort()
Abandon the current write set (synchronous). |
long |
commit()
Atomic commit (synchronous). |
ICommitRecord |
getCommitRecord(long timestamp)
Return the ICommitRecord for the most recent committed state
whose commit timestamp is less than or equal to timestamp. |
long |
getRootAddr(int index)
The last address stored in the specified root slot as of the last committed state of the store. |
IRootBlockView |
getRootBlockView()
Return a read-only view of the current root block. |
void |
setCommitter(int index,
ICommitter committer)
Set a persistence capable data structure for callback during the commit protocol. |
| Methods inherited from interface com.bigdata.rawstore.IRawStore |
|---|
close, deleteResources, destroy, force, getCounters, getFile, getResourceMetadata, getUUID, isFullyBuffered, isOpen, isReadOnly, isStable, read, size, write |
| Methods inherited from interface com.bigdata.rawstore.IAddressManager |
|---|
getByteCount, getOffset, packAddr, toAddr, toString, unpackAddr |
| Methods inherited from interface com.bigdata.rawstore.IStoreSerializer |
|---|
deserialize, deserialize, deserialize, serialize |
| Method Detail |
|---|
void abort()
long commit()
Note: if the commit fails (by throwing any kind of exception) then you
MUST invoke abort() to abandon the current write set.
ICommitRecord -or- 0L if
there were no data to commit.
IllegalStateException - if the store is not open.
IllegalStateException - if the store is not writable.
void setCommitter(int index,
ICommitter committer)
Note: the committers must be reset after restart or whenever
index - The slot in the root block where the address of the
ICommitter will be recorded.committer - The committer.long getRootAddr(int index)
index - The index of the root address to be retrieved.
IndexOutOfBoundsException - if the index is negative or too large.IRootBlockView getRootBlockView()
ICommitRecord getCommitRecord(long timestamp)
ICommitRecord for the most recent committed state
whose commit timestamp is less than or equal to timestamp. This
is used by a transaction to locate the committed state that is
the basis for its operations.
timestamp - The timestamp of interest.
ICommitRecord for the most recent committed state
whose commit timestamp is less than or equal to timestamp
-or- null iff there are no ICommitRecords
that satisfy the probe.
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||