-
Notifications
You must be signed in to change notification settings - Fork 838
Add capability to have multiple domains in replication simulation #6923
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add capability to have multiple domains in replication simulation #6923
Conversation
@@ -79,7 +79,7 @@ func main() { | |||
} | |||
|
|||
dispatcher := yarpc.NewDispatcher(yarpc.Config{ | |||
Name: simTypes.WorkerIdentityFor(*clusterName), | |||
Name: simTypes.WorkerIdentityFor(*clusterName, "test-domain"), |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I guess we don't need to hardcode test-domain
here. you can use another name for dispatcher config
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
yeah, I was passing an empty string here. I was testing and forgot to revert it
Logger: logger, | ||
MetricsScope: tally.NewTestScope(simTypes.TasklistName, map[string]string{"cluster": *clusterName}), | ||
for domainName := range simCfg.Domains { | ||
waitUntilDomainReady(logger, cadenceClient, domainName) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
there's only 1 /health endpoint and it will be marked ready as soon as first domain is created. I recommend running waitUntilDomainReady
in goroutines and wait for both of them to return. Also the /health handler above should return OK if ready == num_domains
for domainName := range simCfg.Domains { | ||
waitUntilWorkersReady(t, domainName) | ||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
this doesn't need to be done per domain. see my other comment. worker readyness endpoint can deal with multiple domain aspect
What changed?
Add capability to have multiple domains in replication simulation. Allow workflows to target the domain where it will be created and create workers for all registered domains.
Why?
We want to simulate failover and replication involving multiple domains.
How did you test it?
Tested locally with the existing simulations
Potential risks
Release notes
Documentation Changes