perf: async bundle indexing — sync path returns in < 1s
unpack-bundle now does exactly three things synchronously: 1. GET bundle + verify sha256(wire_bytes)==bundle_key 2. Advance branch pointer (one PG row) 3. Enqueue bundle.index job (one PG row)
All commit and snapshot indexing is deferred to process_bundle_index_job, called by the background worker. bundle.index is always inserted as a fresh row (no dedup) since each push has a unique bundle_key.
Tests: test_bundle_push_async.py — 3 tests, all passing: - unpack-bundle returns < 1s for 1031 commits × 700 files - bundle.index job correctly writes all commits and snapshots - branch pointer is set before worker runs
sha256:b97b1d8a2da3e3f001a43a0b8157cc0f6a3abaad9468f363ced0ac6c00b5f693
sha
+45
~2
symbols
sha256:d6aec5845051869f6086c6b1da26f8601f7fe84348f7c016b52f73745cd45755
snapshot
+45
symbols added
~2
symbols modified
0
dead code introduced
Semantic Changes
47 symbols
+
test_branch_head_correct_before_indexing
function
async_function test_branch_head_correct_before_indexing L333–362
+
test_bundle_index_job_populates_commits_and_snapshots
function
async_function test_bundle_index_job_populates_commits_and_snapshots L280–329
0 comments
To add a comment, use the Muse CLI:
muse hub commit comment sha256:b97b1d8a2da3e3f001a43a0b8157cc0f6a3abaad9468f363ced0ac6c00b5f693 --body "your comment"
No comments yet. Be the first to start the discussion.