KafkaTopic
Usage example¶
Example
Info
To create this resource, a Secret
containing Aiven token must be created first.
Apply the resource with:
Verify the newly created KafkaTopic
:
The output is similar to the following:
KafkaTopic¶
KafkaTopic is the Schema for the kafkatopics API.
Required
apiVersion
(string). Valueaiven.io/v1alpha1
.kind
(string). ValueKafkaTopic
.metadata
(object). Data that identifies the object, including aname
string and optionalnamespace
.spec
(object). KafkaTopicSpec defines the desired state of KafkaTopic. See below for nested schema.
spec¶
Appears on KafkaTopic
.
KafkaTopicSpec defines the desired state of KafkaTopic.
Required
partitions
(integer, Minimum: 1, Maximum: 1000000). Number of partitions to create in the topic.project
(string, Immutable, Pattern:^[a-zA-Z0-9_-]+$
, MaxLength: 63). Identifies the project this resource belongs to.replication
(integer, Minimum: 2). Replication factor for the topic.serviceName
(string, Immutable, Pattern:^[a-z][-a-z0-9]+$
, MaxLength: 63). Specifies the name of the service that this resource belongs to.
Optional
authSecretRef
(object). Authentication reference to Aiven token in a secret. See below for nested schema.config
(object). Kafka topic configuration. See below for nested schema.tags
(array of objects). Kafka topic tags. See below for nested schema.termination_protection
(boolean). It is a Kubernetes side deletion protections, which prevents the kafka topic from being deleted by Kubernetes. It is recommended to enable this for any production databases containing critical data.topicName
(string, Immutable, MinLength: 1, MaxLength: 249). Topic name. If provided, is used instead of metadata.name. This field supports additional characters, has a longer length, and will replace metadata.name in future releases.
authSecretRef¶
Appears on spec
.
Authentication reference to Aiven token in a secret.
Required
config¶
Appears on spec
.
Kafka topic configuration.
Optional
cleanup_policy
(string). cleanup.policy value.compression_type
(string). compression.type value.delete_retention_ms
(integer). delete.retention.ms value.file_delete_delay_ms
(integer). file.delete.delay.ms value.flush_messages
(integer). flush.messages value.flush_ms
(integer). flush.ms value.index_interval_bytes
(integer). index.interval.bytes value.local_retention_bytes
(integer). local.retention.bytes value.local_retention_ms
(integer). local.retention.ms value.max_compaction_lag_ms
(integer). max.compaction.lag.ms value.max_message_bytes
(integer). max.message.bytes value.message_downconversion_enable
(boolean). message.downconversion.enable value.message_format_version
(string). message.format.version value.message_timestamp_difference_max_ms
(integer). message.timestamp.difference.max.ms value.message_timestamp_type
(string). message.timestamp.type value.min_cleanable_dirty_ratio
(number). min.cleanable.dirty.ratio value.min_compaction_lag_ms
(integer). min.compaction.lag.ms value.min_insync_replicas
(integer). min.insync.replicas value.preallocate
(boolean). preallocate value.remote_storage_enable
(boolean). remote_storage_enable.retention_bytes
(integer). retention.bytes value.retention_ms
(integer). retention.ms value.segment_bytes
(integer). segment.bytes value.segment_index_bytes
(integer). segment.index.bytes value.segment_jitter_ms
(integer). segment.jitter.ms value.segment_ms
(integer). segment.ms value.
tags¶
Appears on spec
.
Kafka topic tags.
Required
key
(string, Pattern:^[a-zA-Z0-9_-]+$
, MinLength: 1, MaxLength: 64).
Optional
value
(string, Pattern:^[a-zA-Z0-9_-]+$
, MaxLength: 256).