danny0405 commented on code in PR #6977:
URL: https://github.com/apache/hudi/pull/6977#discussion_r997822653


##########
hudi-common/src/main/java/org/apache/hudi/common/model/HoodieRecord.java:
##########
@@ -282,6 +287,47 @@ public void checkState() {
     }
   }
 
+  protected abstract void writeRecordPayload(T payload, Kryo kryo, Output 
output);
+
+  protected abstract T readRecordPayload(Kryo kryo, Input input);
+
+  /**
+   * NOTE: This method is declared final to make sure there's no polymorphism 
and therefore
+   *       JIT compiler could perform more aggressive optimizations
+   */
+  @Override
+  public final void write(Kryo kryo, Output output) {
+    Serializer recLocSerializer = 
kryo.getSerializer(HoodieRecordLocation.class);
+
+    kryo.writeObjectOrNull(output, key, HoodieKey.class);
+    kryo.writeObjectOrNull(output, currentLocation, recLocSerializer);
+    kryo.writeObjectOrNull(output, newLocation, recLocSerializer);

Review Comment:
   How about the performance gains for records SE/DE after this change ?



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