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

Investigate better error detection #233

Open
lucidd opened this issue May 18, 2018 · 1 comment
Open

Investigate better error detection #233

lucidd opened this issue May 18, 2018 · 1 comment

Comments

@lucidd
Copy link
Member

lucidd commented May 18, 2018

Salt seems to have added an option called full_return which should give more metadata about the result such as success or failure indication. https://docs.saltstack.com/en/latest/ref/clients/#salt.client.LocalClient.cmd with that we should hopefully be able to detect errors more reliably.
with full_return

{"return": [{"minion1": {"jid": "20190318124528105688", "retcode": 0, "ret": true}}]}

without full_return

{"return": [{"minion1": true}]}

We should set full_return allways to true since we need the information for error detection.
full_return in the request to the api is on the same level as the client value for example.

We also need to adjust the gson type adapter responsible for parsing results and take the new error information into account.

One thing unknown is how this effects wheel and runner calls.

@rmartens-embotics
Copy link

My "solution" was to add retcode to the Return class and make it accessible in Jobs.Info. Not sure if this fully makes sense but it was enough for my purposes.

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

2 participants