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


##########
hudi-flink-datasource/hudi-flink/src/main/java/org/apache/hudi/sink/bulk/RowDataKeyGen.java:
##########
@@ -99,7 +99,7 @@ protected RowDataKeyGen(
       this.recordKeyProjection = null;
     } else {
       this.recordKeyFields = recordKeys.get().split(",");
-      if (this.recordKeyFields.length == 1) {
+      if (this.recordKeyFields.length == 1  && this.partitionPathFields.length 
== 1) {

Review Comment:
   > continue to use ComplexAvroKeyGenerator make ComplexAvroKeyGenerator 
compatible with single primary key
   
   I'm approval with this way for 2 reasons:
   
   1. The ComplexKeyGenerator for row writers already did this;
   2. There is no need to change the strategy of what key generator to use in 
general, to avoid many potential changes.
   
   Compatibility is an issue but I think 1.0.0 is a good chance to shake off 
the history burdens.



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