We'll begin by installing the necessary software: Apache Kafka and OpenFire. Although Kafka is a distributed messaging system, it will work just fine installed as a single node, or even locally as part of a development environment. In a production environment, you will need to set up a cluster of one or more machines depending on your scaling requirements. The OpenFire server is not a clustered system and can be installed on a single node or locally.
Kafka depends on ZooKeeper for storing certain state information, much like Storm. Since Storm imposes a relatively light load on ZooKeeper, in many cases it is acceptable to share the same ZooKeeper cluster between both Kafka and Storm. Since we've already covered ZooKeeper installation in Chapter 2, Configuring Storm Clusters, here we'll just cover the running of the local ZooKeeper server that ships with Kafka and is suitable for a development environment.
Begin by downloading the 0.7.x release...