-
Notifications
You must be signed in to change notification settings - Fork 1.3k
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
support large payload in zk put API #7364
Conversation
Thanks for adding this! Can you add a test for this? |
@@ -139,7 +140,17 @@ public SuccessResponse putData( | |||
@ApiParam(value = "expectedVersion", required = true, defaultValue = "-1") @QueryParam("expectedVersion") | |||
@DefaultValue("-1") String expectedVersion, | |||
@ApiParam(value = "accessOption", required = true, defaultValue = "1") @QueryParam("accessOption") | |||
@DefaultValue("1") String accessOption) { | |||
@DefaultValue("1") String accessOption, | |||
@ApiParam(value = "payload") @Nullable Payload payload |
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.
We don't want it to be an api param, but the actual payload for the PUT http call. The payload should be the same as the content, but not as an api param. Also we need to change content to be optional
ffb519c
to
38207ba
Compare
Codecov Report
@@ Coverage Diff @@
## master #7364 +/- ##
============================================
+ Coverage 71.38% 71.46% +0.08%
- Complexity 4081 4083 +2
============================================
Files 1583 1583
Lines 81863 81868 +5
Branches 12238 12239 +1
============================================
+ Hits 58434 58507 +73
+ Misses 19466 19403 -63
+ Partials 3963 3958 -5
Flags with carried forward coverage won't be shown. Click here to find out more.
Continue to review full report at Codecov.
|
38207ba
to
354080d
Compare
@Jackie-Jiang can you check the PR now, I'll be updating tests coverage |
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.
LGTM otherwise
@@ -0,0 +1,101 @@ | |||
package org.apache.pinot.controller.api; |
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.
Missing license header
) { | ||
|
||
if (payload != null) { | ||
path = payload.getPath(); |
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.
We should only override the value when it is provided in the payload
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.
@Jackie-Jiang I've updated the requested changes
354080d
to
25b6431
Compare
draft remove query_param from payload rename payload content to data, remove required field in query params add test case for zk put method
update format
25b6431
to
24183b3
Compare
24183b3
to
36c2385
Compare
Description
support large payload in ZK put API, solve issue 7305
Upgrade Notes
Does this PR prevent a zero down-time upgrade? (Assume upgrade order: Controller, Broker, Server, Minion)
backward-incompat
, and complete the section below on Release Notes)Does this PR fix a zero-downtime upgrade introduced earlier?
backward-incompat
, and complete the section below on Release Notes)Does this PR otherwise need attention when creating release notes? Things to consider:
release-notes
and complete the section on Release Notes)Release Notes
Documentation