nastra commented on code in PR #7988:
URL: https://github.com/apache/iceberg/pull/7988#discussion_r1259860236


##########
dell/src/test/java/org/apache/iceberg/dell/mock/ecs/ObjectData.java:
##########
@@ -70,9 +71,29 @@ public InputStream createInputStream(Range range) {
 
   public S3ObjectMetadata createFullMetadata() {
     S3ObjectMetadata metadata = new S3ObjectMetadata();
-    metadata.setETag(DigestUtils.md5Hex(content));
+    MessageDigest md = null;
+    try {
+      md = MessageDigest.getInstance("MD5");
+    } catch (NoSuchAlgorithmException e) {
+      throw new RuntimeException(e);
+    }
+    md.update(content);
+    byte[] digest = md.digest();
+    metadata.setETag(bytesToHex(digest));
     metadata.setContentLength((long) content.length);
     metadata.setUserMetadata(userMetadata);
     return metadata;
   }
+
+  private static final char[] HEX_ARRAY = "0123456789ABCDEF".toCharArray();

Review Comment:
   `static final` fields should generally be placed at the top of the java file



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