This is an automated email from the ASF dual-hosted git repository. tsato pushed a commit to branch release-1.10.x in repository https://gitbox.apache.org/repos/asf/camel-k.git
commit d13902ff33f024bd0d4f5f46149f00a3221e6a44 Author: Tadayoshi Sato <[email protected]> AuthorDate: Wed Nov 16 16:45:09 2022 +0900 fix(controller): Ready condition message not always taken from Camel Health Checks Fix #3761 --- pkg/controller/integration/monitor.go | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/pkg/controller/integration/monitor.go b/pkg/controller/integration/monitor.go index fe59feea2..5bb26171c 100644 --- a/pkg/controller/integration/monitor.go +++ b/pkg/controller/integration/monitor.go @@ -237,7 +237,12 @@ func (action *monitorAction) updateIntegrationPhaseAndReadyCondition( return err } + readyPods, unreadyPods := filterPodsByReadyStatus(runningPods, controller.getPodSpec()) + if done, err := controller.checkReadyCondition(ctx); done || err != nil { + // There may be pods that are not ready but still probable for getting error messages. + // Ignore returned error from probing as it's expected when the ctrl obj is not ready. + _ = action.probeReadiness(ctx, environment, integration, unreadyPods) return err } if done := checkPodStatuses(integration, pendingPods, runningPods); done { @@ -245,7 +250,6 @@ func (action *monitorAction) updateIntegrationPhaseAndReadyCondition( } integration.Status.Phase = v1.IntegrationPhaseRunning - readyPods, unreadyPods := filterPodsByReadyStatus(runningPods, controller.getPodSpec()) if done := controller.updateReadyCondition(readyPods); done { return nil }
