State Stores & RocksDB — Concept Check
Questions on State Stores & RocksDB. Stateful operations (aggregations, joins) persist state in RocksDB-backed changelog topics; state is restored automatically on restart, enabling fault-tolerant stateful processing.
Questions in this quiz
8 questions on State Stores & RocksDB — Concept Check. Work through them here, then start the quiz to answer them and see your score.
1.A Kafka Streams application using RocksDB-backed state stores restarts. What happens to the state?
- AState is restored by replaying the changelog topic.
- BState is restored from a central database.
- CState is lost and must be rebuilt from scratch.
- DState is restored from an in-memory cache.
2.You notice a Kafka Streams application is slow during startup due to state restoration. What can you do to speed it up?
- ASwitch to a central database for state storage.
- BEnable standby replicas for faster failover.
- CIncrease the number of changelog topics.
- DUse only in-memory state stores for all data.
3.In a Kafka Streams application, what is the purpose of the changelog topic?
- ATo store application configuration settings.
- BTo log application errors for debugging.
- CTo manage user access and authentication.
- DTo back up state changes for restoration.
4.A developer uses in-memory state stores for a Kafka Streams app. What risk do they face?
- AState will be backed by a central database.
- BState will automatically replicate across nodes.
- CState will be lost on JVM restart.
- DState will be slower to access than RocksDB.
5.What happens if a Kafka Streams instance with RocksDB state stores fails?
- AState is permanently lost and cannot be recovered.
- BState is backed up in-memory and restored instantly.
- CState is restored on a new instance using the changelog.
- DState is automatically transferred to a central database.
6.A developer believes using in-memory state stores will always speed up their Kafka Streams app. Why might this be wrong?
- AIn-memory stores increase CPU usage significantly.
- BIn-memory stores lose state on restart, requiring full replay.
- CIn-memory stores require more network bandwidth.
- DIn-memory stores are slower than disk-based stores.
7.Why might a Kafka Streams application use a custom state store instead of RocksDB?
- ATo ensure state is never lost on restart.
- BTo avoid using any form of changelog topic.
- CTo implement specialized storage like off-heap or Redis.
- DTo simplify the application configuration.
8.What is a benefit of enabling standby replicas in Kafka Streams?
- AIncreases the speed of in-memory state stores.
- BReduces the need for disk storage.
- CEliminates the need for changelog topics.
- DFaster failover by pre-building state on secondary instances.