-
Notifications
You must be signed in to change notification settings - Fork 0
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Containerising App and verify Mongo and Kafka connections #16
Conversation
Verified mongo and Kafka and internally accessible from App
Quality Gate passedIssues Measures |
@@ -75,6 +110,9 @@ services: | |||
- GF_SECURITY_ADMIN_PASSWORD=admin | |||
volumes: | |||
- grafana-storage:/var/lib/grafana | |||
networks: | |||
- app-network |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@@ -2,13 +2,13 @@ spring.application.name=KafkaStudy | |||
kafka.regular.topic=my-topic | |||
regular.kafka.autostart=false | |||
reactive.kafka.autostart=true | |||
spring.kafka.consumer.bootstrap-servers=127.0.0.1:9092 | |||
spring.kafka.consumer.bootstrap-servers=kafka:9092 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
spring.kafka.consumer.group-id=demo-3 | ||
spring.kafka.consumer.auto-offset-reset=earliest | ||
spring.kafka.consumer.key-deserializer=org.apache.kafka.common.serialization.StringDeserializer | ||
spring.kafka.consumer.value-deserializer=org.apache.kafka.common.serialization.StringDeserializer | ||
spring.kafka.consumer.properties.session.timeout.ms=30000 | ||
spring.kafka.consumer.properties.heartbeat.interval.ms=10000 | ||
spring.data.mongodb.uri=mongodb://root:example@localhost:27017/testMongoDb?authSource=admin | ||
spring.data.mongodb.uri=mongodb://root:example@mongodb:27017/testMongoDb?authSource=admin |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
mongodb: | ||
image: mongo:latest | ||
container_name: mongodb-container | ||
container_name: mongodb |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
INSIDE Listener:
Purpose: This is used for communication between Kafka brokers and clients (like producers and consumers) that are within the Docker network. It is typically configured to listen on a specific internal IP address or hostname.
Example Usage: If you have other services running in the same Docker network (e.g., your Spring Boot application), they will connect to Kafka using the INSIDE listener.
OUTSIDE Listener:
Purpose: This listener is exposed to the outside world, allowing clients outside of the Docker network (such as applications running on your local machine) to connect to Kafka. This typically listens on localhost or a specific external IP address.
Example Usage: If you are testing Kafka from your local machine or another service outside the Docker network, you will connect using the OUTSIDE listener.
No description provided.