- All Superinterfaces:
Serializable
Keeps track of database bookmarks and is used by the driver to ensure causal consistency between sessions and query executions.
Please note that implementations of this interface MUST NOT block for extended periods of time.
Implementations must avoid calling driver.
-
Method Summary
Modifier and TypeMethodDescriptionvoidDeletes bookmarks for the given databases.Gets an immutable set of bookmarks for all databases.getBookmarks(String database) Gets an immutable set of bookmarks for a given database.voidUpdates database bookmarks by deleting the given previous bookmarks and adding the new bookmarks.
-
Method Details
-
updateBookmarks
Updates database bookmarks by deleting the given previous bookmarks and adding the new bookmarks.- Parameters:
database- the database name, this might be an empty string when session has no database name configured and database discovery is unavailablepreviousBookmarks- the previous bookmarksnewBookmarks- the new bookmarks
-
getBookmarks
Gets an immutable set of bookmarks for a given database.- Parameters:
database- the database name- Returns:
- the set of bookmarks or an empty set if the database name is unknown to the bookmark manager
-
getAllBookmarks
Gets an immutable set of bookmarks for all databases.- Returns:
- the set of bookmarks or an empty set
-
forget
Deletes bookmarks for the given databases.This method should be called by driver users if data deletion is desired when bookmarks for the given databases are no longer needed.
- Parameters:
databases- the set of database names
-