Skip to content

Commit b2bafac

Browse files
goffrieConvex, Inc.
authored andcommitted
Convert index&document retention to use load_revision_pairs (#41040)
These were previously using `previous_revisions_of_documents` / `previous_revisions` (resp.) directly (the latter only because `prev_ts` fields had not yet been sufficiently backfilled when this was last touched). They can instead use `load_revision_pairs` and benefit from the pushed down join. GitOrigin-RevId: 255135ef2a9b95484e94bb16da92dd7e0fcacf3d
1 parent 3345cef commit b2bafac

File tree

2 files changed

+150
-223
lines changed

2 files changed

+150
-223
lines changed

crates/common/src/knobs.rs

Lines changed: 0 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -367,11 +367,6 @@ pub static MAX_REPEATABLE_TIMESTAMP_COMMIT_DELAY: LazyLock<Duration> =
367367
pub static MAX_RETENTION_DELAY_SECONDS: LazyLock<Duration> =
368368
LazyLock::new(|| Duration::from_secs(env_config("RETENTION_DELETE_FREQUENCY", 60)));
369369

370-
/// How many parallel threads to use for computing which index entries have
371-
/// expired.
372-
pub static RETENTION_READ_PARALLEL: LazyLock<usize> =
373-
LazyLock::new(|| env_config("RETENTION_READ_PARALLEL", 4));
374-
375370
/// How many parallel threads to use for deleting index entries that have
376371
/// expired.
377372
pub static INDEX_RETENTION_DELETE_PARALLEL: LazyLock<usize> =
@@ -432,10 +427,6 @@ pub static INDEX_BACKFILL_CHUNK_SIZE: LazyLock<usize> =
432427
pub static INDEX_BACKFILL_WORKERS: LazyLock<usize> =
433428
LazyLock::new(|| env_config("INDEX_BACKFILL_WORKERS", 1));
434429

435-
/// Chunk size of index entries when reading from persistence.
436-
pub static RETENTION_READ_CHUNK: LazyLock<usize> =
437-
LazyLock::new(|| env_config("RETENTION_READ_CHUNK", 128));
438-
439430
/// Chunk size of index entries for deleting from Persistence.
440431
pub static INDEX_RETENTION_DELETE_CHUNK: LazyLock<usize> =
441432
LazyLock::new(|| env_config("INDEX_RETENTION_DELETE_CHUNK", 512));

0 commit comments

Comments
 (0)