I notice that, in the manual, the description of maxHistory with SizeAndTimeBasedRollingPolicy, said, <rollingPolicy class="ch.qos.logback.core.rolling.SizeAndTimeBasedRollingPolicy"> <!-- rollover daily --> <fileNamePattern>mylog-%d {yyyy-MM-dd}
.%i.txt</fileNamePattern> <!-- each file should be at most 100MB, keep 60 days worth of history, but at most 20GB --> <maxFileSize>100MB</maxFileSize> <maxHistory>60</maxHistory> <totalSizeCap>20GB</totalSizeCap> </rollingPolicy> and in the description of maxHistory, it says, maxHistory int The optional maxHistory property controls the maximum number of archive files to keep, asynchronously deleting older files.
So I guess, if there's a file larger than 100MB, it will be more than 1 log for a day. And there will be at most 60 log files keep in device. That means the description of 'keep 60 days worth of history' probably not correct. Am I right with the understanding?
|