Passing 0 as the port should let you do this. This is how we get the tests to work without assuming a specific port is available. The KafkaServer.boundPort(SecurityProtocol) method can be used to get the port that was bound.
-Ewen On Tue, Nov 10, 2015 at 11:23 PM, Hemanth Yamijala <yhema...@gmail.com> wrote: > Hello, > > Is there any way to specify that the Kafka broker should bind to any > available port. This could be used, maybe for an embedded Kafka instance, > etc. > > Thanks > Hemanth > -- Thanks, Ewen