mirror of
https://github.com/rustfs/rustfs.git
synced 2026-08-21 11:56:38 +00:00
129677f0b3
* refactor(scanner): split scanner_folder item actions and ledger Split the 6345-line scanner_folder.rs (46% inline tests) into a canonical scanner_folder.rs + scanner_folder/ module tree with zero behavior change: - scanner_folder.rs (~2280): scan constants, alert cooldowns, metric accounting, resume ordering, tracing helpers, the FolderScanner struct with failed-object bookkeeping and the scan_folder traversal, and scan_data_folder - scanner_folder/item_actions.rs (~890): CachedFolder, the get-size failure policy, ScannerItem with apply_actions and the heal/ILM admission helpers - scanner_folder/ledger.rs (~280): the pending-scanner-heal ledger methods and their entry helpers (record/prune/clear-for-repaired/ retry) - scanner_folder/tests.rs (~2950): the inline test module as a child module The ScannerItem path used by scanner_io resolves through a root re-export, and every other crate path is unchanged. Cross-module items gain pub(super), whose scope equals the old single-module privacy domain. Code is moved verbatim apart from those markers, per-module import headers, and rustfmt re-wraps. Co-Authored-By: heihutu <heihutu@gmail.com> * fmt --------- Co-authored-by: heihutu <heihutu@gmail.com>
RustFS Scanner
RustFS Scanner is the background maintenance scan loop. It handles usage accounting, lifecycle expiry and transition admission, bucket replication repair admission, scanner-driven heal/bitrot checks, and namespace alerts.
For operator-facing runtime controls, status fields, and tuning workflows, see Scanner Runtime Controls. For repeatable scanner-pressure validation, see Scanner Benchmark Runbook.
Chinese documentation is available in README.zh-CN.md.
Development
Build
cargo build --package rustfs-scanner
Test
cargo test --package rustfs-scanner
License
Apache License 2.0