public interface AdminClient extends ApiBackgroundResourceA client for performing Pub/Sub Lite admin operations.
Implements
ApiBackgroundResourceStatic Methods
create(AdminClientSettings settings)
public static AdminClient create(AdminClientSettings settings)| Name | Description | 
| settings | AdminClientSettings | 
      
| Type | Description | 
| AdminClient | 
| Type | Description | 
| ApiException | 
Methods
createReservation(Reservation reservation)
public abstract ApiFuture<Reservation> createReservation(Reservation reservation)Create the provided reservation if it does not yet exist.
| Name | Description | 
| reservation | ReservationThe reservation to create.  | 
      
| Type | Description | 
| ApiFuture<Reservation> | A future that will have either an error com.google.api.gax.rpc.ApiException or the reservation on success.  | 
      
createSubscription(Subscription subscription)
public default ApiFuture<Subscription> createSubscription(Subscription subscription)Create the provided subscription if it does not yet exist.
By default, a new subscription will only receive messages published after the subscription was created.
| Name | Description | 
| subscription | SubscriptionThe subscription to create.  | 
      
| Type | Description | 
| ApiFuture<Subscription> | A future that will have either an error com.google.api.gax.rpc.ApiException or the subscription on success.  | 
      
createSubscription(Subscription subscription, BacklogLocation startingOffset)
public abstract ApiFuture<Subscription> createSubscription(Subscription subscription, BacklogLocation startingOffset)Create the provided subscription at the given starting offset if it does not yet exist.
| Name | Description | 
| subscription | SubscriptionThe subscription to create.  | 
      
| startingOffset | BacklogLocationThe offset at which the new subscription will start receiving messages.  | 
      
| Type | Description | 
| ApiFuture<Subscription> | A future that will have either an error com.google.api.gax.rpc.ApiException or the subscription on success.  | 
      
createTopic(Topic topic)
public abstract ApiFuture<Topic> createTopic(Topic topic)Create the provided topic if it does not yet exist.
| Name | Description | 
| topic | TopicThe topic to create.  | 
      
| Type | Description | 
| ApiFuture<Topic> | A future that will have either an error com.google.api.gax.rpc.ApiException or the topic on success.  | 
      
deleteReservation(ReservationPath path)
public abstract ApiFuture<Void> deleteReservation(ReservationPath path)Delete the reservation with id id if it exists.
| Name | Description | 
| path | ReservationPathThe path of the reservation to retrieve.  | 
      
| Type | Description | 
| ApiFuture<Void> | A future that will have either an error com.google.api.gax.rpc.ApiException or void on success. Deleting nonexistent reservations will cause the future to have an exception with status com.google.api.gax.rpc.StatusCode.Code#NOT_FOUND  | 
      
deleteSubscription(SubscriptionPath path)
public abstract ApiFuture<Void> deleteSubscription(SubscriptionPath path)Delete the subscription with id id if it exists.
| Name | Description | 
| path | SubscriptionPathThe path of the subscription to retrieve.  | 
      
| Type | Description | 
| ApiFuture<Void> | A future that will have either an error com.google.api.gax.rpc.ApiException or void on success. Deleting nonexistent subscriptions will cause the future to have an exception with status com.google.api.gax.rpc.StatusCode.Code#NOT_FOUND  | 
      
deleteTopic(TopicPath path)
public abstract ApiFuture<Void> deleteTopic(TopicPath path)Delete the topic with id id if it exists.
| Name | Description | 
| path | TopicPathThe path of the topic to retrieve.  | 
      
| Type | Description | 
| ApiFuture<Void> | A future that will have either an error com.google.api.gax.rpc.ApiException or void on success. Deleting nonexistent topics will cause the future to have an exception with status com.google.api.gax.rpc.StatusCode.Code#NOT_FOUND  | 
      
getReservation(ReservationPath path)
public abstract ApiFuture<Reservation> getReservation(ReservationPath path)Get the reservation with id id if it exists.
| Name | Description | 
| path | ReservationPathThe path of the reservation to retrieve.  | 
      
| Type | Description | 
| ApiFuture<Reservation> | A future that will have either an error com.google.api.gax.rpc.ApiException or the reservation on success.  | 
      
getSubscription(SubscriptionPath path)
public abstract ApiFuture<Subscription> getSubscription(SubscriptionPath path)Get the subscription with id id if it exists.
| Name | Description | 
| path | SubscriptionPathThe path of the subscription to retrieve.  | 
      
| Type | Description | 
| ApiFuture<Subscription> | A future that will have either an error com.google.api.gax.rpc.ApiException or the subscription on success.  | 
      
getTopic(TopicPath path)
public abstract ApiFuture<Topic> getTopic(TopicPath path)Get the topic with id id if it exists.
| Name | Description | 
| path | TopicPathThe path of the topic to retrieve.  | 
      
| Type | Description | 
| ApiFuture<Topic> | A future that will have either an error com.google.api.gax.rpc.ApiException or the topic on success.  | 
      
getTopicPartitionCount(TopicPath path)
public abstract ApiFuture<Long> getTopicPartitionCount(TopicPath path)Get the partitioning info for the topic with id id if it exists.
| Name | Description | 
| path | TopicPathThe path of the topic to retrieve.  | 
      
| Type | Description | 
| ApiFuture<Long> | A future that will have either an error com.google.api.gax.rpc.ApiException or the number of topic partitions on success.  | 
      
listReservationTopics(ReservationPath path)
public abstract ApiFuture<List<TopicPath>> listReservationTopics(ReservationPath path)Get the list of topics for the reservation with id id if it exists.
| Name | Description | 
| path | ReservationPathThe path of the reservation to retrieve.  | 
      
| Type | Description | 
| ApiFuture<List<TopicPath>> | A future that will have either an error com.google.api.gax.rpc.ApiException or the list of topics on success.  | 
      
listReservations(LocationPath path)
public abstract ApiFuture<List<Reservation>> listReservations(LocationPath path)List all reservations for the specified project.
| Name | Description | 
| path | LocationPathThe path of the project to list reservations for.  | 
      
| Type | Description | 
| ApiFuture<List<Reservation>> | A future that will have either an error com.google.api.gax.rpc.ApiException or the list of reservation paths on success.  | 
      
listSubscriptions(LocationPath path)
public abstract ApiFuture<List<Subscription>> listSubscriptions(LocationPath path)List all subscriptions for the specified project.
| Name | Description | 
| path | LocationPathThe path of the project to list subscriptions for.  | 
      
| Type | Description | 
| ApiFuture<List<Subscription>> | A future that will have either an error com.google.api.gax.rpc.ApiException or the list of subscription paths on success.  | 
      
listTopicSubscriptions(TopicPath path)
public abstract ApiFuture<List<SubscriptionPath>> listTopicSubscriptions(TopicPath path)Get the list of subscriptions for the topic with id id if it exists.
| Name | Description | 
| path | TopicPathThe path of the topic to retrieve.  | 
      
| Type | Description | 
| ApiFuture<List<SubscriptionPath>> | A future that will have either an error com.google.api.gax.rpc.ApiException or the list of subscriptions on success.  | 
      
listTopics(LocationPath path)
public abstract ApiFuture<List<Topic>> listTopics(LocationPath path)List all topics for the specified project.
| Name | Description | 
| path | LocationPathThe path of the project to list topics for.  | 
      
| Type | Description | 
| ApiFuture<List<Topic>> | A future that will have either an error com.google.api.gax.rpc.ApiException or the list of topic paths on success.  | 
      
region()
public abstract CloudRegion region()The Google Cloud region this client operates on.
| Type | Description | 
| CloudRegion | 
seekSubscription(SubscriptionPath path, SeekTarget target)
public abstract OperationFuture<SeekSubscriptionResponse,OperationMetadata> seekSubscription(SubscriptionPath path, SeekTarget target)Initiate an out-of-band seek for a subscription to a specified target, which may be timestamps or named positions within the message backlog.
See https://cloud.google.com/pubsub/lite/docs/seek for more information.
| Name | Description | 
| path | SubscriptionPathThe path of the subscription to seek.  | 
      
| target | SeekTargetThe location to seek to.  | 
      
| Type | Description | 
| OperationFuture<SeekSubscriptionResponse,OperationMetadata> | A com.google.api.gax.longrunning.OperationFuture that returns an operation name if the seek was successfully initiated, or otherwise throw an com.google.api.gax.rpc.ApiException. com.google.api.gax.longrunning.OperationFuture.get() will return a response if the seek operation completes successfully, or otherwise throw an com.google.api.gax.rpc.ApiException.  | 
      
updateReservation(Reservation reservation, FieldMask mask)
public abstract ApiFuture<Reservation> updateReservation(Reservation reservation, FieldMask mask)Update the reservation with path reservation.getPath() if it exists.
| Name | Description | 
| reservation | ReservationThe reservation to update.  | 
      
| mask | FieldMaskThe mask indicating which fields should be updated.  | 
      
| Type | Description | 
| ApiFuture<Reservation> | A future that will have either an error com.google.api.gax.rpc.ApiException or the resulting reservation on success. Updating nonexistent reservations will cause the future to have an exception with status com.google.api.gax.rpc.StatusCode.Code#NOT_FOUND  | 
      
updateSubscription(Subscription subscription, FieldMask mask)
public abstract ApiFuture<Subscription> updateSubscription(Subscription subscription, FieldMask mask)Update the subscription with path subscription.getPath() if it exists.
| Name | Description | 
| subscription | SubscriptionThe subscription to update.  | 
      
| mask | FieldMaskThe mask indicating which fields should be updated.  | 
      
| Type | Description | 
| ApiFuture<Subscription> | A future that will have either an error com.google.api.gax.rpc.ApiException or the resulting subscription on success. Updating nonexistent subscriptions will cause the future to have an exception with status com.google.api.gax.rpc.StatusCode.Code#NOT_FOUND  | 
      
updateTopic(Topic topic, FieldMask mask)
public abstract ApiFuture<Topic> updateTopic(Topic topic, FieldMask mask)Update the topic with path topic.getPath() if it exists.
| Name | Description | 
| topic | TopicThe topic to update.  | 
      
| mask | FieldMaskThe mask indicating which fields should be updated.  | 
      
| Type | Description | 
| ApiFuture<Topic> | A future that will have either an error com.google.api.gax.rpc.ApiException or the resulting topic on success. Updating nonexistent topics will cause the future to have an exception with status com.google.api.gax.rpc.StatusCode.Code#NOT_FOUND  |