ivandika3 commented on code in PR #9612:
URL: https://github.com/apache/ozone/pull/9612#discussion_r2711575395
##########
hadoop-ozone/s3gateway/src/main/java/org/apache/hadoop/ozone/s3/endpoint/ObjectEndpoint.java:
##########
@@ -472,10 +472,10 @@ public Response get(
responseBuilder
.header(ACCEPT_RANGE_HEADER, RANGE_HEADER_SUPPORTED_UNIT);
- String eTag = keyDetails.getMetadata().get(OzoneConsts.ETAG);
- if (eTag != null) {
- responseBuilder.header(HttpHeaders.ETAG, wrapInQuotes(eTag));
- String partsCount = extractPartsCount(eTag);
+ String md5Hash = keyDetails.getMetadata().get(OzoneConsts.ETAG);
+ if (md5Hash != null) {
+ responseBuilder.header(HttpHeaders.ETAG, wrapInQuotes(md5Hash));
+ String partsCount = extractPartsCount(md5Hash);
Review Comment:
Nit: This should still be `ETag` since we are actually getting the key ETag
which may not be MD5. We should only use `md5Hash` if we are actually
calculating MD5.
--
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]