Skip to content

refactor(namespace)!: converge mutation projections - #3136

Open
nostalume wants to merge 7 commits into
OpenListTeam:mainfrom
nostalume:refactor/domain3-namespace-convergence
Open

nostalume wants to merge 7 commits into
OpenListTeam:mainfrom
nostalume:refactor/domain3-namespace-convergence

Conversation

@nostalume

@nostalume nostalume commented Sep 24, 2026 •

Copy link
Copy Markdown
Contributor

Summary / 摘要

  • Converge namespace changes on one cache/mutation authority and two separately bounded latest-snapshot projection lifecycles for search and STRM. Delete the old generic object hooks, search lock/queue, SkipHook effect flag, generic task payload path, and in-memory queue rather than adding a second scheduling layer.

  • Preserve mount traversal failures and correct exact-node deletion in the search index. Add behavior tests for list identity, bounded admission, task completion, and Windows-safe SQLite fixture cleanup. Retain a build-tagged configured Local/WebDAV → search/STRM mutation benchmark; it is not part of ordinary tests.

  • This is one atomic architecture cutover, organized as five review commits: mount diagnostic, bounded processor, complete cutover/deletion, search-node correction, configured benchmark. The 55-file layer diff is production +1015/-1018 (net -3) and tests +767/-58 (net +709); the test delta includes the 272-line end-to-end benchmark. The value claimed is removal of duplicate authorities and queue protocols, not a throughput improvement or a large total-LOC reduction.

  • Depends on refactor(authz)!: centralize path authorization #3132. This branch descends from its exact reviewed head 853e15af. The upstream PR's default diff temporarily includes refactor(authz)!: centralize path authorization #3132; review only this Domain 3 layer. Parallel review is welcome; merge only after refactor(authz)!: centralize path authorization #3132. Once it lands, we will update this same PR against landed main and revalidate the final diff and CI.

  • Source compatibility: internal Go callers using the removed ListArgs.SkipHook/old task and hook paths must migrate. No persisted configuration or storage format migration is intended. If Driver catalog PR refactor(drivers)!: replace init registration with explicit catalog #3134 lands first, this benchmark's baseline blank-import fixture must be adapted to explicit catalog installation before this PR merges; this is an integration check, not a semantic dependency between the domains.

  • This PR has breaking changes.
    / 此 PR 包含破坏性变更。

  • This PR changes public API, config, storage format, or migration behavior.
    / 此 PR 修改了公开 API、配置、存储格式或迁移行为。

  • This PR requires corresponding changes in related repositories.
    / 此 PR 需要关联仓库同步修改。

Related repository PRs / 关联仓库 PR: None known.

Testing / 测试

Windows, Go 1.27.1, head b25ba197:

  • go test ./pkg/mq ./internal/op ./internal/fs ./internal/search/... ./internal/task_group ./internal/db ./server/handles ./server/webdav ./server/ftp ./server/s3 — passed. The new SQLite test was first found to leave its file open on Windows; after closing/restoring its fixture, the direct three-repeat test and this focused run passed.

  • go test -tags benchmark ./internal/bootstrap -run '^$' -bench '^BenchmarkConfiguredProjectionMutation$' -benchtime=1x -count=1 — passed for the default Local/SQLite/STRM fixture. Optional WebDAV and Meilisearch modes were not rerun in this audit.

  • WSL Tumbleweed, Go 1.27.1: go test -race ./pkg/mq ./internal/op ./internal/fs ./internal/search/... ./internal/task_group ./server/webdav and one tagged race benchmark iteration — passed.

  • Focused vet, go build ./..., and all-package test compilation with go test -run '^$' -vet=off ./... — passed; Go emitted a non-fatal module stat-cache access warning in this restricted environment.

  • All 51 changed committed Go blobs are gofmt-clean; git diff --check passed. The retired hook/skip/queue identifiers were checked absent in their owning packages.

  • Full go test ./... was not run in this audit and is not claimed green.

  • go test ./...

  • Manual test / 手动测试:

Checklist / 检查清单

  • I have read CONTRIBUTING.
    / 我已阅读 CONTRIBUTING。
  • I confirm this contribution follows the repository license, contribution policy, and code of conduct.
    / 我确认此贡献符合仓库许可证、贡献规范和行为准则。
  • I have formatted the changed code with gofmt, go fmt, or prettier where applicable.
    / 我已按适用情况使用 gofmt、go fmt 或 prettier 格式化变更代码。
  • I have requested review from relevant maintainers or code owners where applicable.
    / 我已在适用情况下请求相关维护者或代码所有者审查。

AI Disclosure / AI 使用声明

  • This PR includes AI-assisted content.
    / 此 PR 包含 AI 辅助内容。

Tools used / 使用工具:

  • Codex

Usage scope / 使用范围:

  • Code generation / 代码生成

  • Refactoring / 重构

  • Documentation / 文档

  • Tests / 测试

  • Translation / 翻译

  • Review assistance / 审查辅助

  • I have reviewed and validated all AI-assisted content included in this PR.
    / 我已审核并验证此 PR 中的所有 AI 辅助内容。

  • I have ensured that all AI-assisted commits include Co-Authored-By attribution.
    / 我已确保所有 AI 辅助提交都包含 Co-Authored-By 归属信息。

  • I can reproduce all AI-assisted content included in this PR without any AI tools.
    / 我可以在没有任何 AI 工具的情况下重现此 PR 中包含的所有 AI 辅助内容。

nostalume and others added 7 commits September 24, 2026 20:05
- Move user, meta, path, hidden-name, and password policy into internal/authz.

- Remove authorization regex state from object merging and migrate protocol callers directly.

- Replace structural tests with a compact behavior matrix for the policy owner.

Co-authored-by: Codex <267193182+codex@users.noreply.github.com>
- Propagate directory-listing failures through mount traversal and protocol callers.

- Keep list diagnostics at their owning outcome and remove an unused argument placeholder.

Co-authored-by: Codex <267193182+codex@users.noreply.github.com>
- Admit keyed updates through a bounded processor with explicit shutdown and replacement semantics.

- Retain behavior tests for overwrite, drain, cancellation, and refusal paths.

Co-authored-by: Codex <267193182+codex@users.noreply.github.com>
- Route accepted namespace changes through one bounded latest-value projection owner.

- Remove generic hooks, duplicate search queues and locks, skip flags, and old task payload paths.

- Preserve mount, search, STRM, and cache behavior with identity and task-group regressions.

Co-authored-by: Codex <267193182+codex@users.noreply.github.com>
- Remove the exact search node and its descendants when a renamed path is deleted.

- Cover sibling preservation and close the SQLite fixture before Windows temp cleanup.

Co-authored-by: Codex <267193182+codex@users.noreply.github.com>
- Measure end-to-end namespace mutation through configured search and STRM sinks.

- Verify completion, bounded admission, and final projected state for local or loopback WebDAV sources.

Co-authored-by: Codex <267193182+codex@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant