public interface TopicStatsClient extends ApiBackgroundResource
| Modifier and Type | Method and Description |
|---|---|
com.google.api.core.ApiFuture<Optional<Cursor>> |
computeCursorForEventTime(TopicPath path,
Partition partition,
com.google.protobuf.Timestamp eventTime)
Compute the cursor of the first message with event time greater than or equal to the specified
event time, for a topic partition.
|
com.google.api.core.ApiFuture<Optional<Cursor>> |
computeCursorForPublishTime(TopicPath path,
Partition partition,
com.google.protobuf.Timestamp publishTime)
Compute the cursor of the first message with publish time greater than or equal to the
specified publish time, for a topic partition.
|
com.google.api.core.ApiFuture<Cursor> |
computeHeadCursor(TopicPath path,
Partition partition)
Compute the head cursor for the partition.
|
com.google.api.core.ApiFuture<ComputeMessageStatsResponse> |
computeMessageStats(TopicPath path,
Partition partition,
Offset start,
Offset end)
Compute statistics about the messages between two cursors in a topic partition.
|
static TopicStatsClient |
create(TopicStatsClientSettings settings) |
CloudRegion |
region()
The Google Cloud region this client operates on.
|
closestatic TopicStatsClient create(TopicStatsClientSettings settings) throws com.google.api.gax.rpc.ApiException
com.google.api.gax.rpc.ApiExceptionCloudRegion region()
com.google.api.core.ApiFuture<ComputeMessageStatsResponse> computeMessageStats(TopicPath path, Partition partition, Offset start, Offset end)
path - The topic to compute statistics onpartition - The partition to compute statistics forstart - The start cursorend - The end cursorApiException or the
ComputeMessageStatistics on success.com.google.api.core.ApiFuture<Cursor> computeHeadCursor(TopicPath path, Partition partition)
path - The topic to compute head cursor onpartition - The partition to compute head cursor forApiException or the head cursor on
success.com.google.api.core.ApiFuture<Optional<Cursor>> computeCursorForPublishTime(TopicPath path, Partition partition, com.google.protobuf.Timestamp publishTime)
If such a message cannot be found, the returned Optional will be empty.
path - The topic to compute cursor forpartition - The partition to compute cursor forpublishTime - The target publish timeApiException, an empty Optional or a
non-null Cursor.com.google.api.core.ApiFuture<Optional<Cursor>> computeCursorForEventTime(TopicPath path, Partition partition, com.google.protobuf.Timestamp eventTime)
If such a message cannot be found, the returned Optional will be empty.
path - The topic to compute cursor forpartition - The partition to compute cursor foreventTime - The target event timeApiException, an empty Optional or a
non-null Cursor.Copyright © 2023 Google LLC. All rights reserved.