theglobalsolutions

Apache Kafka Powered by GlobalSolutions
Kafka
Powered by GS

Apache Kafka is a publish-subscribe based fault-tolerant messaging system. In comparison to other messaging systems, Kafka has better throughput,
built-in partitioning, replication, and inherent fault-tolerance, which makes it a good fit for large-scale message processing applications.



We have packaged and hardened the Kafka service offering so our customers can seamlessly subscribe to this offering with no setup work from their end.
All that you have to do is subscribe to this offering from the marketplace, create topics, publish messages from the producers and start consuming with the consumers.






 
Kafka service 

Installation location and accessing Kafka -

Kafka is under C:\kafka
Zookeeper is under C:\zookeeper

The instance is tuned in a way that one can start using the instance immediately as the Kafka and Zookeeper are installed as a service and is in a running state.You can start and stop the services by going to Administrative tool.

To execute any Kafka related commands, you can directly go to the command prompt icon on the desktop and type in the commands.

 

Run the following command to create a topic : test


1. Create a topic with the name “test” and a replication factor of 1, as we have only one Kafka server running.
2. Open a new command prompt by clicking on command prompt icon or by going to C:\kafka\bin\windows>
3. Type the following command and hit enter

  • C:\kafka\bin\windows>kafka-topics.bat --create --zookeeper localhost:2181 --replication-factor 1 --partitions 1 --topic test
 
Steps to publish a message to the topic.

You can create a producer from the command line by running the following command.It expects the Kafka server’s hostname and port, along with a topic name as arguments,and this will be producer command prompt.

  • C:\kafka\bin\windows>kafka-console-producer.bat --broker-list localhost:9092 --topic test
 
Steps to consume the message as a consumer.

You can create a Kafka consumer from the command line by running the following command . It expects the hostname and port, along with a topic name as arguments, and this will be consumer command prompt.

  • C:\kafka\bin\windows>kafka-console-consumer.bat --bootstrap-server localhost:9092 --topic test
 
How to check ?

Now type anything in the producer command prompt and press Enter, and you should be able to see the message in the other consumer command prompt.
 
How to connect to kafka from outside? Or I am not able to publish or consume messages from Kafka?

You need to make the following changes in the server.properties file with the right domain name and port. Please open the server.properties file which is under C:\kafka\config\ . Locate the following property and change the value of the property to your public DNS. The plaintext in the property has to be left as is, just change the public DNS of your Ec2 instance which you can get it from AWS console.

advertised.listeners=PLAINTEXT://your.host.name:9092
 


Support

Please contact us at support@theglobalsolutions.net for any questions on this offering in AWS Marketplace.
copyright - © 2016,The Globalsolutions LLC. or its affiliates. All rights reserved.