ChenSammi commented on code in PR #5233: URL: https://github.com/apache/ozone/pull/5233#discussion_r1311095057
########## hadoop-ozone/s3gateway/src/main/java/org/apache/hadoop/ozone/s3secret/S3SecretGenerateEndpoint.java: ########## @@ -34,16 +36,30 @@ public class S3SecretGenerateEndpoint extends S3SecretEndpointBase { @POST public Response generate() throws IOException { + return generateInternal(null); + } + + @POST + @Path("/{username}") + public Response generate(@PathParam("username") String username) Review Comment: The current URL and HTTP action of each operation is POST /secret/generate POST /secret/generate/testuser2 POST /secret/revoke POST /secret/revoke/testuser2 For a REST API, it usually leverages HTTP operations instead of put the operation/action name in the URL. I'd like to recommend change the URL and HTTP action to, PUT /secret/ PUT /secret/testuser2 DELETE /secret/ DELETE /secret/testuser2 @ivanzlenko , the rest looks good. -- 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: issues-unsubscr...@ozone.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org --------------------------------------------------------------------- To unsubscribe, e-mail: issues-unsubscr...@ozone.apache.org For additional commands, e-mail: issues-h...@ozone.apache.org