Skip to content

Commit 1ccadda

Browse files
authored
KAFKA-19209: Clarify index.interval.bytes impact on offset and time index (#19657)
Update docs to note index.interval.bytes sets entry frequency for offset index and, conditionally, time index. Improve clarity and readability of index.interval.bytes description. Reviewers: Luke Chen <[email protected]>
1 parent b5c468f commit 1ccadda

File tree

1 file changed

+6
-4
lines changed

1 file changed

+6
-4
lines changed

clients/src/main/java/org/apache/kafka/common/config/TopicConfig.java

+6-4
Original file line numberDiff line numberDiff line change
@@ -111,10 +111,12 @@ public class TopicConfig {
111111
"The largest record batch size allowed by Kafka (after compression if compression is enabled).";
112112

113113
public static final String INDEX_INTERVAL_BYTES_CONFIG = "index.interval.bytes";
114-
public static final String INDEX_INTERVAL_BYTES_DOC = "This setting controls how frequently " +
115-
"Kafka adds an index entry to its offset index. The default setting ensures that we index a " +
116-
"message roughly every 4096 bytes. More indexing allows reads to jump closer to the exact " +
117-
"position in the log but makes the index larger. You probably don't need to change this.";
114+
public static final String INDEX_INTERVAL_BYTES_DOC = "This setting controls how frequently Kafka " +
115+
"adds entries to its offset index and, conditionally, to its time index. " +
116+
"The default setting ensures that we index a message roughly every 4096 bytes. " +
117+
"More frequent indexing allows reads to jump closer to the exact position in the log " +
118+
"but results in larger index files. You probably don't need to change this." +
119+
"<p> Note: the time index will be inserted only when the timestamp is greater than the last indexed timestamp.</p>";
118120

119121
public static final String FILE_DELETE_DELAY_MS_CONFIG = "file.delete.delay.ms";
120122
public static final String FILE_DELETE_DELAY_MS_DOC = "The time to wait before deleting a file from the " +

0 commit comments

Comments
 (0)