Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Inconsistent probe default values when changing the probe configs versus deploying #541

Open
hoyhbx opened this issue Mar 29, 2023 · 0 comments

Comments

@hoyhbx
Copy link
Contributor

hoyhbx commented Mar 29, 2023

Description

(Describe the feature, bug, question, proposal that you are requesting)
We found that the configurations for the readinessProbe and livenessProbe are only set with default value when the entire probe configuration is nil.
When we do not specify any probe configuration, all the configs, e.g. initialDelaySeconds, timeout_seconds are set with default values, such as 10 seconds.
Then when we deploy the zookeeper cluster with spec.probes.livenessProbe.initialDelaySeconds as 5 seonds, all other fields are set with 1 seconds now.
But if we first have a deployed zookeeper cluster, and then change spec.probes.livenessProbe.initialDelaySeconds to 5 seconds, all other fields would have the correct default value.

Importance

(Indicate the importance of this issue to you (blocker, must-have, should-have, nice-to-have))
Importance: should-have

Location

(Where is the piece of code, package, or document affected by this issue?)
The default is set here:

if s.LivenessProbe == nil {

Suggestions for an improvement

The default values should be set on per field basis, rather than only when the entire struct is nil, to avoid the inconsistency

(How do you suggest to fix or proceed with this issue?)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant