// Note: The Kafka Runnable must be created before the ZooKeeper
// Runnable when using shutdown hooks.
final KafkaServerRunnable kafkaServerRunnable = KafkaServerRunnable
.newInstance(kafkaConfigFile, true);
final ZooKeeperServerRunnable zooKeeperServerRunnable = ZooKeeperServerRunnable
.newInstance(zooKeeperConfig, true);
final Thread kafkaThread = new Thread(kafkaServerRunnable);
final Thread zkThread = new Thread(zooKeeperServerRunnable);
zkThread.start();