Class Topic (2.5.0)

Topic(mapping=None, *, ignore_unknown_fields=False, **kwargs)

A topic resource.

Attributes

NameDescription
name str
Required. The name of the topic. It must have the format "projects/{project}/topics/{topic}". {topic} must start with a letter, and contain only letters ([A-Za-z]), numbers ([0-9]), dashes (-), underscores (`_), periods (.`), tildes (
), plus
   (+) or percent signs (%). It must be between 3 and
   255 characters in length, and it must not start with
   "goog".
        
labels Sequence[google.pubsub_v1.types.Topic.LabelsEntry]
See [Creating and managing labels] (https://cloud.google.com/pubsub/docs/labels).
message_storage_policy google.pubsub_v1.types.MessageStoragePolicy
Policy constraining the set of Google Cloud Platform regions where messages published to the topic may be stored. If not present, then no constraints are in effect.
kms_key_name str
The resource name of the Cloud KMS CryptoKey to be used to protect access to messages published on this topic. The expected format is projects/*/locations/*/keyRings/*/cryptoKeys/*.
schema_settings google.pubsub_v1.types.SchemaSettings
Settings for validating messages published against a schema.
satisfies_pzs bool
Reserved for future use. This field is set only in responses from the server; it is ignored if it is set in any requests.

Classes

LabelsEntry

LabelsEntry(mapping=None, *, ignore_unknown_fields=False, **kwargs)

The abstract base class for a message.

Parameters
NameDescription
kwargs dict

Keys and values corresponding to the fields of the message.

mapping Union[dict, .Message]

A dictionary or message to be used to determine the values for this message.

ignore_unknown_fields Optional(bool)

If True, do not raise errors for unknown fields. Only applied if mapping is a mapping type or there are keyword parameters.