Skip to content
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

When run second consumer, the docker port changed automaticlly and previous consumer/producer disconnected #717

Open
wolfwell5 opened this issue Aug 11, 2022 · 1 comment

Comments

@wolfwell5
Copy link

image

After run up one producer, one consumer, everything is OK, **but when I run second consumer(sometimes run the third consumer**, the port of local machine changed automatily. then producer or consumer will disconnected... Not very familiar with docker/kafka, so don't know why this happen. Hope hear your sound, thx in advanced
@OneCricketeer
Copy link

If ports are changing on the same service, then it's crashing and you'll need to look at the server logs...

One solution - Don't use 3 Kafka brokers locally with plain port exposure. Main reason - you're "wasting" disk space/cycles if you have replication factor more than 1; you can use one broker with a static port.

Or, you need to edit the listeners on the three services such that their ports don't overlap, then statically assign them to your host

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants