bharatviswa504 commented on a change in pull request #2912:
URL: https://github.com/apache/ozone/pull/2912#discussion_r767993185
##########
File path:
hadoop-ozone/s3gateway/src/main/java/org/apache/hadoop/ozone/s3/endpoint/ObjectEndpoint.java
##########
@@ -828,22 +832,29 @@ private CopyObjectResponse copyObject(String copyHeader,
}
int pos = header.indexOf('/');
if (pos == -1) {
- OS3Exception ex = S3ErrorTable.newError(S3ErrorTable
- .INVALID_ARGUMENT, header);
+ OS3Exception ex = S3ErrorTable.newError(INVALID_ARGUMENT, header);
ex.setErrorMessage("Copy Source must mention the source bucket and " +
"key: sourcebucket/sourcekey");
throw ex;
}
- return Pair.of(header.substring(0, pos), header.substring(pos + 1));
+ try {
+ String bucket = header.substring(0, pos);
Review comment:
Question:
What is the reason not to do urlDecode on the copyHeader if it is urlEncoded?
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]