Skip to content

test(core): narrow effect flock harness - #41837

Merged
kitlangton merged 1 commit into
v2from
speed-flock-tests
Aug 11, 2026
Merged

test(core): narrow effect flock harness#41837
kitlangton merged 1 commit into
v2from
speed-flock-tests

Conversation

@kitlangton

Copy link
Copy Markdown
Contributor

What

Cuts the EffectFlock suite's measured median runtime from 6.45 seconds to 3.64 seconds, about 44%, by avoiding an unrelated Core Location import graph in every lock worker.

Before / After

Before: The EffectFlock test and worker used AppNodeBuilder, whose eager import of Core Location services loaded the complete application graph into the parent process and each of 16 contention workers. EffectFlock itself only depends on Global and FSUtil.

After: Both boundaries compile EffectFlock.node directly with LayerNode.compile. Dependency provisioning remains explicit and identical, without importing Location services.

How

  • Replaces AppNodeBuilder.build with LayerNode.compile in effect-flock.test.ts.
  • Applies the same focused construction in effect-flock-worker.ts, where repeated process startup makes the import graph especially expensive.
  • Leaves worker count, lock timings, production code, and assertions unchanged.

Scope

This is a test-harness import-boundary change only. It does not reduce contention coverage or alter EffectFlock behavior. Reducing the 16-worker stress count is a separate coverage tradeoff and is intentionally excluded.

Testing

  • Audit baseline: median 6.45s, range 5.82-8.58s
  • Focused result: 1 warmup + 7 measured runs, median 3.64s, range 3.44-5.41s
  • Benchmark: 96 passed across 8 suite runs
  • Focused suite: 12 passed
  • bun typecheck from packages/core
  • Push hook: typechecked all 39 workspace packages
  • Oxlint, Prettier, and git diff --check

@kitlangton
kitlangton merged commit b4abeb4 into v2 Aug 11, 2026
9 of 10 checks passed
@kitlangton
kitlangton deleted the speed-flock-tests branch August 11, 2026 20:51
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant