Kafka - Topics and PartitionsWhat does a time-based retention policy in Kafka primarily control?AThe maximum size of a topic partitionBThe number of consumers allowedCHow long messages are kept before deletionDThe replication factor of the topicCheck Answer
Step-by-Step SolutionSolution:Step 1: Understand retention.ms settingThe retention.ms setting defines the time duration messages are retained in Kafka before deletion.Step 2: Differentiate from size-based retentionSize-based retention controls storage size, not time. Time-based retention controls message lifetime.Final Answer:How long messages are kept before deletion -> Option CQuick Check:Time-based retention = message lifetime [OK]Quick Trick: Time-based retention controls message lifetime [OK]Common Mistakes:Confusing time-based with size-based retentionThinking retention controls consumer countMixing retention with replication settings
Master "Topics and Partitions" in Kafka9 interactive learning modes - each teaches the same concept differentlyLearnWhyDeepVisualTryChallengeProjectRecallTime
More Kafka Quizzes Consumers - Auto-commit vs manual commit - Quiz 7medium Kafka Basics and Event Streaming - Kafka installation and setup - Quiz 8hard Kafka Cluster Architecture - Controller broker - Quiz 7medium Producers - Producer retries and idempotency - Quiz 10hard Producers - Acknowledgment modes (acks=0, 1, all) - Quiz 2easy Producers - Producer retries and idempotency - Quiz 11easy Topics and Partitions - Topic creation - Quiz 5medium Topics and Partitions - Topic deletion and cleanup - Quiz 7medium Topics and Partitions - Partition ordering guarantees - Quiz 3easy Topics and Partitions - Topic deletion and cleanup - Quiz 10hard