InterviewSolution
| 1. |
What do you understand about log compaction and quotas in Kafka? |
|
Answer» Log compaction is a way through which Kafka assures that for each topic partition, at least the last known value for each message KEY within the log of data is kept. This allows for the restoration of state following an application crash or a system failure. During any operational maintenance, it allows REFRESHING caches after an application restarts. Any consumer processing the log from the beginning will be able to see at least the FINAL state of all records in the order in which they were written, because of the log compaction. A Kafka cluster can apply quotas on producers and fetch requests as of Kafka 0.9. Quotas are byte-rate limits that are set for each client-id. A client-id is a logical identifier for a request-making application. A single client-id can THEREFORE link to numerous producers and client instances. The quota will be applied to them all as a single unit. Quotas PREVENT a single application from monopolizing broker resources and causing network saturation by consuming extremely large amounts of data. |
|