jiafu1115 commented on code in PR #20913:
URL: https://github.com/apache/kafka/pull/20913#discussion_r3201080327


##########
storage/src/main/java/org/apache/kafka/storage/internals/log/LogConfig.java:
##########
@@ -138,6 +144,10 @@ public Optional<String> serverConfigName(String 
configName) {
     public static final boolean DEFAULT_REMOTE_LOG_DELETE_ON_DISABLE_CONFIG = 
false;
     public static final long DEFAULT_LOCAL_RETENTION_BYTES = -2; // It 
indicates the value to be derived from RetentionBytes
     public static final long DEFAULT_LOCAL_RETENTION_MS = -2; // It indicates 
the value to be derived from RetentionMs
+    public static final long DEFAULT_REMOTE_COPY_LAG_MS = -2;  // It indicates 
no delay check based on local retention ms
+    public static final long DEFAULT_REMOTE_COPY_LAG_BYTES = -2; // It 
indicates no delay check based on local retention bytes

Review Comment:
   @kamalcph your case remind me to update the document/validation to remind 
user: 
   example:
   Constraint: if <code>local.retention.ms</code> is explicitly set to a 
non-negative value, <code>remote.copy.lag.ms</code> cannot be -2 unless 
<code>remote.copy.lag.bytes</code> is also -2. Otherwise, it may break 
time-based delete policy. 
   
   I already update the validation and document for this case. Can you help to 
check it again. thanks. 
   BTW: maybe I will try to open another demo PR try to simple the logic for 
comparing if possible
   current code can work but it is somehow a little complex. If we don't want 
-1/-2. it may reduce a little complex . WDTY? anyway. let me try to refactor 
the code as first step. at least. refactor code must support all the test 
metric I list in the KIP.
   Thanks for your time! 



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