-
-
Notifications
You must be signed in to change notification settings - Fork 8k
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
HubStatusServlet - use GET with query string instead of GET with body #2771
Conversation
da68765
to
b236b6e
Compare
can you make it allow both POST data and url parameter? I'm a bit concerned here about breaking people unnecessarily. |
I share the concerns of @lukeis -- It should continue support (although it is odd from an HTTP protocol point of view) All said, personally I'm in the opinion that the It's also worth mentioning that nodes query this servlet. |
It's now backward compatible with |
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.
Other than the inconsistent use of whitespace, this change looks good to me.
Any chance you can clean up the whitespace? :)
@@ -101,7 +102,10 @@ private JsonObject getResponse(HttpServletRequest request) throws IOException { | |||
if (request.getInputStream() != null) { | |||
JsonObject requestJSON = getRequestJSON(request); | |||
List<String> keysToReturn = null; | |||
if (requestJSON != null && requestJSON.has("configuration")) { | |||
|
|||
if (request.getParameter("configuration")!=null && !"".equals(request.getParameter("configuration"))) { |
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.
inconsistent use of whitespace here
keys.add(URLEncoder.encode("I'm not a valid key", "UTF-8")); | ||
keys.add(URLEncoder.encode("servlets", "UTF-8")); | ||
|
||
String query = "?configuration="+String.join(",",keys); |
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.
inconsistent use of whitespace here
@mach6 done |
@lukeis is it ok now? can you merge? |
X
in the preceding checkbox, I verify that I have signed the Contributor License Agreement