squakez commented on code in PR #4182:
URL: https://github.com/apache/camel-k/pull/4182#discussion_r1150841810


##########
pkg/apis/camel/v1/trait/health.go:
##########
@@ -54,4 +54,19 @@ type HealthTrait struct {
        ReadinessSuccessThreshold int32 `property:"readiness-success-threshold" 
json:"readinessSuccessThreshold,omitempty"`
        // Minimum consecutive failures for the readiness probe to be 
considered failed after having succeeded.
        ReadinessFailureThreshold int32 `property:"readiness-failure-threshold" 
json:"readinessFailureThreshold,omitempty"`
+
+       // Configures the startup probe for the integration container (default 
`true`).
+       StartupProbeEnabled *bool `property:"startup-probe-enabled" 
json:"startupProbeEnabled,omitempty"`

Review Comment:
   I think the Kubernetes doc page [1] has the better explaination:
   > The 
[kubelet](https://kubernetes.io/docs/reference/command-line-tools-reference/kubelet/)
 uses liveness probes to know when to restart a container. For example, 
liveness probes could catch a deadlock, where an application is running, but 
unable to make progress. Restarting a container in such a state can help to 
make the application more available despite bugs.
   >
   >The kubelet uses readiness probes to know when a container is ready to 
start accepting traffic. A Pod is considered ready when all of its containers 
are ready. One use of this signal is to control which Pods are used as backends 
for Services. When a Pod is not ready, it is removed from Service load 
balancers.
   >
   >The kubelet uses startup probes to know when a container application has 
started. If such a probe is configured, it disables liveness and readiness 
checks until it succeeds, making sure those probes don't interfere with the 
application startup. This can be used to adopt liveness checks on slow starting 
containers, avoiding them getting killed by the kubelet before they are up and 
running
   
   I think since in the integration space we're typically dealing with backend 
services we're mostly interested in readiness (by default). However, the 
presence of the parameters will let the final user to configure according to 
her requirements.
   
   [1] 
https://kubernetes.io/docs/tasks/configure-pod-container/configure-liveness-readiness-startup-probes/



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to