TopicState constructor
Creates a new TopicState.
cluster The cluster name.
configs Configuration for the topic that are overridden from the cluster defaults. The key of the map is a Kafka topic property name, for example: cleanup.policy=compact, compression.type=producer.
deletionPolicy Whether Terraform will be prevented from destroying the resource. Defaults to DELETE.
location ID of the location of the Kafka resource. See https://cloud.google.com/managed-kafka/docs/locations for a list of supported locations.
name The name of the topic. The topic segment is used when connecting directly to the cluster. Must be in the format projects/PROJECT_ID/locations/LOCATION/clusters/CLUSTER_ID/topics/TOPIC_ID.
partitionCount The number of partitions in a topic. You can increase the partition count for a topic, but you cannot decrease it. Increasing partitions for a topic that uses a key might change how messages are distributed.
project The ID of the project in which the resource belongs.
replicationFactor The number of replicas of each partition. A replication factor of 3 is recommended for high availability.
topicId The ID to use for the topic, which will become the final component of the topic's name. This value is structured like: my-topic-name.
Implementation
const TopicState({
this.cluster,
this.configs,
this.deletionPolicy,
this.location,
this.name,
this.partitionCount,
this.project,
this.replicationFactor,
this.topicId,
});