AdminClient(
region: google.cloud.pubsublite.types.location.CloudRegion,
credentials: Optional[google.auth.credentials.Credentials] = None,
transport: Optional[str] = None,
client_options: Optional[google.api_core.client_options.ClientOptions] = None,
)
An admin client for Pub/Sub Lite. Only operates on a single region.
Methods
AdminClient
AdminClient(
region: google.cloud.pubsublite.types.location.CloudRegion,
credentials: Optional[google.auth.credentials.Credentials] = None,
transport: Optional[str] = None,
client_options: Optional[google.api_core.client_options.ClientOptions] = None,
)
Create a new AdminClient.
create_subscription
create_subscription(
subscription: google.cloud.pubsublite_v1.types.common.Subscription,
)
Create a subscription, returns the created subscription.
create_topic
create_topic(topic: google.cloud.pubsublite_v1.types.common.Topic)
Create a topic, returns the created topic.
delete_subscription
delete_subscription(
subscription_path: google.cloud.pubsublite.types.paths.SubscriptionPath,
)
Delete a subscription and all associated messages.
delete_topic
delete_topic(topic_path: google.cloud.pubsublite.types.paths.TopicPath)
Delete a topic and all associated messages.
get_subscription
get_subscription(
subscription_path: google.cloud.pubsublite.types.paths.SubscriptionPath,
)
Get the subscription object from the server.
get_topic
get_topic(topic_path: google.cloud.pubsublite.types.paths.TopicPath)
Get the topic object from the server.
get_topic_partition_count
get_topic_partition_count(
topic_path: google.cloud.pubsublite.types.paths.TopicPath,
)
Get the number of partitions in the provided topic.
list_subscriptions
list_subscriptions(location_path: google.cloud.pubsublite.types.paths.LocationPath)
List the Pub/Sub lite subscriptions that exist for a project in a given location.
list_topic_subscriptions
list_topic_subscriptions(topic_path: google.cloud.pubsublite.types.paths.TopicPath)
List the subscriptions that exist for a given topic.
list_topics
list_topics(location_path: google.cloud.pubsublite.types.paths.LocationPath)
List the Pub/Sub lite topics that exist for a project in a given location.
region
region()
The region this client is for.
update_subscription
update_subscription(
subscription: google.cloud.pubsublite_v1.types.common.Subscription,
update_mask: google.protobuf.field_mask_pb2.FieldMask,
)
Update the masked fields of the provided subscription.
update_topic
update_topic(
topic: google.cloud.pubsublite_v1.types.common.Topic,
update_mask: google.protobuf.field_mask_pb2.FieldMask,
)
Update the masked fields of the provided topic.