Copilot commented on code in PR #11426:
URL: https://github.com/apache/ozone/pull/11426#discussion_r4201280032


##########
hadoop-ozone/s3gateway/src/main/java/org/apache/hadoop/ozone/s3/endpoint/BucketEndpoint.java:
##########
@@ -109,7 +109,7 @@ Response handleGetRequest(S3RequestContext context, String 
bucketName) throws IO
     final String delimiter = queryParams().containsKey(QueryParams.DELIMITER) ?
         queryParams().get(QueryParams.DELIMITER) : null;
     final String encodingType = queryParams().get(QueryParams.ENCODING_TYPE);
-    final String marker = queryParams().get(QueryParams.MARKER);
+    final String marker = queryParams().get(isListObjectVersions() ? 
QueryParams.KEY_MARKER : QueryParams.MARKER);

Review Comment:
   ListObjectVersions requires `key-marker` whenever `version-id-marker` is 
supplied; AWS returns `InvalidArgument` for an orphan version marker. This path 
currently accepts the request, ignores the missing key marker, and returns a 
normal listing while echoing the unusable version marker. Validate this 
parameter combination before deriving the listing marker.



-- 
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]

Reply via email to