segment.bytes
The topic property that sets the maximum size of one log segment file before the broker closes it and starts a new one.
In more detail
Kafka's default is one gibibyte. The compaction lesson sets it very small so segments close quickly and the cleaner has something to work on.
Example
-c segment.bytes=10000Related terms
- log segment — One file in the series of files that together make up a partition's log on disk.
- log compaction — A cleanup mode in which the broker keeps at least the latest record for every key and removes older records with the same key.
- retention — How long data such as backups, logs or snapshots is kept before it is deleted.
Taught in
- Retention Deletes Files, Not Records — Confluent Apache Kafka Certifications (CCDAK and CCAAK) Exam Prep
- Forty Minutes To Start — Confluent Apache Kafka Certifications (CCDAK and CCAAK) Exam Prep
- Log Compaction: A Topic As A Table — Apache Kafka & Event Streaming