Oct 8, 2018

Textual description of firstImageUrl

Setup Kafka and Zookeeper with brew(homebrew) on Mac operating system: Use Kafka tool(UI) to Publish message and monitor Kafka topic message.

Kafka is publish subscribe messaging system which are most commonly used in asynchronous work flow. Homebrew is a software package management system that simplifies the installation of software on Apple's macOS operating system. Using brew Kafka and Zookeeper can installed & setup with ease.

Install zookeeper using brew(homebrew):
brew install zookeeper
Updating Homebrew...
==> Auto-updated Homebrew!
Updated 2 taps (homebrew/core, homebrew/cask).
==> New Formulae
bundletool         geant4             i2pd               mallet             opensubdiv         opentracing-cpp    stanford-corenlp   tdlib
==> Updated Formulae
....
.....
==> Downloading https://homebrew.bintray.com/bottles/zookeeper-3.4.12.high_sierra.bottle.tar.gz
######################################################################## 100.0%
==> Pouring zookeeper-3.4.12.high_sierra.bottle.tar.gz
==> Caveats
To have launchd start zookeeper now and restart at login:
  brew services start zookeeper
Or, if you don't want/need a background service you can just run:
  zkServer start
==> Summary
๐Ÿบ  /usr/local/Cellar/zookeeper/3.4.12: 242 files, 32.9MB
Where is installation directory of zookeeper : /usr/local/Cellar/zookeeper

Install Kafka Using brew(hombrew):
➜  brew install kafka
Updating Homebrew...
==> Downloading https://homebrew.bintray.com/bottles/kafka-2.0.0.high_sierra.bottle.tar.gz
######################################################################## 100.0%
==> Pouring kafka-2.0.0.high_sierra.bottle.tar.gz
==> Caveats
To have launchd start kafka now and restart at login:
  brew services start kafka
Or, if you don't want/need a background service you can just run:
  zookeeper-server-start /usr/local/etc/kafka/zookeeper.properties & kafka-server-start /usr/local/etc/kafka/server.properties
==> Summary
๐Ÿบ  /usr/local/Cellar/kafka/2.0.0: 160 files, 46.8MB
Where is installation directory of Kafka : /usr/local/Cellar/kafka


Kafka Producer and Consumer(Command line tool)

Create Kafka topic: Create topic "topic-devinline-1" with replication factor 1 and partition 1
➜  bin pwd
/usr/local/Cellar/kafka/2.0.0/bin
➜  bin sh kafka-topics --create --zookeeper localhost:2181 --replication-factor 1 --partitions 1 --topic topic-devinline-1 
Created topic "topic-devinline-1".

Start producer:
➜  bin kafka-console-producer --broker-list localhost:9092 --topic topic-devinline-1                       
>Hello, Fist message
>Bye, Message
>
Start consumer:
➜  bin kafka-console-consumer --bootstrap-server localhost:9092 --topic  topic-devinline-1 --from-beginning
Hello, Fist message
Bye, Message

Kafka UI tool(Kafka Tool)

An UI tool to analyse and post/consume messages in topic. Download Kafka tool
As we have setup Zookeeper and Kafka locally, we can use following configuration to setup Kafka tool.

Analyse Kafka Topic through UI:
Open Topic "topic-devinline-1" and partition-0. Click green play button and find both message posted earlier.

Post Message from UI tool in Kafka topic:
1. Select Partition-0, Select Data tab and Click + 
2. Post message in text-box and click Add.
3. Click on green-play button and message posted is available in topic.


Note: If you find text box for Key also, provide a key along with message. It can be configured in preferences.
Kafka tool -> Preferences -> topics -> Default content type (Key = No Key)
Location: Bengaluru, Karnataka, India

27 comments:

  1. I thought protecting the website from the hackers is a hectic task. This post makes it easy for the developers and business people to protect the website. Keep sharing posts like this…
    Hire Web Developerc
    Hire Wordpress Programmer
    Hire PHP Developer India
    Mobile App Development India
    Hire Opencart Developer

    ReplyDelete
  2. My friend website has been infected with malware. The tips shared in this post helps me in a better way and guide me to protect my website.
    Hire Dedicated Wordpress Developer
    Smarty Developers
    Hire Dedicated Web Developers
    Hire Dedicated Php Developer
    Hire Dedicated Opencart Developers

    ReplyDelete
  3. It's a magnificent blog and it was very informative while reading. I look forward to reading more of your blogs. More info please visit:

    Hire Cake Php Developer
    Hire Phonegap Developer
    Hire Dedicated Laravel Developer
    Hire Dedicated Developers

    ReplyDelete
  4. Everything has its value. Thanks for sharing this informative information with us. GOOD works! satta king

    ReplyDelete
  5. A round of applause for your article.Much thanks again. Really Cool. Satta king

    ReplyDelete
  6. Super site! I am Loving it!! Will return once more, I’m taking your food additionally, Thanks. Oregon Business Registry

    ReplyDelete
  7. Very awesome!!! When I seek for this I found this website at the top of all blogs in search engine. Oregon Business Registry

    ReplyDelete
  8. I want to say thanks to you. I have bookmark your site for future updates. Oregon Business Registry

    ReplyDelete
  9. wow your arctile was very informative and it has solved my many quiries.
    Please more information on different topic please visit these links given bellow...
    Satta Bazar

    ReplyDelete
  10. I truly like you're composing style, incredible data, thankyou for posting. ๋จนํŠ€๊ฒ€์ฆ

    ReplyDelete
  11. I want to say thanks to you. I have bookmark your site for future updates. ํ† ํ† ์‚ฌ์ดํŠธ

    ReplyDelete
  12. It is extremely nice to see the greatest details presented in an easy and understanding manner. ๋จนํŠ€์‚ฌ์ดํŠธ

    ReplyDelete
  13. Mick Youthful is experts in web developers denver in Lincoln and also has a firm called Regional Professions Website Design that are experts in making web sites for neighborhood professions such as plumbing technicians, electrical contractors, painter and also designers, etc.

    ReplyDelete
  14. I am very impressed with your writing I couldn't think of this, but it's amazing! I wrote several posts similar to this one, but please come and see! ํ† ํ† ์‚ฌ์ดํŠธ

    ReplyDelete
  15. I’m not sure exactly why but this weblog is loading incredibly slow for me. Is anyone else having this problem or is it a problem on my end? I’ll check back later on and see if the problem still exists. ์•ˆ์ „๋†€์ดํ„ฐ

    ReplyDelete
  16. What an interesting story! I'm glad I finally found what I was looking for Excellent reading ์•ˆ์ „๋†€์ดํ„ฐ, I read a lot of posts but I am really impressed with your post. Thanks sir, I will look into this article. To know about me, try talking to ์‚ฌ์„คํ† ํ† ์‚ฌ์ดํŠธ.

    ReplyDelete
  17. Hello ! I am a student writing a report on the subject of your post.Your article is an article with all the content and topics. I've ever wanted . Thanks to this, it will be of great help to the report I am preparing now.Thanks for your hard work. And if you have time, please visit my site as well. The site name is ํ† ํ† ์ปค๋ฎค๋‹ˆํ‹ฐ.Thank you for this wonderful post! It has long been extremely helpful. ์‚ฌ์„คํ† ํ† ์‚ฌ์ดํŠธI wish that you will carry on posting your knowledge with us.Simply unadulterated brilliance from you here. I have never expected something not as much as this from you and ๋จนํŠ€๊ฒ€์ฆ have not confounded me by any reach out of the inventive vitality. I acknowledge you will keep the quality work going on.


    ReplyDelete