chihsuan commented on code in PR #11236:
URL: https://github.com/apache/ozone/pull/11236#discussion_r4006136733
##########
hadoop-ozone/s3gateway/src/main/java/org/apache/hadoop/ozone/s3/endpoint/BucketCrudHandler.java:
##########
@@ -41,15 +41,14 @@
*/
public class BucketCrudHandler extends BucketOperationHandler {
- /**
- * Handle only plain PUT bucket (create bucket), not subresources.
- */
+ /** Handle only plain bucket creation and deletion, not subresources. */
private boolean shouldHandle() {
return queryParams().get(QueryParams.ACL) == null
&& queryParams().get(QueryParams.UPLOADS) == null
&& queryParams().get(QueryParams.DELETE) == null
&& queryParams().get(QueryParams.TAGGING) == null
- && queryParams().get(QueryParams.LIFECYCLE) == null;
+ && queryParams().get(QueryParams.LIFECYCLE) == null
+ && queryParams().get(QueryParams.PUBLIC_ACCESS_BLOCK) == null;
Review Comment:
Have you considered a small handler before `BucketCrudHandler`, similar to
`BucketGetLocationHandler`? It would also cover `GET ?publicAccessBlock`, which
still returns a listing today, and other unsupported subresources could join it
later.
##########
hadoop-ozone/s3gateway/src/main/java/org/apache/hadoop/ozone/s3/endpoint/BucketCrudHandler.java:
##########
Review Comment:
nit: The class javadoc above is missing `?lifecycle` and
`?publicAccessBlock`. Maybe drop the examples and describe the rule instead?
They go stale easily.
--
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]