Skip to content

org.testcontainers.kafka.KafkaContainer is not reusable #9143

@eddumelendez

Description

@eddumelendez

Discussed in #9119

Originally posted by cer August 17, 2024
I discovered that kafka.KafkaContainer is not reusable.
As far as I can tell, it's because of the configure() method:

withEnv("KAFKA_CONTROLLER_QUORUM_VOTERS", controllerQuorumVoters);

The value of KAFKA_CONTROLLER_QUORUM_VOTERS uses the random network alias generated by GenericContainer's constructor.

Is there a reason why it doesn't simply use localhost?

Thoughts?

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions