Commit Graph

421 Commits

Author SHA1 Message Date
Zhengchao An b0dbf35cd4 refactor(ecstore): route lifecycle metadata reads (#4111) 2026-06-30 15:22:12 +08:00
Zhengchao An 4538919efa refactor(ecstore): route runtime getters through facade (#4109) 2026-06-30 14:32:01 +08:00
Zhengchao An 143833ec45 test(architecture): guard rustfs owner statics (#4108) 2026-06-30 14:01:19 +08:00
houseme 22c7cb1923 feat(ecstore): refresh issue-787 phase-3 validation track (#4106)
* feat: isolate list objects quorum config

* perf: add list gather observability for issue-785

* feat: add list-path observability for storage layers

* chore: add issue 785 list observability acceptance runner

* fix: avoid moved fields in list_path logging

* test: add marker replay idempotence checks for list pagination

* feat(ecstore): add list marker v2 cache id

* Revert "feat(ecstore): add list marker v2 cache id"

This reverts commit 980c364e02.

* Reapply "feat(ecstore): add list marker v2 cache id"

This reverts commit 766d2cee65.

* feat(ecstore): propagate list cache cursor in list layers

* test: add versioned continuation fallback tests

* test: add live pagination continuity smoke mode

* chore: run cargo fmt on issue-4003 branch

* build: fix bash3 compatibility in live smoke

* test(ecstore): simplify bool marker test assertion

* refactor(ecstore): unify list pagination state machine

* test: add issue 787 quorum validation runner

* build: support bash32 in issue-787 runner

* docs: add issue-787 benchmark evidence
2026-06-30 11:37:44 +08:00
Zhengchao An 7041d60cbf refactor(storage): narrow root runtime facade (#4105) 2026-06-30 11:19:21 +08:00
Zhengchao An f6689f5b39 test(app): remove object store fallback (#4104) 2026-06-30 08:08:54 +08:00
Zhengchao An 27e1cb5ffd refactor(storage): narrow object store resolver boundary (#4103) 2026-06-30 07:56:36 +08:00
Zhengchao An 9a8a82e90c test(architecture): guard owner cache globals (#4102) 2026-06-30 07:17:51 +08:00
Zhengchao An 733904deb1 test(architecture): guard owner runtime globals (#4101) 2026-06-30 06:54:07 +08:00
Zhengchao An f0d27982e5 refactor(app): collapse transition stats boundary (#4100) 2026-06-30 06:48:09 +08:00
Zhengchao An 46edc118f0 refactor(app): add lifecycle state context boundary (#4099) 2026-06-30 06:26:06 +08:00
Zhengchao An de19342744 refactor(runtime): finish legacy global naming (#4097) 2026-06-30 05:50:58 +08:00
Zhengchao An 74aef760f0 refactor(lifecycle): normalize state global names (#4096) 2026-06-30 05:29:10 +08:00
Zhengchao An cbd527cd6e refactor(runtime): normalize legacy global names (#4095) 2026-06-30 05:13:06 +08:00
Zhengchao An 90f9c24503 refactor(runtime): clean scalar globals (#4094) 2026-06-30 04:52:23 +08:00
Zhengchao An 77e45896ba refactor(runtime): remove unused node names global (#4093) 2026-06-30 04:44:17 +08:00
Zhengchao An c279d34af6 refactor(runtime): batch owner boundary guards (#4092) 2026-06-30 04:34:54 +08:00
Zhengchao An 19dc019038 test(runtime): guard kms service manager global (#4086) 2026-06-30 04:17:24 +08:00
Zhengchao An 90ea66423e test(runtime): guard internode transport global (#4085) 2026-06-30 04:11:30 +08:00
Zhengchao An 3b754f649d test(runtime): guard batch processor global (#4083) 2026-06-30 03:40:03 +08:00
Zhengchao An fab78f8402 refactor(scanner): use expiry runtime boundary (#4079) 2026-06-30 02:09:52 +08:00
Zhengchao An 35d7d6bf23 refactor(ecstore): wrap background cancel token access (#4078) 2026-06-30 02:09:39 +08:00
Zhengchao An 50c9078142 refactor(runtime): guard scalar lock globals (#4059) 2026-06-29 20:04:44 +08:00
Zhengchao An 27a491a730 refactor(runtime): guard replication stats globals (#4058) 2026-06-29 19:55:38 +08:00
Zhengchao An 9b6c6df81b refactor(runtime): guard local node globals (#4057) 2026-06-29 19:47:21 +08:00
Zhengchao An 35077c033c refactor(runtime): guard endpoint erasure globals (#4055) 2026-06-29 19:26:05 +08:00
Zhengchao An 636476c3e5 refactor(runtime): guard lifecycle event globals (#4053) 2026-06-29 17:56:02 +08:00
Zhengchao An 0c4deb0e2f refactor(runtime): guard setup type globals (#4052) 2026-06-29 17:38:57 +08:00
Zhengchao An aadefcc577 refactor(runtime): guard local disk set global (#4049) 2026-06-29 17:29:24 +08:00
Zhengchao An ecbc5385d3 refactor(runtime): hide local disk id global (#4047) 2026-06-29 16:33:36 +08:00
Zhengchao An ad6be6a167 refactor(runtime): hide local disk map global (#4046) 2026-06-29 14:57:14 +08:00
Zhengchao An 4111ce1547 refactor(runtime): wrap tier config global (#4045) 2026-06-29 14:38:36 +08:00
Zhengchao An e012d1e799 refactor(runtime): wrap boot time global (#4044) 2026-06-29 14:21:31 +08:00
Zhengchao An 4567f6f521 refactor(runtime): guard rpc secret global (#4043) 2026-06-29 14:02:03 +08:00
Zhengchao An 6093eb0c9c refactor(runtime): wrap local node name global (#4041) 2026-06-29 13:13:54 +08:00
Zhengchao An 9c62a24efc refactor(runtime): wrap outbound tls globals (#4039) 2026-06-29 12:56:34 +08:00
Henry Guo de41303f3e feat(table-catalog): add durable backing migration guardrails (#4038)
Co-authored-by: Henry Guo <marshawcoco@users.noreply.github.com>
Co-authored-by: houseme <housemecn@gmail.com>
2026-06-29 12:39:04 +08:00
Zhengchao An 9414d645f4 refactor(runtime): wrap rustfs address globals (#4037) 2026-06-29 11:18:30 +08:00
Zhengchao An 9165de3241 refactor(runtime): wrap internode connection cache (#4036) 2026-06-29 10:43:13 +08:00
Zhengchao An 1e6f20912a test(ecstore): cover SetDisks storage contracts (#4033) 2026-06-29 10:01:42 +08:00
Zhengchao An 2d547de84a docs(architecture): inventory global state migration (#4028) 2026-06-29 08:20:32 +08:00
Zhengchao An 51d44f20c7 docs(ecstore): inventory replication split blockers (#4027) 2026-06-29 07:57:48 +08:00
Zhengchao An 763cbdd5b7 docs(ecstore): inventory lifecycle split blockers (#4026) 2026-06-29 07:57:22 +08:00
Zhengchao An aaef31d4dd docs(ecstore): inventory api facade boundaries (#4025) 2026-06-29 07:57:01 +08:00
Zhengchao An 1104d630d1 docs(obs): inventory ecstore dependency boundary (#4023) 2026-06-29 07:07:47 +08:00
houseme 0485e5adf0 feat(get): Small-file GET performance optimization for 1KiB-1MiB objects (#4016)
* feat(get): SF01 - bucket validation cache

Add 5s TTL cache for bucket validation to avoid repeated stat_volume()
calls on every GET request.

Changes:
- Add BUCKET_VALIDATED_CACHE (OnceLock + RwLock + HashMap)
- Add invalidate_bucket_validation_cache() for cache invalidation
- Add invalidate_all_bucket_validation_cache() for bulk invalidation
- Update get_validated_store() to use cache
- Add cache invalidation in execute_delete_bucket()

Expected impact: 3-5x improvement for small file GET latency.

Closes rustfs/backlog#766

Co-Authored-By: heihutu <heihutu@gmail.com>

* feat(get): SF03 - metadata cache TTL increase

Increase metadata cache TTL from 250ms to 2s and capacity from 1024
to 4096 entries.

Changes:
- GET_OBJECT_METADATA_CACHE_TTL: 250ms -> 2s
- GET_OBJECT_METADATA_CACHE_MAX_ENTRIES: 1024 -> 4096

All mutation paths already call invalidate_get_object_metadata_cache,
so the longer TTL is safe.

Expected impact: 10-50x improvement for hot objects.

Closes rustfs/backlog#768

Co-Authored-By: heihutu <heihutu@gmail.com>

* feat(get): SF04 - remove unnecessary tokio::spawn in metadata fanout

Replace tokio::spawn with direct async future in read_all_fileinfo_full_wait.
join_all already provides concurrency, so tokio::spawn adds unnecessary
task creation and scheduling overhead.

Changes:
- Remove tokio::spawn from metadata fanout futures
- Update result handling for direct future results

Expected impact: 16-32us reduction per GET request.

Closes rustfs/backlog#769

Co-Authored-By: heihutu <heihutu@gmail.com>

* feat(get): SF06 - conditional lifecycle check

Only call resolve_put_object_expiration when the object has an
x-amz-expiration metadata marker. This avoids unnecessary lifecycle
configuration reads on every GET request.

Expected impact: 50-100us reduction per GET request.

Closes rustfs/backlog#771

Co-Authored-By: heihutu <heihutu@gmail.com>

* feat(get): SF07 - conditional metrics recording

Gate hot path metrics behind get_stage_metrics_enabled() to reduce
overhead when metrics are not needed.

Changes:
- Conditional record_zero_copy_read
- Conditional manager.record_disk_operation
- Conditional manager.record_access
- Conditional manager.record_transfer

Expected impact: 20-50us reduction per GET request.

Closes rustfs/backlog#772

Co-Authored-By: heihutu <heihutu@gmail.com>

* refactor(get): SF01 - use moka instead of dashmap for bucket cache

Replace OnceLock + RwLock + HashMap with moka::sync::Cache for bucket
validation cache. moka provides built-in TTL support and is already
available in the workspace.

Changes:
- Add moka dependency to rustfs crate
- Replace manual TTL management with moka's time_to_live
- Simplify cache operations

Closes rustfs/backlog#766

Co-Authored-By: heihutu <heihutu@gmail.com>

* feat(get): SF02 - inline data fast path

Add fast path for small inline objects that bypasses duplex pipe,
tokio::spawn, and bitrot reader creation when data is already in memory.

Changes:
- Add inline data detection before codec streaming gate
- Direct in-memory erasure decode for inline objects <= 128KB
- Add GET_OBJECT_PATH_INLINE_DIRECT metric path
- Skip duplex pipe and background task for inline data

Conditions for fast path:
- Single part object
- Inline data available
- Size <= 128KB
- Not encrypted/compressed/remote
- No range request

Expected impact: 2-3x improvement for small file GET latency.

Closes rustfs/backlog#767

Co-Authored-By: heihutu <heihutu@gmail.com>

* refactor: translate Chinese comments to English

Translate all Chinese comments to English in modified files:
- rustfs/src/storage/ecfs_extend.rs
- rustfs/src/app/bucket_usecase.rs

Co-Authored-By: heihutu <heihutu@gmail.com>

* fix

* add

* fmt and improve import

* fmt

* feat(get): SF05 skip IO planning + refactor inline detection + adaptive bucket cache

SF05: Skip disk I/O semaphore for inline data fast path
- Reorder prepare_get_object_read_execution: read first, then decide semaphore
- Inline objects skip acquire_disk_read_permit() entirely (saves 100-200us)
- Add is_inline_fast_path field to GetObjectReadSetup

Refactor: Unify inline detection logic
- Add ObjectInfo::is_inline_fast_path_eligible() as single source of truth
- Version-aware thresholds: non-versioned 128KB, versioned 16KB (matches PUT)
- Eliminates divergent conditions between set_disk/mod.rs and object_usecase.rs

Refactor: Restore fault tolerance in metadata fanout
- Restore tokio::spawn + JoinError handling in read_all_fileinfo_full_wait
- Prevents single disk read panic from unwinding the entire operation

Refactor: Restore lifecycle check correctness
- Remove incorrect SF06 conditional that skipped lifecycle for most objects
- Always call resolve_put_object_expiration (original behavior)

Fix: make_bucket cache invalidation
- Invalidate bucket validation cache on create_bucket

Fix: erasure decode written validation
- Check decode() return value; error if 0 bytes written for non-empty object

Adaptive bucket cache
- Default: RwLock<HashMap> for < 100 buckets (low overhead)
- Opt-in: starshard::ShardedHashMap via RUSTFS_BUCKET_CACHE_STARSHARD=1
- 5s TTL with manual timestamp checking

Benchmark results (warp get, concurrency 32, 10s, 3 rounds):
- 10KiB: 25.10 MiB/s (+28.2% vs SF01-07)
- 100KiB: 221.81 MiB/s
- 1MiB: 1972.78 MiB/s
- vs main: -10% to -12% (inline path not triggered by warp)

Co-Authored-By: heihutu <heihutu@gmail.com>

* fix(versioning): use read lock for versioning config query + five-expert analysis

P0 fix: BucketVersioningSys::get() was using write lock on
GLOBAL_BucketMetadataSys for a pure read operation. This serialized
all concurrent GET requests (3 write-lock acquisitions per request).

Changed to read lock — get_versioning_config() handles its own
internal locking via metadata_map RwLock.

Five-expert analysis identified top bottlenecks:
1. Versioning write lock (P0, fixed)
2. Inline fast path not triggered (P0, needs verification)
3. Metadata fanout no early-stop (P1, early-stop has bug, reverted)
4. Request-level versioning cache (P1, pending)
5. Duplex pipe for small objects (P2, pending)

Benchmark (read-lock fix, warp concurrency 32):
- 1KiB: 2.29 MiB/s (vs 2.53 before, within variance)
- 10KiB: 25.00 MiB/s (same as before)
- 100KiB: 246.72 MiB/s (+11% vs 221.81)
- 1MiB: 2039.95 MiB/s (+3% vs 1972.78)

Co-Authored-By: heihutu <heihutu@gmail.com>

* chore: remove benchmark results from git, keep locally only

Remove docs/benchmark/*.md from version control.
Files remain on disk but are no longer tracked by git.
Added docs/benchmark/*.md to .gitignore.

Co-Authored-By: heihutu <heihutu@gmail.com>

* fix(get): decode inline fast path through bitrot readers

---------

Co-authored-by: heihutu <heihutu@gmail.com>
2026-06-28 22:35:42 +08:00
Zhengchao An 99f981a868 docs: plan ecstore split boundaries (#4017)
docs: plan ecstore module split boundaries
2026-06-28 21:55:10 +08:00
Zhengchao An 7ae9697d42 docs: close final architecture audit gaps (#3966) 2026-06-28 00:07:42 +08:00
Zhengchao An 79234c030d docs: close architecture migration validation (#3965) 2026-06-27 23:42:51 +08:00
Zhengchao An 82bbef0b60 test: cover runtime and repair preservation (#3964) 2026-06-27 23:34:59 +08:00