GithubHelp home page GithubHelp logo

apache_kafka's Introduction

Apache Kafka Cookbook

Install and configure apache kafka 0.8.2.1.

Default installation assumes a local zookeeper instance (see SimpleFinance/chef-zookeeper).

Based off the work of Federico Gimenez Nieto

Cookbooks

  • apache_kafka::default
    • Full default install
  • apache_kafka::install
    • Install the application, but do not start
    • Useful for wrapper cookbooks that want custom configurations before starting
  • apache_kafka::configure
    • Create the broker configs
  • apache_kafka::service
    • Create service upstart scripts

Usage

Create a single kafka node with a single zookeeper instance on the same host.

bundle install --path vendor/bundle
bundle exec berks install
bundle exec kitchen converge
bundle exec kitchen login

Create a new kafka topic with 3 partitions

sudo /usr/local/kafka/bin/kafka-topics.sh --create --topic event-stream --replication-factor 1 --partitions 3 --zookeeper localhost:2181
# [2015-02-06 00:49:08,721] INFO Topic creation {"version":1,"partitions":{"2":[0],"1":[0],"0":[0]}} (kafka.admin.AdminUtils$)
# Created topic "event-stream".

Verify the new topic exists

sudo /usr/local/kafka/bin/kafka-topics.sh --describe --zookeeper localhost:2181
# Topic:event-stream  PartitionCount:3    ReplicationFactor:1 Configs:
#     Topic: event-stream Partition: 0    Leader: 0   Replicas: 0 Isr: 0
#     Topic: event-stream Partition: 1    Leader: 0   Replicas: 0 Isr: 0
#     Topic: event-stream Partition: 2    Leader: 0   Replicas: 0 Isr: 0

Delete the topic

sudo /usr/local/kafka/bin/kafka-topics.sh --delete --topic event-stream --zookeeper localhost:2181
# Topic event-stream is marked for deletion.
# Note: This will have no impact if delete.topic.enable is not set to true.

Contributing

  • Standard PR model with details on why

Version Control

Major.Minor.Patch managed via thor

Sample patch bump to master after PR merge

git checkout master
git pull
bundle exec thor version:bump patch

Test Converge

bundle install --path vendor/bundle
bundle exec berks install
bundle exec kitchen converge

apache_kafka's People

Contributors

atongen avatar darron avatar davidgiesberg avatar dorianzaccaria avatar justizin avatar mathyourlife avatar petere avatar vkhatri avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.