Skip to content

fix(active-active): Fix query workflow for active-active domains#7339

Merged
Shaddoll merged 1 commit intocadence-workflow:masterfrom
Shaddoll:aa
Oct 16, 2025
Merged

fix(active-active): Fix query workflow for active-active domains#7339
Shaddoll merged 1 commit intocadence-workflow:masterfrom
Shaddoll:aa

Conversation

@Shaddoll
Copy link
Member

What changed?
Fix query workflow for active-active domains

Why?
In active-active domains, the active cluster of an workflow is also determined by the active cluster selection policy.

How did you test it?
unit tests

Potential risks

Release notes

Documentation Changes

clusterAttribute := mutableState.GetExecutionInfo().ActiveClusterSelectionPolicy.GetClusterAttribute()
activeClusterInfo, exists := de.GetActiveClusterInfoByClusterAttribute(clusterAttribute)
if !exists {
// TODO: this is only possible if the domain metadata doesn't have the cluster attribute, should we return an error instead?
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think we want to default to the domains ActiveClusterName here - this will be a 'normal' scenario when someone uses a ClusterAttribute that exists but hasn't been onboarded to their domain data yet.

@Shaddoll Shaddoll merged commit aafc9f5 into cadence-workflow:master Oct 16, 2025
47 of 48 checks passed
@Shaddoll Shaddoll deleted the aa branch October 16, 2025 20:07
instamitch pushed a commit to instamitch/cadence that referenced this pull request Oct 21, 2025
…ence-workflow#7339)

<!-- Describe what has changed in this PR -->
**What changed?**
Fix query workflow for active-active domains

<!-- Tell your future self why have you made these changes -->
**Why?**
In active-active domains, the active cluster of an workflow is also
determined by the active cluster selection policy.

<!-- How have you verified this change? Tested locally? Added a unit
test? Checked in staging env? -->
**How did you test it?**
unit tests

<!-- Assuming the worst case, what can be broken when deploying this
change to production? -->
**Potential risks**

<!-- Is it notable for release? e.g. schema updates, configuration or
data migration required? If so, please mention it, and also update
CHANGELOG.md -->
**Release notes**

<!-- Is there any documentation updates should be made for config,
https://cadenceworkflow.io/docs/operation-guide/setup/ ? If so, please
open an PR in https://github.com/cadence-workflow/cadence-docs -->
**Documentation Changes**

Signed-off-by: Mitch O'Dea <mitchelo@netapp.com>
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.

2 participants