Introduction to Red Hat AMQ Streams
Last updated
Last updated
Basic Red Hat AMQ Streams:
go to lab folder 1-introduction-amq-streams
see detail of amq streams installation folder (you can install amq streams by download zip file from and unzip to your path )
example result
review in kafka/config, see detail of zookeeper configuration. we will use this file for config zookeeper.
First before we start Kafka, we have to start ZooKeeper, start zookeeper with command line (For testing, we start only 1 server.)
wait until zookeeper start complete
zookeeper terminal
wait unti kafka start complete
kafka broker terminal
open new terminal and check zookeeper and kafka process
example result
process "QuorumPeerMain" is zookeeper
process "Kafka" is kafka broker
List the topics using Kafka, open new terminal and run command
no topic show in terminal
create sample new topic which we will use
result of create topic command
List the topics again to see it was created.
Describe the topic to see more details:
example output
Start the console producer for create and send message to topic
Wait until it is ready (it should show >
).
Next we can consume the messages, open new terminal and run command
Once ready, back to producer terminal and send some message by typing the message payload and pressing enter to send. such as
see output in consumer terminal:
example result in terminal
exit from producer console by type ctrl+c in producer console terminal
You can also check the consumer groups:
example result
exit from consumer console by type ctrl+c in consumer console terminal
check the consumer groups again:
example result
run stop server command in another terminal
or type ctrl + c in kafka terminal and zookeeper terminal
check with jps command again (if stop complete, kafka and QuorumPeerMain will disappear)
review in kafka/config, see detail of server configuration. we will use this file for start kafka.
Next we can start Kafka Broker, open new terminal by repeat step in and run command (For testing, we start only 1 server.)