Skip to content

cre-4799: Shard Failover - sender and receiver wired - #23487

Open
mchain0 wants to merge 2 commits into
cre-4799from
cre-4799-p2
Open

cre-4799: Shard Failover - sender and receiver wired#23487
mchain0 wants to merge 2 commits into
cre-4799from
cre-4799-p2

Conversation

@mchain0

@mchain0 mchain0 commented Aug 21, 2026

Copy link
Copy Markdown
Contributor

The sender and receiver are fully wired:

  • Primary shard: wireShardFailoverHooks creates an ExecutionCompletedSender (targeting the secondary DON resolved via shardDonLookup), wires it into the engine's OnExecutionCompleted lifecycle hook, and registers it as a sub-service for lifecycle management.
  • Secondary shard: wireShardFailoverHooks creates an ExecutionCompletedReceiver and registers it with the dispatcher via SetReceiverForMethod(MethodExecutionCompleted) so incoming Don2Don messages are delivered to it.
  • Role detection: isPrimaryShardForDon uses AllShardsResolver.ResolveAllShards to determine if this shard is the primary (first in the assignment list).
  • DON lookup: newShardDonLookup uses CapabilitiesRegistry.DONByID to resolve peer membership for the other shard.
  • Dispatcher + lookup are passed from cre.go -> newWorkflowRegistrySyncer -> newWorkflowRegistrySyncerV2 -> handler options.

It is supplementary to #23457

@github-actions

Copy link
Copy Markdown
Contributor

✅ No conflicts with other open PRs targeting cre-4799

@github-actions

Copy link
Copy Markdown
Contributor

I see you updated files related to core. Please run make gocs in the root directory to add a changeset as well as in the text include at least one of the following tags:

  • #added For any new functionality added.
  • #breaking_change For any functionality that requires manual action for the node to boot.
  • #bugfix For bug fixes.
  • #changed For any change to the existing functionality.
  • #db_update For any feature that introduces updates to database schema.
  • #deprecation_notice For any upcoming deprecation functionality.
  • #internal For changesets that need to be excluded from the final changelog.
  • #nops For any feature that is NOP facing and needs to be in the official Release Notes for the release.
  • #removed For any functionality/config that is removed.
  • #updated For any functionality that is updated.
  • #wip For any change that is not ready yet and external communication about it should be held off till it is feature complete.

@trunk-io

trunk-io Bot commented Aug 21, 2026

Copy link
Copy Markdown

Static BadgeStatic BadgeStatic Badge

View Full Report ↗︎Docs

@mchain0
mchain0 requested review from bolekk and pavel-raykov August 21, 2026 13:58
@mchain0
mchain0 force-pushed the cre-4799-p2 branch 4 times, most recently from 98427a4 to d77a574 Compare August 21, 2026 15:32
@mchain0
mchain0 marked this pull request as ready for review August 21, 2026 16:14
@mchain0
mchain0 requested review from a team as code owners August 21, 2026 16:14
@cl-sonarqube-production

Copy link
Copy Markdown

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant