Question concerning K8s Operator and `allowNonRest...
# troubleshooting
t
Question concerning K8s Operator and
allowNonRestoredState
Been testing the 1.10.0 release of the K8s Operator and stumbled upon something odd (I think) I have a simple test job that simply generates number, does some calculation and prints them. Works fine for testing. I save the state, and when I do a
restartNonce
it saves the state, restarts and resumes from where it left off. All good 🙂 Now for testing purposes I changed the
uid
of an operator to something else and restarted the job again. As expected it could not map the state. Then i inserted the
allowNonRestoredState
in the operator config, which should put the
execution.savepoint.ignore-unclaimed-state: "true"
into the conf file. It does not. Not even when forcing a restart using
restartNonce
The `allowNonRestoredState`has
@SpecDiff(DiffType.IGNORE)
which could be the reason why, but I would expect a restart would take the variable into consideration. Settings the
execution.savepoint.ignore-unclaimed-state: "true"
myself in the
flinkConfiguration
section works fine, but that kind off makes the documented
allowNonRestoredState
redundant? Also the
allowNonRestoredState
does insert the correct settings when the job is running, but the idea here is that the job fails because it can't migrate state and then I want to mitigate this. Knowing before-hand is of course always a valid argument, but I think it should also work when it's failing. Anybody else experienced something similar or can just tell me what I might be doing wrong? 😉
g
The
allowNonRestoredState
setting simply sets the
execution.savepoint.ignore-unclaimed-state
so yes, technically it’s a bit redundant. But actually many settings are just helpers for most common configs so thats fine. I guess the `@SpecDiff(DiffType.IGNORE)`is debatable but the logic there is that if you change this field for a running job, this alone should not trigger an update. If you combine it with bumping the restartnonce then you will get a restart with allowNonRestored state set
But I would not be against changing the DiffType to upgrade because the scenario you mentioned sounds pretty common. You change this field when you get into trouble but then it “doesn’t work”
So overall +1 for changing the difftype to upgrade, please open a jira ticket 🙂
👍 1
t
Agree. Will do so as soon as i get my jira account approved 🙂