public static interface SpannerDatabaseChangeSetPoller.Builder
SpannerDatabaseChangeSetPoller.| Modifier and Type | Interface and Description |
|---|---|
static interface |
SpannerDatabaseChangeSetPoller.Builder.TableExcluder
Interface for excluding specific tables from a
SpannerDatabaseChangeSetPoller. |
static interface |
SpannerDatabaseChangeSetPoller.Builder.TableSelecter
Interface for selecting the tables that should be monitored by a
SpannerDatabaseChangeSetPoller. |
| Modifier and Type | Method and Description |
|---|---|
SpannerDatabaseChangeSetPoller |
build()
Creates a
SpannerDatabaseChangeSetPoller from this builder. |
SpannerDatabaseChangeSetPoller.Builder |
setCommitTimestampRepository(CommitTimestampRepository repository)
Sets a specific
CommitTimestampRepository to use for the SpannerTableTailers
that are watching the change set table. |
SpannerDatabaseChangeSetPoller.Builder |
setExecutor(ScheduledExecutorService executor)
Sets a specific
ScheduledExecutorService to use for this SpannerDatabaseChangeSetPoller. |
SpannerDatabaseChangeSetPoller.Builder |
setPollInterval(org.threeten.bp.Duration interval)
Sets the poll interval to use for this
SpannerDatabaseChangeSetPoller. |
SpannerDatabaseChangeSetPoller.Builder setCommitTimestampRepository(CommitTimestampRepository repository)
CommitTimestampRepository to use for the SpannerTableTailers
that are watching the change set table.
If none is set, it will default to a SpannerCommitTimestampRepository which stores
the last seen commit timestamp in a table named LAST_SEEN_COMMIT_TIMESTAMPS. The table will
be created if it does not yet exist.
SpannerDatabaseChangeSetPoller.Builder setPollInterval(org.threeten.bp.Duration interval)
SpannerDatabaseChangeSetPoller. The default is
1 second.SpannerDatabaseChangeSetPoller.Builder setExecutor(ScheduledExecutorService executor)
ScheduledExecutorService to use for this SpannerDatabaseChangeSetPoller. This executor will be used to execute the poll queries on
the tables and to call the SpannerTableChangeWatcher.RowChangeCallbacks. The default will use a ScheduledThreadPoolExecutor with a core size equal to the number of tables that is being
monitored.SpannerDatabaseChangeSetPoller build()
SpannerDatabaseChangeSetPoller from this builder.Copyright © 2022 Google LLC. All rights reserved.