public class MemoryPublishStore extends BlockPublishStore
Publish stores hold messages until the AMPS server has acknowledged that they are persisted. When the client detects disconnection and reconnects, the client can republish any messages which have not been acknowledged by AMPS.
Use this PublishStore when you are only concerend about server failover: MemoryPublishStore does not protect you in case of subscriber failure, because it has no persisted backing store.
|Modifier and Type||Field and Description|
The size of each block the store allocates.
_buffer, _resizeHandler, AMPS_MIN_PUB_STORE_DISCARDED_VERSION, METADATA_LAST_DISCARDED_LOCATION, METADATA_VERSION_LOCATION
|Constructor and Description|
Construct an in-memory publish store with the specified number of blocks as the initial capacity.
close, discardUpTo, flush, flush, getHighestUnpersisted, getLastPersisted, getLowestUnpersisted, growFreeListIfEmpty, recover, replay, replaySingle, setMessage, setResizeHandler, store, store, unpersistedCount
public static final int BLOCK_SIZE
public MemoryPublishStore(int initialCapacity) throws StoreException
initialCapacity- the number of blocks to allocate on construction
StoreException- Thrown when an operation fails with details of the failure.