-
Notifications
You must be signed in to change notification settings - Fork 459
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
Pod isn't restarted when configmap is updated #197
Comments
Hey @jpkrohling , I would like to work on this. I have gone through the code where we are handling updates to the configmap. I would like to understand couple things.
Dint get the use of this. For restarting pod on configmap change, I guess we should do following -
Thoughts @jpkrohling ? |
Thank you for helping out!
Patches are less likely to get in conflict with full object updates. See #54 for more info.
Do you have any references on what's the recommendation on Kubernetes' documentation? A rolling update would be my preference, so that pod using the new configuration will have to first get into a running state before they are killed, preventing bad configs from causing an outage of the collector. |
I was coming from the thought process behind the configmap reloaders out there. For example - https://github.com/stakater/Reloader. This actually does the same, kills the pod when config changes. But as you said, as deployment itself is created/updated by controller, we could actually do a rolling update - which is better than simply killing the pod. I agree. To achieve this
Second point I am not sure how to implement using controller-runtime. |
I might need to look into more details, but apparently, the rollout restart command does something similar to the first option: |
@jpkrohling , went through above code links, as you said - its doing the same - annotating with timestamp. |
Sounds worth a try! |
When the collector's configuration has changed, the pods that are using the respective configmap should be restarted, and it currently isn't.
The text was updated successfully, but these errors were encountered: