Fixing ports is not recommended by Test containers as we're - by nature - evolving into volatile environments that should be dynamically configurable / re-configurable. All the ports exposed by a testcontainer should be dynamic with the ability to retrieve them using a dedicated method.
Description
The setHttpExposedPort(int httpPort) and setGrpcExposedPort(int grpcPort) methods where introduced for debugging purpose and specific needs of the Quarkus DevServices but are no longer needed as we now know how to use dynamic ports on Quarkus use-cases ;-)
They can be removed.
Implementation ideas
Remove both methods for fixing Http and Grpc ports.
Reason/Context
Fixing ports is not recommended by Test containers as we're - by nature - evolving into volatile environments that should be dynamically configurable / re-configurable. All the ports exposed by a testcontainer should be dynamic with the ability to retrieve them using a dedicated method.
Description
The
setHttpExposedPort(int httpPort)
andsetGrpcExposedPort(int grpcPort)
methods where introduced for debugging purpose and specific needs of the Quarkus DevServices but are no longer needed as we now know how to use dynamic ports on Quarkus use-cases ;-)They can be removed.
Implementation ideas
Remove both methods for fixing Http and Grpc ports.