jiafu1115 commented on code in PR #20913:
URL: https://github.com/apache/kafka/pull/20913#discussion_r3200875310
##########
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 yes. you are right.
so this case's precondition is : "Suppose a user has a topic that **only**
sets a time-based retention policy (e.g., 7 days)"
my case is:
retention.ms = 2 days
retention.bytes = -1 no limit
local.retention.ms = 6 hour
remote.copy.lag.ms = how to set here ? if 0. upload at once. if positive. I
don't need it. so I set it to -2 mean no check.
for your case:
retention.ms = 2 days
retention.bytes = 10 GB
local.retention.ms = 6 hour
remote.copy.lag.ms = 5.5 hour
Your unstand is right. if he don't set the "remote.copy.lag.bytes" value.
it may break the deletion logic for size constrait. So for your case. he need
to set the size lag to keep the constrait. no need to set to -1/-2.
--
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]