Runs embedded, in-memory Apache Kafka and Apache ZooKeeper instances. Helpful for integration testing.
The code in this project was extracted from kafka-storm-starter to allow for easier reuse in other projects.
Table of Contents
With this project you can run in-memory instances of:
- Kafka -- see KafkaEmbedded
- ZooKeeper -- see ZooKeeperEmbedded
- A ready-to-use Kafka and ZooKeeper "cluster" -- see KafkaZooKeeperCluster
- Java 7
- Scala 2.10
This project is published via Sonatype.
- Snapshots are available in the Maven repository at https://oss.sonatype.org/content/repositories/snapshots
- Releases are available on Maven Central.
Example 1, using a snapshot:
// In build.sbt
resolvers ++= Seq("sonatype-snapshots" at "https://oss.sonatype.org/content/repositories/snapshots")
libraryDependencies ++= Seq("com.miguno" % "kafka_embedded_2.10" % "0.1.0-SNAPSHOT")
Example 2, using a release (note: no release has been published yet!):
// In build.sbt
libraryDependencies ++= Seq("com.miguno" % "kafka_embedded_2.10" % "0.1.0")
A full example of an integration test using in-memory instances of Kafka and ZooKeeper is available at KafkaZooKeeperClusterSpec.
See CHANGELOG.
Code contributions, bug reports, feature requests etc. are all welcome.
If you are new to GitHub please read Contributing to a project for how to send patches and pull requests to kafka-embedded.
Copyright © 2014 Michael G. Noll
See LICENSE for licensing information.