Files
floci/src/test/java
Robin BaeckmanandRobin Baeckman dfeb05a400 fix(docker): adopt a surviving container on the network it was created on (#5811)
When Floci runs in Docker, a sidecar it creates that publishes ports (a
k3s node, the ECR registry, a Redshift engine, the Floci UI, the AppSync
JS runtime) starts on the default bridge and is then connected to its
service's network.
createAndStart resolves the endpoint on that network. Adopting a
surviving container after a restart took the first address in Docker's
inspect response instead, which in practice is usually the bridge, and
Floci is not on the bridge. Every probe of the adopted container failed;
an EKS cluster stayed CREATING.

ContainerLifecycleManager.adopt gains an overload that takes the network
to prefer and resolves each endpoint with resolveEndpoint(inspect, port,
network). Each caller passes the network it creates its container on,
through ContainerBuilder.resolveDockerNetwork with the argument it gives
withDockerNetwork. A survivor that is not on that network falls back to
the first address, as before; the two-argument adopt is unchanged.

Co-authored-by: Robin Baeckman <27041454+RobinBaeckman@users.noreply.github.com>
2026-10-16 11:50:07 -04:00
..