AMPS C/C++ Client Class Reference
AMPS C/C++ Client Version 5.3.4.4
|
Interface for BookmarkStoreImpl classes. More...
#include <BookmarkStore.hpp>
Public Member Functions | |
BookmarkStore () | |
Creates a BookmarkStore that does nothing. | |
BookmarkStore (BookmarkStoreImpl *impl_) | |
Creates a BookmarkStore based on the given implementation. | |
void | setImplementation (BookmarkStoreImpl *impl_) |
Sets the BookmarkStore to use the given implementation. | |
size_t | log (Message &message_) |
Log a bookmark to the persistent log. More... | |
void | discard (const Message::Field &subId_, size_t bookmarkSeqNo_) |
Log a discard-bookmark entry to the persistent log based on a bookmark sequence number. More... | |
void | discard (const Message &message_) |
Log a discard-bookmark entry to the persistent log based on a Message. More... | |
Message::Field | getMostRecent (const Message::Field &subId_) |
Returns the most recent bookmark from the log that ought to be used for (re-)subscriptions. More... | |
bool | isDiscarded (Message &message_) |
Called for each arriving message to determine if the application has already seen this bookmark and should not be reprocessed. More... | |
void | purge () |
Called to purge the contents of this store. More... | |
void | purge (const Message::Field &subId_) |
Called to purge the contents of this store for particular subId. More... | |
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... | |
size_t | getOldestBookmarkSeq (const std::string &subId_) |
Called to find the oldest bookmark in the store. More... | |
size_t | getOldestBookmarkSeq (const Message::Field &subId_) |
Called to find the oldest bookmark sequence in the store. More... | |
void | persisted (const Message::Field &subId_, const Message::Field &bookmark_) |
Called internally to indicate messages up to and including bookmark are replicated to all replication destinations. More... | |
void | persisted (const Message::Field &subId_, size_t bookmark_) |
Called internally to indicate messages up to and including bookmark are replicated to all replication destinations. More... | |
void | setServerVersion (size_t version_) |
Internally used to set the server version so the store knows how to deal with persisted acks and calls to getMostRecent(). More... | |
void | setServerVersion (const VersionInfo &version_) |
Internally used to set the server version so the store knows how to deal with persisted acks and calls to getMostRecent(). More... | |
void | prune (const std::string &tmpFileName_="") |
Used to trim the size of a store's storage. More... | |
BookmarkStoreImpl * | get () |
Used to get a pointer to the implementation. 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... | |
Interface for BookmarkStoreImpl classes.
|
inline |
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. |
|
inline |
Log a discard-bookmark entry to the persistent log based on a Message.
message_ | The message to discard. |
|
inline |
Used to get a pointer to the implementation.
|
inline |
Gets the maximum allowed length for a sub id when recovering a bookmark store from persistent storage.
|
inline |
Returns the most recent bookmark from the log that ought to be used for (re-)subscriptions.
subId_ | The id of the subscription to check. |
|
inline |
Called to find the oldest bookmark in the store.
subId_ | The subscription ID on which to find the oldest bookmark. |
|
inline |
Called to find the oldest bookmark sequence in the store.
subId_ | The subscription ID on which to find the oldest bookmark. |
|
inline |
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. |
|
inline |
Log a bookmark to the persistent log.
message_ | The Message to log. |
|
inline |
Called internally to indicate messages up to and including bookmark are replicated to all replication destinations.
subId_ | The subscription Id to which the bookmark applies. |
bookmark_ | The most recent bookmark replicated everywhere. |
|
inline |
Called internally to indicate messages up to and including bookmark are replicated to all replication destinations.
subId_ | The subscription Id to which the bookmark applies. |
bookmark_ | The most recent bookmark replicated everywhere. |
|
inline |
Used to trim the size of a store's storage.
Implemented for file-based stores to remove items no longer necessary to create the current state.
tmpFileName_ | The name to use for the temporary file created while pruning the bookmark store. |
|
inline |
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.
|
inline |
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.
|
inline |
Sets the maximum allowed length for a sub id when recovering a bookmark store from persistent storage.
maxSubIdLength_ | The maximum length allowed. |
|
inline |
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. |
|
inline |
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. |
|
inline |
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. |