Skip to content

chore: spawn actors after sync#2144

Open
SantiagoPittella wants to merge 1 commit into
nextfrom
santiagopittella-ntx-builder-block-sub-phase-2
Open

chore: spawn actors after sync#2144
SantiagoPittella wants to merge 1 commit into
nextfrom
santiagopittella-ntx-builder-block-sub-phase-2

Conversation

@SantiagoPittella
Copy link
Copy Markdown
Collaborator

Second PR of the ntx-builder block-subscription refactor. PR 1 left the actors deactivated behind a subscription-driven sync loop. This PR reintroduces the actor lifecycle driven by committed blocks.

The builder now runs three steps:

  1. catch-up,
  2. a one-shot boundary that spawns an actor per account with carry-over pending notes,
  3. a steady-state loop that applies each block then has the coordinator spawn actors for newly note-targeted accounts and wake the rest.

The coordinator is now a pure lifecycle owner (handle_committed_block) with the old mempool-shape write_event/send_targeted removed, and chain state is shared with actors via Arc<SharedChainState>.

Actors here are lifecycle-only: an actor waits for its account to be committed locally, then idles on notify/timeout. No transactions are built or submitted yet (will be reconnected in PR 3).

@SantiagoPittella SantiagoPittella added the no changelog This PR does not require an entry in the `CHANGELOG.md` file label May 26, 2026
@SantiagoPittella SantiagoPittella force-pushed the santiagopittella-ntx-builder-block-sub-phase-2 branch from b27ba78 to 207b4eb Compare May 26, 2026 20:47
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

no changelog This PR does not require an entry in the `CHANGELOG.md` file

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant