Skip to content

Setting up Kafka

For connector version 3.2.0 and later

To use the Kafka connector, download and install Apache Kafka. Before you start configuring Kafka you also need the integration runtime and we refer to that location as <PRODUCT_HOME>.

Note: The recommended version is Kafka 2.12-2.8.2. For all available versions of Kafka that you can download, see https://kafka.apache.org/downloads. The recommended Java version is 11.

To configure the Kafka connector, copy the following client libraries from the <KAFKA_HOME>/lib directory to the <MI_HOME>/lib directory.

Copy the following additional client libraries to the <MI_HOME>/lib directory (can be copied from the Confluent platform):

Navigate to <KAFKA_HOME> and run the following command to start the ZooKeeper server:

bin/zookeeper-server-start.sh config/zookeeper.properties

From the <KAFKA_HOME> directory, run the following command to start the Kafka server:

bin/kafka-server-start.sh config/server.properties

Now that you have connected to Kafka, you can start publishing and consuming messages using the Kafka brokers. For more information, see Publishing Messages using Kafka and Consuming Messages using Kafka.

For connector version 3.1.x and below

To use the Kafka connector, download and install Apache Kafka. Before you start configuring the Kafka you also need the integration runtime and we refer to that location as <PRODUCT_HOME>.

Note: The recommended version is Kafka_2.11-2.2.1. For all available versions of Kafka that you can download, see https://kafka.apache.org/downloads. The recommended Java version is 1.8.

To configure the Kafka connector, copy the following client libraries from the <KAFKA_HOME>/lib directory to the <MI_HOME>/lib directory.

Copy the following additional client libraries to the <MI_HOME>/lib directory (can be copied from the Confluent platform):

Navigate to and run the following command to start the ZooKeeper server:

bin/zookeeper-server-start.sh config/zookeeper.properties

From the directory, run the following command to start the Kafka server:

bin/kafka-server-start.sh config/server.properties

Now that you have connected to Kafka, you can start publishing and consuming messages using the Kafka brokers. For more information, see Publishing Messages using Kafka and Consuming Messages using Kafka.