Interface ConnectionPorts
public interface ConnectionPorts
Provides access to the ports that can be used to connect to a
RunningService
.- Since:
- 3.1.0
- Author:
- Moritz Halbritter, Andy Wilkinson, Phillip Webb
- See Also:
-
Method Summary
-
Method Details
-
get
int get(int containerPort) Return the host port mapped to the given container port.- Parameters:
containerPort
- the container port. This is usually the standard port for the service (e.g. port 80 for HTTP)- Returns:
- the host port. This can be an ephemeral port that is different from the container port
- Throws:
IllegalStateException
- if the container port is not mapped
-
getAll
-
getAll
-