Producer

When we write the Producer applications, we use Producer APIs that expose methods at an abstract level. Before we send any data, there are a lot of steps are performed by these APIs. Hence, it is important to understand the internal steps to gain knowledge about the Kafka producers. We will cover these in this section. First, we need to understand the responsibilities of Kafka producers besides publishing messages. Let's look at them one by one:

  • Bootstrapping Kafka broker URLs: The producer connects to at least one broker to fetch metadata about the Kafka cluster. It may happen that the first broker to which the producer wants to connect may be down. To ensure a failover, the producer implementation takes a list of more than one ...

Get Mastering Hadoop 3 now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.