Conversation
Also improved OPTIONS http method handling to better conform with the http spec.
|
Thanks for changing the title! I use those to triage what I review and the old title didn't help! |
|
No worries, I realized after I hit submit that the old title was pretty opaque, especially if you were scanning through the PR list. |
| } | ||
| } | ||
| } | ||
| void executeHandler(RestRequest request, RestChannel channel) throws Exception { |
There was a problem hiding this comment.
Sneaky indentation change snuck in.
|
I like it! @jasontedor filed the original bug and will probably want to look too! |
|
Thanks for the review @nik9000. Just realized my updates are tab indented - will change to space indents to match the ES code style. Sorry that snuck in, was working on something else with tab indents and forgot to change the style. |
It is cool! I suspect the build would warn you about that with |
|
@jbertouch I gave it a first pass and it looks great. Regarding
you can override the |
|
@jasontedor Thank you for the review. I can't see a |
|
@jbertouch Nope, I'm referring to a protected method on |
|
Ah, sorry I see it now. I hadn't merged in the latest commits from master in a while. |
|
@jasontedor Updated the test class to extend |
| * <a href="https://tools.ietf.org/html/rfc2616#section-10.4.6">HTTP/1.1 - | ||
| * 10.4.6 - 405 Method Not Allowed</a>). | ||
| */ | ||
| public void testUnsupportedMethodResponseHTTPHeader() throws Exception { |
In this test, an OPTIONS method request is valid, and should not return a 405 error.
|
@jasontedor I had some time to review issue #17853 on a flight between LA and Sydney. Here's a high-level outline of my updated solution: PathTrie
RestController
|
|
One other thing, I guess |
|
@jasontedor, any chance of reviewing these changes? I can close the PR if it's redundant. |
|
Since this is a community submitted pull request, a Jenkins build has not been kicked off automatically. Can an Elastic organization member please verify the contents of this patch and then kick off a build manually? |
|
@jbertouch I've asked @dakrone to take over reviewing this one; he'll work with you on getting this one across the finish line! |
|
Hi @jbertouch! We would really love to get this PR in as soon as we can, so it can be released! Would you be adverse to me helping out by cherry-picking your commits to a new branch and bringing this up to date with the current master branch? I know Github has a feature where repo members can push to a pull request's branch to collaboratively develop, but I think this PR was opened prior to that feature, so I can't push and help resolve the conflicts without a new branch/pr. |
|
Hi @dakrone, that's great to hear - sorry about the delay in getting back to you. Please go ahead and move my commits to a new branch. |
|
Thanks! I've opened #24437 to continue this so I'm going to close this one. |
First pass at closing #15335. The new behavior for the
RestController#executeHandlermethod is as follows:The tests extend
ESIntegTestCaserather than theESSingleNodeTestCase, ashttp.enabledis set to false in the latter class.Let me know if you think the tests should be broader - they could be improved by pulling in a random selection of REST endpoints to test, rather than the existing hardcoded endpoints.