gabriel / musehub public
feat patch push task/phase7-perf-engineering #1 / 1
AI Agent gabriel · 153 days ago · Apr 23, 2026 · Diff

feat(push): Phase 7 — _flush_batch parallelism + benchmark suite

Overlap R2 PUTs with skipped-object ref upserts via asyncio.create_task. Replace O(n²) path lookup with a pre-built dict. Add bench_push.py with 6 scenarios: tiny, incremental, cold_large, repush_noop, many_small, few_large. All 52 wire push stream tests still pass.

sha256:a439a899873cbddeacff5433ac3b76796df161c725d71ae59e753674356d3f3a sha
+63 ~1 symbols
sha256:15bb4b15bc9fb4e9c155e213a37d452c78a4cb9fcd0b3a8b1fc10e78de218d16 snapshot
+63
symbols added
~1
symbol modified
0
dead code introduced
Semantic Changes 64 symbols
~ tests/bench_push.py .py 63 symbols added
+ BenchResult class class BenchResult L162–185
+ __init__ method method __init__ L163–166
+ p50 method method p50 L172–173
+ p95 method method p95 L175–179
+ record method method record L168–170
+ throughput_mbs method method throughput_mbs L181–185
+ _AUTH_CTX variable variable _AUTH_CTX L57–62
+ _DB_URL variable variable _DB_URL L50–53
+ _ENGINE variable variable _ENGINE L54–54
+ _SESSION_FACTORY variable variable _SESSION_FACTORY L55–55
+ _c_frame function function _c_frame L117–120
+ _commit_counter variable variable _commit_counter L79–79
+ _create_repo_api function async_function _create_repo_api L143–151
+ _do_push function async_function _do_push L153–159
+ _e_frame function function _e_frame L122–125
+ _fw variable variable _fw L48–48
+ _h_frame function function _h_frame L105–109
+ _make_commit function function _make_commit L81–100
+ _make_snapshot function function _make_snapshot L102–103
+ _o_frame function function _o_frame L111–115
+ _pack function function _pack L66–67
+ _print_results function function _print_results L395–418
+ _push_body function function _push_body L127–138
+ _sha256_oid function function _sha256_oid L69–70
+ _utc function function _utc L75–77
+ _wrap function function _wrap L72–73
+ bench_cold_large function async_function bench_cold_large L212–238
+ bench_few_large function async_function bench_few_large L308–334
+ bench_incremental function async_function bench_incremental L337–390
+ bench_many_small function async_function bench_many_small L279–305
+ bench_repush_noop function async_function bench_repush_noop L241–276
+ bench_tiny function async_function bench_tiny L190–209
+ ASGITransport import import ASGITransport L36–36
+ Any import import Any L30–30
+ AsyncClient import import AsyncClient L36–36
+ Base import import Base L41–41
+ MSignContext import import MSignContext L45–45
+ MuseWireFrameWriter import import MuseWireFrameWriter L40–40
+ NullPool import import NullPool L38–38
+ Path import import Path L29–29
+ SFRAME_COMMIT_PACK import import SFRAME_COMMIT_PACK L46–46
+ SFRAME_END import import SFRAME_END L46–46
+ SFRAME_HEADER import import SFRAME_HEADER L46–46
+ SFRAME_OBJECT import import SFRAME_OBJECT L46–46
+ WIRE_CONTENT_TYPE import import WIRE_CONTENT_TYPE L40–40
+ _database import import _database L42–42
+ annotations import import annotations L20–20
+ app import import app L44–44
+ async_sessionmaker import import async_sessionmaker L37–37
+ asyncio import import asyncio L22–22
+ create_async_engine import import create_async_engine L37–37
+ get_db import import get_db L41–41
+ hashlib import import hashlib L23–23
+ msgpack import import msgpack L35–35
+ muse_cli_models import import musehub.db.muse_cli_models L43–43
+ optional_signed_request import import optional_signed_request L45–45
+ os import import os L24–24
+ require_signed_request import import require_signed_request L45–45
+ statistics import import statistics L25–25
+ sys import import sys L26–26
+ tempfile import import tempfile L27–27
+ time import import time L28–28
+ main function async_function main L423–487
← Older Oldest on task/phase7-perf-engineering
All commits
Newer → Latest on task/phase7-perf-engineering

0 comments

No comments yet. Be the first to start the discussion.

To add a comment, use the Muse CLI: muse hub commit comment sha256:a439a899873cbddeacff5433ac3b76796df161c725d71ae59e753674356d3f3a --body "your comment"