kafka定期清理过期数据
制定了清理策略,但是还是每隔7天才会清理
清理策略如下:
############################# Log Retention Policy #############################
# The following configurations control the disposal of log segments. The policy can
# be set to delete segments after a period of time, or after a given size has accumulated.
# A segment will be deleted whenever *either* of these criteria are met. Deletion always happens
# from the end of the log.
# The minimum age of a log file to be eligible for deletion due to age
# 日志清理策略
log.cleanup.policy=delete
log.retention.hours=1
log.cleaner.enable=true
# A size-based retention policy for logs. Segments are pruned from the log unless the remaining
# segments drop below log.retention.bytes. Functions independently of log.retention.hours.
log.retention.bytes=1048576
# The maximum size of a log segment file. When this size is reached a new log segment will be created.
log.segment.bytes=10240
# The interval at which log segments are checked to see if they can be deleted according
# to the retention policies
log.retention.check.interval.ms=300000
############################# Zookeeper #############################