Using Apache Kafka from CFML
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
com
lib
LICENSE
README.md
consumer.cfm
index.cfm
send.cfm
server.json

README.md

Using Apache Kafka from CFML

Examples of using apache kafka with cfml.

Installation

Kakfa

  cd <kafka-dir>
  sudo ./bin/zookeeper-server-start.sh -daemon config/zookeeper.properties
  sudo ./bin/kafka-server-start.sh -daemon config/server.properties
  • Create our test topic, mytopic:
  sudo ./bin/kafka-topics.sh --create --topic mytopic --partitions 5 --replication-factor 1 --zookeeper localhost:2181
  • start a console kafka client, so you can see the messages that we will send to it:
  ./bin/kafka-console-consumer.sh --bootstrap-server localhost:9092 --topic  mytopic --from-beginning

CFML

    cd cfml-kafka
    commandbox> start server libDirs=lib
  • From the website that opens commandbox, you can send messages to "mytopic" topic and you can see it in the kafka client console.