Published:
Last updated:

Kafka

Authors
Time yourself:
Your progress:

00:30:00

0%

Filter by difficulty

38 of 38 questions shown

Kafka Fundamentals

1. What are the main components of Kafka (broker, topic, partition, etc.)?

Junior
Flag important question
Mark as complete

2. How does Kafka differ from traditional messaging systems like ActiveMQ or RabbitMQ?

Mid-level
Flag important question
Mark as complete

3. What is a Kafka cluster, and why is it recommended to run multiple brokers?

Junior
Flag important question
Mark as complete

4. How do producers publish messages to Kafka topics?

Mid-level
Flag important question
Mark as complete

5. Why is Kafka sometimes described as a “distributed commit log”? What does that imply for data retention and ordering?

Mid-level
Flag important question
Mark as complete

Cluster Architecture & Setup

Free preview complete

You’ve reached the end of the free preview

Get every remaining question and complete answer, plus progress tracking across the full Interview Question Library.

  • 33 more questions and complete answers in this topic
  • Full access to every interview topic
  • Progress tracking and question flags
  • New questions and improvements during your subscription

Full access from

$12/month

No long-term commitment. Cancel whenever you want.

6. How does Kafka ensure durability of messages even if multiple brokers fail?

Mid-levelPaid Question

7. What are the key broker configuration parameters you typically tune (e.g., log.retention.hours, num.partitions)?

JuniorPaid Question

8. How do you add a new broker to an existing Kafka cluster?

Mid-levelPaid Question

9. If you are using Kafka without ZooKeeper (KIP-500), how is metadata handled differently?

Mid-levelPaid Question

Producers & Consumers

10. How does a Kafka producer handle message batching and compression?

Mid-levelPaid Question

11. What are Consumer Groups, and why are they crucial for scalability?

Mid-levelPaid Question

12. How do you commit offsets in a consumer? What’s the difference between manual and automatic offset commits?

Mid-levelPaid Question

13. Can you explain how a consumer rebalance happens?

Mid-levelPaid Question

14. If a consumer crashes right after polling but before committing offsets, what happens to those uncommitted messages?

Mid-levelPaid Question

15. How would you design a system to guarantee exactly-once delivery in Kafka?

SeniorPaid Question

16. Can you compare synchronous vs. asynchronous consumption in Kafka consumers, and what are the trade-offs?

SeniorPaid Question

Reference: Kafka partitions and scalability

17. How does leader-follower replication work in Kafka?

Mid-levelPaid Question

Partitions & Replication

18. Why does Kafka use partitions, and how do partitions help with scalability?

SeniorPaid Question

19. How do you decide the right number of partitions for a topic?

Mid-levelPaid Question

20. What are the trade-offs of having a very high number of partitions in a topic?

Mid-levelPaid Question

Kafka Streams & Connect

21. If a leader partition crashes and a follower is not fully in sync, what is the potential data impact?

Mid-levelPaid Question

22. What is Kafka Streams, and how does it differ from Spark Streaming or Flink?

Mid-levelPaid Question

23. How does stateful stream processing work in Kafka Streams?

Mid-levelPaid Question

24. What is Kafka Connect, and why is it used for data import/export tasks?

JuniorPaid Question

25. How would you handle schema evolution in a Kafka Connect pipeline?

Mid-levelPaid Question

Security & Monitoring

26. What built-in security features does Kafka offer (e.g., SSL, SASL)?

Mid-levelPaid Question

27. How can you enable encryption in transit between Kafka brokers and clients?

Mid-levelPaid Question

28. What metrics do you typically monitor in a Kafka cluster (e.g., under replicated partitions)?

Mid-levelPaid Question

29. How do tools like Prometheus, Grafana, or Confluent Control Center help with monitoring Kafka?

Mid-levelPaid Question

30. How do you maintain and update ACLs in Kafka at scale?

SeniorPaid Question

31. What is “lag” in Kafka Consumer Groups, and how do you detect and resolve consistently high lag?

Mid-levelPaid Question

Performance & Tuning

32. How do you tune Kafka for low latency vs. high throughput?

Mid-levelPaid Question

33. What is the impact of acks settings on performance and reliability?

Mid-levelPaid Question

34. How do you optimize producer batch sizes or linger times?

SeniorPaid Question

35. Why might you adjust heap sizes or GC settings for Kafka brokers?

Mid-levelPaid Question

36. How do you troubleshoot frequent “OutOfMemoryError” crashes in a heavily loaded Kafka broker?

Mid-levelPaid Question

37. If you suspect disk I/O bottlenecks, what steps would you take to isolate and fix the problem?

SeniorPaid Question

38. If you had to handle a major Kafka cluster outage during peak traffic, how would you systematically restore service while preserving data consistency?

Mid-levelPaid Question