mirror of
https://github.com/mastra-ai/mastra.git
synced 2026-11-17 08:44:46 +00:00
perf(pg): read only the guarded step and its predecessor under the run lock
Guarded storage v2 appends materialized the whole run while holding the row lock, so sequential runs grew quadratically under the lock. The guard now reads just the guarded step and its predecessor, and loads the full run only to report a completed conflict. Sequential 64 steps: 593ms to 400ms; 128 steps: 1670ms to 1153ms. Co-Authored-By: mastracode <284800079+mastra-platform[bot]@users.noreply.github.com>
This commit is contained in:
parent
eaac6fc33f
commit
4136e11803
1 changed files with 42 additions and 18 deletions
Loading…
Add table
Add a link
Reference in a new issue