반응형

맥(MacOS) - M1 Apple Silicon - 카프카 (kafka) 설치 및 실행

 

개발 환경

  • Mac OS (Apple Silicon M1)

 

1. apache-kafka binary 버전 다운로드

2. 압축해제

3. ZooKeeper 실행

4. KafkaServer 실행

5. 토픽 (topic) 생성

6. 이벤트 테스트

 

 

1. apache-kafka binary 버전 다운로드

https://www.apache.org/dyn/closer.cgi?path=/kafka/3.0.0/kafka_2.12-3.0.0.tgz

 

2. 압축해제

 

3. ZooKeeper 실행

1
.../kafka_2.13-3.0.0/bin/zookeeper-server-start.sh .../kafka_2.13-3.0.0/config/zookeeper.properties

 

4. KafkaServer 실행

1
.../kafka_2.13-3.0.0/bin/kafka-server-start.sh .../kafka_2.13-3.0.0/config/server.properties

 

5. 토픽 (topic) 생성

1
.../kafka_2.13-3.0.0/bin/kafka-topics.sh --create --topic topic --bootstrap-server localhost:9092 --replication-factor 1 --partitions 1

 

6. 이벤트 테스트

    6.1. producer

1
.../kafka_2.13-3.0.0/bin/kafka-console-producer.sh --topic quickstart-events --bootstrap-server localhost:9092

 

    6.2. consumer

1
.../kafka_2.13-3.0.0/bin/kafka-console-consumer.sh --topic quickstart-events --from-beginning --bootstrap-server localhost:9092

 


참고

https://www.apache.org/dyn/closer.cgi?path=/kafka/3.0.0/kafka_2.12-3.0.0.tgz

 

Apache Downloads

We suggest the following site for your download: https://dlcdn.apache.org/kafka/3.0.0/kafka_2.12-3.0.0.tgz Alternate download locations are suggested below. It is essential that you verify the integrity of the downloaded file using the PGP signature (.asc

www.apache.org

https://kafka.apache.org/quickstart

 

Apache Kafka

Apache Kafka: A Distributed Streaming Platform.

kafka.apache.org

 

 

 

반응형