You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
CreatePorts was creating a port name based on the index of the port in
the *current reconcile*. This could be different to the absolute index
of the port if ports had been partially created in a previous reconcile.
We fix this by passing all current state into CreatePorts so it can
create an absolute index. This also ensures that partially created ports
will be persisted on failure so we don't have to rely on adoption in the
next reconcile.
returnfmt.Errorf("length of desired ports (%d) is not equal to the length of ports to create (%d) + the length of ports that already exist (%d)", len(desiredPorts), len(portsToCreate), len(openStackCluster.Status.Bastion.DependentResources.Ports))
// Sanity check that the number of ports that have been put into PortsStatus is equal to the number of desired ports now that we have created them all.
returnfmt.Errorf("length of ports that already exist (%d) is not equal to the length of desired ports (%d)", len(openStackCluster.Status.Bastion.DependentResources.Ports), len(desiredPorts))
returnfmt.Errorf("length of desired ports (%d) is not equal to the length of ports to create (%d) + the length of ports that already exist (%d)", len(desiredPorts), len(portsToCreate), len(openStackMachine.Status.DependentResources.Ports))
// Sanity check that the number of ports that have been put into PortsStatus is equal to the number of desired ports now that we have created them all.
returnfmt.Errorf("length of ports that already exist (%d) is not equal to the length of desired ports (%d)", len(openStackMachine.Status.DependentResources.Ports), len(desiredPorts))
0 commit comments