AMPS C/C++ Client Class Reference
AMPS C/C++ Client Version 5.3.4.4
|
Abstract base class for storing received bookmarks for HA clients. More...
#include <BookmarkStore.hpp>
Public Member Functions | |
virtual size_t | log (Message &message_)=0 |
Log a bookmark to the persistent log. More... | |
virtual void | discard (const Message::Field &subId_, size_t bookmarkSeqNo_)=0 |
Log a discard-bookmark entry to the persistent log based on a bookmark sequence number. More... | |
virtual void | discard (const Message &message_)=0 |
Log a discard-bookmark entry to the persistent log based on a bookmark sequence number. More... | |
virtual Message::Field | getMostRecent (const Message::Field &subId_)=0 |
Returns the most recent bookmark from the log that ought to be used for (re-)subscriptions. More... | |
virtual bool | isDiscarded (Message &message_)=0 |
Called for each arriving message to determine if the application has already seen this bookmark and should not be reprocessed. More... | |
virtual void | purge ()=0 |
Called to purge the contents of this store. More... | |
virtual void | purge (const Message::Field &subId_)=0 |
Called to purge the contents of this store for particular subId. More... | |
virtual size_t | getOldestBookmarkSeq (const Message::Field &subId_)=0 |
Called to find the oldest bookmark sequence in the store. More... | |
virtual void | setResizeHandler (BookmarkStoreResizeHandler handler_, void *userData_) |
Set a handler on the bookmark store that will get called whenever a resize of the store is required due to the number of stored bookmarks exceeding the currently allocated storage to hold them. More... | |
virtual void | persisted (const Message::Field &subId_, const Message::Field &bookmark_)=0 |
Mark the bookmark provided as replicated to all sync replication destinations for the given subscription. More... | |
virtual Message::Field | persisted (const Message::Field &subId_, size_t bookmark_)=0 |
Mark the bookmark provided as replicated to all sync replication destinations for the given subscription. More... | |
virtual void | setServerVersion (size_t version_)=0 |
Internally used to set the server version so the store knows how to deal with persisted acks and calls to getMostRecent(). More... | |
virtual void | setServerVersion (const VersionInfo &version_)=0 |
Internally used to set the server version so the store knows how to deal with persisted acks and calls to getMostRecent(). More... | |
size_t | getMaxSubIdLength () const |
Gets the maximum allowed length for a sub id when recovering a bookmark store from persistent storage. More... | |
void | setMaxSubIdLength (size_t maxSubIdLength_) |
Sets the maximum allowed length for a sub id when recovering a bookmark store from persistent storage. More... | |
Abstract base class for storing received bookmarks for HA clients.
|
pure virtual |
Log a discard-bookmark entry to the persistent log based on a bookmark sequence number.
subId_ | The id of the subscription to which the bookmark applies. |
bookmarkSeqNo_ | The bookmark sequence number to discard. |
Implemented in AMPS::MemoryBookmarkStore, AMPS::MMapBookmarkStore, AMPS::LoggedBookmarkStore, and AMPS::RingBookmarkStore.
|
pure virtual |
Log a discard-bookmark entry to the persistent log based on a bookmark sequence number.
message_ | The Message to discard from the store. |
Implemented in AMPS::MemoryBookmarkStore, AMPS::MMapBookmarkStore, AMPS::LoggedBookmarkStore, and AMPS::RingBookmarkStore.
|
inline |
Gets the maximum allowed length for a sub id when recovering a bookmark store from persistent storage.
|
pure virtual |
Returns the most recent bookmark from the log that ought to be used for (re-)subscriptions.
subId_ | The id of the subscription to check. |
Implemented in AMPS::MemoryBookmarkStore, AMPS::MMapBookmarkStore, AMPS::LoggedBookmarkStore, and AMPS::RingBookmarkStore.
|
pure virtual |
Called to find the oldest bookmark sequence in the store.
subId_ | The subscription ID on which to find the oldest bookmark. |
Implemented in AMPS::MemoryBookmarkStore.
|
pure virtual |
Called for each arriving message to determine if the application has already seen this bookmark and should not be reprocessed.
Returns 'true' if the bookmark is in the log and should not be re-processed, false otherwise.
message_ | The Message to check. |
Implemented in AMPS::MemoryBookmarkStore, AMPS::MMapBookmarkStore, and AMPS::LoggedBookmarkStore.
|
pure virtual |
Log a bookmark to the persistent log.
message_ | The Message to log in the store. |
Implemented in AMPS::MemoryBookmarkStore, AMPS::MMapBookmarkStore, AMPS::LoggedBookmarkStore, and AMPS::RingBookmarkStore.
|
pure virtual |
Mark the bookmark provided as replicated to all sync replication destinations for the given subscription.
subId_ | The subscription Id to which the bookmark applies. |
bookmark_ | The most recent replicated bookmark. |
Implemented in AMPS::MemoryBookmarkStore, and AMPS::RingBookmarkStore.
|
pure virtual |
Mark the bookmark provided as replicated to all sync replication destinations for the given subscription.
subId_ | The subscription Id to which the bookmark applies. |
bookmark_ | The most recent bookmark's sequence number. |
Implemented in AMPS::MemoryBookmarkStore.
|
pure virtual |
Called to purge the contents of this store.
Removes any tracking history associated with publishers and received messages, and may delete or truncate on-disk representations as well.
Implemented in AMPS::MemoryBookmarkStore, AMPS::MMapBookmarkStore, AMPS::LoggedBookmarkStore, and AMPS::RingBookmarkStore.
|
pure virtual |
Called to purge the contents of this store for particular subId.
Removes any tracking history associated with publishers and received messages, and will remove the subId from the file as well.
Implemented in AMPS::MemoryBookmarkStore, AMPS::LoggedBookmarkStore, AMPS::MMapBookmarkStore, and AMPS::RingBookmarkStore.
|
inline |
Sets the maximum allowed length for a sub id when recovering a bookmark store from persistent storage.
maxSubIdLength_ | The maximum length allowed. |
|
inlinevirtual |
Set a handler on the bookmark store that will get called whenever a resize of the store is required due to the number of stored bookmarks exceeding the currently allocated storage to hold them.
handler_ | The handler to be called when resizing. |
userData_ | User data passed to the handler when it is called. |
|
pure virtual |
Internally used to set the server version so the store knows how to deal with persisted acks and calls to getMostRecent().
version_ | The version of the server being used. |
Implemented in AMPS::MemoryBookmarkStore, AMPS::LoggedBookmarkStore, and AMPS::MMapBookmarkStore.
|
pure virtual |
Internally used to set the server version so the store knows how to deal with persisted acks and calls to getMostRecent().
version_ | The version of the server being used. |
Implemented in AMPS::MemoryBookmarkStore, AMPS::LoggedBookmarkStore, and AMPS::MMapBookmarkStore.