Skip to content

Commit 7da675a

Browse files
committed
docs: correct compaction period comments for 24-hour window
Update compaction period logic in periodic compactor to consistently use 24-hour intervals instead of 1-hour. This fixes incorrect time calculations where: - Compaction period now correctly uses 24-hour instead of 1-hour - Revision recording interval updated to 144-minute (1/10 of 24-hour) instead of 6-minute - Retry interval on compaction failure adjusted to 144-minute to match the new period This ensures consistent time-based compaction behavior for 24-hour windows as originally intended. Fixes #[issue-19017] Signed-off-by: wodeyoulai <[email protected]>
1 parent 2f37f48 commit 7da675a

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

server/etcdserver/api/v3compactor/periodic.go

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -72,12 +72,12 @@ Compaction period 1-hour:
7272
- failure? update revs, and retry after 1/10 of 1-hour (6-minute)
7373
7474
Compaction period 24-hour:
75-
1. compute compaction period, which is 1-hour
76-
2. record revisions for every 1/10 of 1-hour (6-minute)
75+
1. compute compaction period, which is 24-hour
76+
2. record revisions for every 1/10 of 24-hour (144-minute)
7777
3. keep recording revisions with no compaction for first 24-hour
7878
4. do compact with revs[0]
7979
- success? continue on for-loop and move sliding window; revs = revs[1:]
80-
- failure? update revs, and retry after 1/10 of 1-hour (6-minute)
80+
- failure? update revs, and retry after 1/10 of 24-hour (144-minute)
8181
8282
Compaction period 59-min:
8383
1. compute compaction period, which is 59-min

0 commit comments

Comments
 (0)