-
Notifications
You must be signed in to change notification settings - Fork 844
Make sure, when plugins cause a GET request to fail, there is always a response body. #8643
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
Conversation
f709eb8 to
093aff5
Compare
|
As an alternative to HttpMsgComp.h, Alan proposes https://github.com/SolidWallOfCode/txn_box/blob/master/plugin/include/txn_box/ts_util.h / https://github.com/SolidWallOfCode/txn_box/blob/master/plugin/src/ts_util.cc |
093aff5 to
5ed24f5
Compare
|
[approve ci centos] |
5ed24f5 to
c27c199
Compare
c27c199 to
5b26267
Compare
…response body. Adds Au test with plugin forcing various errors on various hooks, with default body or set body.
5b26267 to
4a70a82
Compare
| // | ||
| // This class and the base class are pseudo-namespaces, have only static member functions (no data members). | ||
| // The manager data cannot simply be in the base class, because the (static member) continuation function that | ||
| // runs on the TXN_CLOSE hook would not be able to access it. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This comment improvement is not directly related to this PR.
| #include <ts/experimental.h> | ||
| #include <tscore/ink_defs.h> | ||
| #include <tscpp/util/PostScript.h> | ||
| #include <tscpp/util/TextView.h> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Changed double quotes to braces to make it clear these are not subdirs under xdebug.
| #include <tscore/ink_defs.h> | ||
| #include <tscpp/util/PostScript.h> | ||
| #include <tscpp/util/TextView.h> | ||
| #include <tscpp/api/Cleanup.h> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
No real change to xdebug, just from this header to make it available to all plugins.
| const char *reason = http_hdr_reason_lookup(s->http_return_code); | ||
| ; | ||
| build_response(s, &s->hdr_info.client_response, s->client_info.http_version, s->http_return_code, reason ? reason : "Error"); | ||
| build_error_response(s, s->http_return_code, reason ? reason : "Error", nullptr); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is the only real code change. Most of this PR is to add an Au test.
|
Is this an incompatible change? Since plugin which may have generated empty response bodies in some cases will not generate non-empty response bodies? |
|
This pull request has been automatically marked as stale because it has not had recent activity. Marking it stale to flag it for further consideration by the community. |
|
[approve ci autest] |
|
[approve ci autest] |
|
This was an ask from YCPI Prod. But, no point in fixing it if it's going to continue to rot in the Sun. |
Adds Au test with plugin forcing various errors on various hooks, with default body
or set body.