kafka/examples
Ailing Zhang e1f7bea157 kafka-1205; README in examples not update; patched by Ailing Zhang; reviewed by Jun Rao 2014-01-17 08:29:28 -08:00
..
bin KAFKA-141 Check and make sure that the files that have been donated have been updated to reflect the new ASF copyright;patched by nehanarkhede; reviewd by jjkoshy 2011-10-07 19:51:28 +00:00
src/main/java/kafka/examples kafka-896; merge 0.8 (988d4d8e65) to trunk; patched by Jun Rao; reviewed by Jay Kreps 2013-07-08 15:42:24 -07:00
README kafka-1205; README in examples not update; patched by Ailing Zhang; reviewed by Jun Rao 2014-01-17 08:29:28 -08:00
build.sbt Re-applied old patch from KAFKA-139 2012-12-14 17:12:38 -07:00

README

This directory contains examples of client code that uses kafka.

The default target for ant is kafka.examples.KafkaConsumerProducerDemo which sends and receives 
messages from Kafka server.

In order to run demo from SBT:
   1. Start Zookeeper and the Kafka server
   2. ./sbt from top-level kafka directory
   3. Switch to the kafka java examples project -> project kafka-examples
   4. execute run -> run
   5. For simple consumer demo, select option 1
      For unlimited producer-consumer run, select option 2

To run the demo using scripts: 

   1. Start Zookeeper and the Kafka server
   2. For simple consumer demo, run bin/java-simple-consumer-demo.sh
   3. For unlimited producer-consumer run, run bin/java-producer-consumer-demo.sh