-
Notifications
You must be signed in to change notification settings - Fork 30
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
added option 'ignorable_codes' to also return failed REST calls #32
base: main
Are you sure you want to change the base?
Conversation
💚 CLA has been signed |
00b9d7b
to
f58fdfc
Compare
Any chance you can roll in the "form" change I made, too? They haven't been too quick on accepting pull requests for this plugin. |
Nice addition, however I think a better approach would be to make the |
Hmm... Yes. Need to think about it. So you mean that you need to give the codes of "valid" codes in an array of this option is set to |
I mean not having Not yet sure what the best approach would be to represent ranges, hopefully some other plugin is using smt similar already. |
@kares Found a bit time to further work on this. For now, I'm just doing exactly the same as the |
Also use the same logic. Only difference is that http codes between 200 and 299 are - as before - considered success. Other http codes are only considered success, if they are listed within 'ignorable_codes'.
I am not able to run |
Setting this option to
true
will return the response headers and response body also for failed REST calls. This means, unless there is an exception, settingignore_errors
totrue
will always succeed.The idea behind is to also be able to fetch the results for failed HTTP requests, parse them and - maybe - use that data within elasticsearch.