|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
public interface WriteBuffer
Potentially buffers writes until full, or until flush.
Method Summary | |
---|---|
void |
abort()
Abort pending writes, and wait for acknowledgment. |
void |
flush()
Flush any pending writes, and wait for them to complete. |
Method Detail |
---|
void flush() throws DhtException
DhtException
- one or more writes failed. As writes may occur in any order,
the exact state of the database is unspecified.void abort() throws DhtException
Once a buffer has been aborted, it cannot be reused. Application code must discard the buffer instance and use a different buffer to issue subsequent operations.
If writes have not been started yet, they should be discarded and not submitted to the storage system.
If writes have already been started asynchronously in the background, this method may try to cancel them, but must wait for the operation to either complete or abort before returning. This allows callers to clean up by scanning the storage system and making corrections to clean up any partial writes.
DhtException
- one or more already started writes failed.
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |