RockteMQ-AI commented on code in PR #11006:
URL: https://github.com/apache/rocketmq/pull/11006#discussion_r3923145628


##########
common/src/main/java/org/apache/rocketmq/common/message/MessageDecoder.java:
##########
@@ -44,6 +44,9 @@ public class MessageDecoder {
     public final static int MESSAGE_PHYSIC_OFFSET_POSITION = 28;
     public final static int MESSAGE_STORE_TIMESTAMP_POSITION = 56;
 
+    // Pre-encoded constant to avoid per-message getBytes() allocation in 
createCrc32()

Review Comment:
   Minor consistency nit: `MessageDecoder` already declares `public final 
static Charset CHARSET_UTF8 = StandardCharsets.UTF_8` at line 41. Consider 
using `CHARSET_UTF8` here instead of `StandardCharsets.UTF_8` to match the 
existing convention in this file (e.g. lines 150, 198, 201, 317).



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

Reply via email to