Browse the Repo

file-type-icon.circleci
file-type-iconexamples
file-type-iconconfluent-oss-ami
file-type-iconkafka-ami
file-type-iconkafka-zookeeper-confluent-oss-ami
file-type-iconkafka-zookeeper-confluent-oss-colocated-cl...
file-type-iconkafka-zookeeper-confluent-oss-standalone-c...
file-type-iconkafka-zookeeper-standalone-clusters
file-type-iconuser-data
file-type-iconREADME.md
file-type-iconmain.tf
file-type-iconoutputs.tf
file-type-iconvars.tf
file-type-iconzookeeper-ami
file-type-iconmodules
file-type-icontest
file-type-icon.gitignore
file-type-icon.pre-commit-config.yaml
file-type-iconCODEOWNERS
file-type-iconLICENSE.txt
file-type-iconREADME.md

Browse the Repo

file-type-icon.circleci
file-type-iconexamples
file-type-iconconfluent-oss-ami
file-type-iconkafka-ami
file-type-iconkafka-zookeeper-confluent-oss-ami
file-type-iconkafka-zookeeper-confluent-oss-colocated-cl...
file-type-iconkafka-zookeeper-confluent-oss-standalone-c...
file-type-iconkafka-zookeeper-standalone-clusters
file-type-iconuser-data
file-type-iconREADME.md
file-type-iconmain.tf
file-type-iconoutputs.tf
file-type-iconvars.tf
file-type-iconzookeeper-ami
file-type-iconmodules
file-type-icontest
file-type-icon.gitignore
file-type-icon.pre-commit-config.yaml
file-type-iconCODEOWNERS
file-type-iconLICENSE.txt
file-type-iconREADME.md
Apache Kafka and Confluent Tools

Apache Kafka and Confluent Tools

Deploy a cluster of Kafka brokers. Optionally deploy Confluent tools such as Schema Registry, REST Proxy, and Kafka Connect.

Code Preview

Preview the Code

mobile file icon

README.md

down

Kafka and ZooKeeper Standalone Clusters Example

This folder shows an example of how to use the kafka-cluster to run a cluster of Kafka brokers and the zookeeper-cluster module from package-zookeeper to deploy a separate cluster of ZooKeeper nodes.

This deployment configuration allows you to scale Kafka and ZooKeeper separately to handle huge amounts of data. However, this requires running and managing more servers. If you have a smaller deployment, check out the kafka-zookeeper-confluent-oss-colocated-cluster example for how to run ZooKeeper and Kafka in the same cluster.

How do you run this example?

To run this example, you need to do the following:

  1. Build the Kafka AMI
  2. Build the ZooKeeper AMI
  3. Apply the Terraform code
  4. Connect to Kafka

Build the Kafka AMI

See the kafka-ami docs.

Build the ZooKeeper AMI

See the zookeeper-ami docs.

Apply the Terraform code

To apply the Terraform templates:

  1. Install Terraform
  2. Open vars.tf, set the environment variables specified at the top of the file, and fill in any other variables that don't have a default. This includes setting the ami_id variable to the ID of the AMI you just built.
  3. Run terraform init.
  4. Run terraform plan.
  5. If the plan looks good, run terraform apply.

Connect to Kafka

Check out the Connecting to Kafka brokers documentation for instructions.

Questions? Ask away.

We're here to talk about our services, answer any questions, give advice, or just to chat.

Ready to hand off the Gruntwork?