-
Notifications
You must be signed in to change notification settings - Fork 243
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
cronjob suspend failed #4842
Comments
The above-mentioned problem exists in v2.4.x & upgraded setups( v2.4.x to v2.5.2) But On a fresh install of v2.5.1 or v2.5.2, they cannot reproduce the issue because it's sending the right parameter ("restartPolicy":"Never"). The main culprit is "restartPolicy": "Always" parameter is passed while performing the suspend cron job operation, and the expected value is "restart policy: Never." Due to that, suspend operation is returned with status code422. And when you refresh the page, it shows the cronjob is active because the previous operation is not completed successfully and failed with the below error message: {"baseType":"error","code":"Invalid","message":"CronJob.batch "testcron" is invalid: spec.jobTemplate.spec.template.spec.restartPolicy: Unsupported value: "Always": supported values: "OnFailure", "Never"","status":422,"type":"error"} |
Hi Team, Any update on this. |
Internal reference: SURE-2605 Not sure what can be fixed here based on Vue and Ember, especially if 2.5.1+ resolves this. Need to investigate. |
Checking the code for 2.6.4, it looks like the dashboard does the right thing here. |
Verified on 2.6.4 in old UI - no longer an issue. |
@nwmac @Jono-SUSE-Rancher what does team 1 need to do here? No longer an issue? |
Dev-validated in new UI of @Allen-yan, maybe I am missing something about CronJobs, but what does redeploying entail? If I modify its labels and even image, then the same cronjob still exists and isn't really redeployed, only its jobs and ultimately pods will be different when it's time to run another job. |
On 2.6-head
|
What kind of request is this bug:
Steps to reproduce (least amount of steps as possible):
Result:
The cronjob is active and the suspended icon disappeared ...
Other details that may be helpful:
The PUT request's response:
"CronJob.batch "update-b-asset-withdraw" is invalid: spec.jobTemplate.spec.template.spec.restartPolicy: Unsupported value: "Always": supported values: "OnFailure", "Never"
REDEPLOY button update the cronjob's metadata restartPolicy to "Always" , but cronjob does not support it.
So when I suspend the job , failed
Environment information
rancher/rancher
/rancher/server
image tag or shown bottom left in the UI):rancher/rancher v2.3.4
gz#13569
The text was updated successfully, but these errors were encountered: