-
Notifications
You must be signed in to change notification settings - Fork 5.5k
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
[BUG] salt runner doesn't store results in job cache #61729
Comments
FWIW, this definitely shows up in the jobs cache:
But it looks like it's missing any kind of other file with that name or contents:
that produces nothing as the output. |
this should fix saltstack#61729 for salt commands run via remote minions, the returner save_load function is effectively called twice-- once via salt.master.ClearFuncs.publish when the job starts and then again via store_job called from salt.master.AESFuncs.return when each minion returns. store_job when called via the minion return path ("_return") will call save_load in addition to the returner function when it seems it should only call the returner. there's an additional problem which is that for salt runners the job data is saved via a call to store_job in which case both the returner *and* save_load should be called at once this change attempts to give store_job the ability to distinguish between situations in which it should call save_load or just the returner by checking for the presence of the "tgt" attribute
Seems to be fixed in 3006.1
|
Hey some updates,
and one more thing that is different now with raas plugin enabled, this one without the raas plugin did not retrieve the orchestration jid but it was not throwing this error, now it throws this error
So for sure, yes functons are broken, and yes the raas plugin makes a difference I can see the JIDs in the SSE Activity page. I also tried running the orchestration as a job from SSE, same results |
I believe this particular issue was fixed in #65023 and is included in Salt 3006.3 and later. @aaronknister Could you please test it again using the latest Salt version? |
Description
Salt runners don't appear to store results in the job cache. This worked on older versions of salt (~2015 time frame at least).
Querying the result of a salt runner job shows an Error and it's missing expected attributes such as Function:
Setup
Observed on the salt 3004rc1 container and the tip of master (run inside a container).
Steps to Reproduce the behavior
salt-run -l info jobs.list_jobs 2>&1 | grep 'Runner completed' | awk '{ print $5 }' | xargs --no-run-if-empty -n1 salt-run jobs.print_job
Expected behavior
Output should not contain an Error field and should contain Function attribute (and others) as shown below:
Screenshots
Console output included above
Versions Report
salt --versions-report
(Provided by running salt --versions-report. Please also mention any differences in master/minion versions.)Additional context
None at this time
The text was updated successfully, but these errors were encountered: