Skip to content

perf(session): batch persisted turn-intent status reads - #512

Open
beruro wants to merge 1 commit into
developfrom
junyu/rpc-performance-closure
Open

perf(session): batch persisted turn-intent status reads#512
beruro wants to merge 1 commit into
developfrom
junyu/rpc-performance-closure

Conversation

@beruro

@beruro beruro commented Jul 24, 2026

Copy link
Copy Markdown
Collaborator

Summary

  • add connection-scoped turn-intent insert/update helpers for atomic adjacent lifecycle writes
  • add one batched persisted-status projection for reconnect/focus reconciliation
  • preserve the existing turn-intent transition FSM and complete row shape

Why #512 was rewritten

The previous PR mixed RPC lifecycle, frontend async consumers, cache bounds, diagnostics, and profiling across 233 files. The clean pre-split head is preserved at junyu/pr-512-clean-backup-20260729. This PR is now the small persistence root of the stack; dependent CLI and frontend lifecycle PRs will target it separately.

Validation

  • cargo test -p session_persistence turn_intents (12 passed)
  • cargo check -p session_persistence
  • rustfmt --edition 2021 --check crates/session-persistence/src/turn_intents.rs
  • git diff --check origin/develop...HEAD

Architecture boundary

This PR only changes the authoritative SQLite turn-intent persistence boundary. It does not include CLI runner wiring, frontend reconciliation, generic async hooks, runtime caches, browser diagnostics, or Team Inbox (#531).

beruro added a commit that referenced this pull request Jul 27, 2026
beruro added a commit that referenced this pull request Jul 27, 2026
beruro added a commit that referenced this pull request Jul 27, 2026
beruro added a commit that referenced this pull request Jul 27, 2026
beruro added a commit that referenced this pull request Jul 27, 2026
beruro added a commit that referenced this pull request Jul 27, 2026
beruro added a commit that referenced this pull request Jul 27, 2026
beruro added a commit that referenced this pull request Jul 27, 2026
@beruro
beruro force-pushed the junyu/rpc-performance-closure branch 2 times, most recently from 4672245 to 08c6161 Compare July 29, 2026 04:05
@beruro
beruro force-pushed the junyu/rpc-performance-closure branch from 08c6161 to f2c5742 Compare July 29, 2026 05:20
@beruro

beruro commented Jul 29, 2026

Copy link
Copy Markdown
Collaborator Author

Split completed. The previous clean 233-file head remains recoverable at junyu/pr-512-clean-backup-20260729.

Review / merge order:

  1. perf(session): batch persisted turn-intent status reads #512 — persisted turn-intent batch projection (1 file)
  2. perf(cli): replace status polling with turn-intent push #565 — CLI runner + push reconciliation (depends on perf(session): batch persisted turn-intent status reads #512)
  3. fix(session): preserve queue and terminal finality #566 — queue/intervention/finality semantics (depends on perf(cli): replace status polling with turn-intent push #565)

Independent async stack:

  1. refactor(async): add scoped resource lifecycle #562 — scoped async lifecycle foundation (13 files)
  2. refactor(data): scope async resource consumers #563 — scoped application consumers (depends on refactor(async): add scoped resource lifecycle #562)
  3. perf(runtime): bound caches, scans, and background work #564 — bounded caches/scans/background work (depends on refactor(async): add scoped resource lifecycle #562; independent of refactor(data): scope async resource consumers #563)

Independent PRs:

I also excluded 25 files that were byte-for-byte identical to running the current rustfmt on develop; they were formatter noise, not a reviewable semantic change. No split PR contains Team Inbox / #531 paths.

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