EricJoy2048 commented on code in PR #3831:
URL: 
https://github.com/apache/incubator-seatunnel/pull/3831#discussion_r1059227634


##########
seatunnel-connectors-v2/connector-kafka/src/main/java/org/apache/seatunnel/connectors/seatunnel/kafka/source/ConsumerMetadata.java:
##########
@@ -38,7 +38,7 @@ public class ConsumerMetadata implements Serializable {
     private String bootstrapServers;
     private Properties properties;
     private String consumerGroup;
-    private boolean commitOnCheckpoint = false;
+    private boolean commitOnCheckpoint = true;

Review Comment:
   We use `COMMIT_ON_CHECKPOINT` to define the default value.
   
   ```
       public static final Option<Boolean> COMMIT_ON_CHECKPOINT = 
Options.key("commit_on_checkpoint")
               .booleanType()
               .defaultValue(true)
               .withDescription("If true the consumer's offset will be 
periodically committed in the background.");
   ```
   
   So, I think if user does not set it in config file, you need get the default 
value from `COMMIT_ON_CHECKPOINT.defaultValue()`. Otherwise, the defaultValue 
in Option will lose its meaning.



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