Skip to content
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

Cluster not found #4501

Merged
merged 3 commits into from
Jun 16, 2023
Merged
Changes from 2 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions client/clientBean.go
Original file line number Diff line number Diff line change
Expand Up @@ -184,7 +184,7 @@ func (h *clientBeanImpl) GetRemoteAdminClient(cluster string) (adminservice.Admi

clusterInfo, clusterFound := h.clusterMetadata.GetAllClusterInfo()[cluster]
if !clusterFound {
return nil, &serviceerror.NotFound{
return nil, &serviceerror.Unavailable{
Copy link
Member

Choose a reason for hiding this comment

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

How do you differentiate real NOT_FOUND case?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

This not found err is translated to workflow not found on SDK side. This is kind of revert the change: https://github.com/temporalio/temporal/pull/3557/files#diff-0fb06c985229c9113e2a3fdd295d262429b58e003f73cabf860c432fc3529d47L194.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

We don't need to differentiate the not found. This is due to some server side misconfig and should not be a not found.

Copy link
Member

Choose a reason for hiding this comment

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

Don't have the full context here but thought I'd drop by and mention that Unavailable error reaching a client counts against our SLA in cloud and is considered retryable vs. NotFound which should not be retried by default, I'm assuming this is desirable.

Copy link
Member

Choose a reason for hiding this comment

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

I remember last time we changed this to NotFound so that standby task won't get stuck when remote cluster is not found.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Then I cannot do it.

Copy link
Member

@yycptt yycptt Jun 15, 2023

Choose a reason for hiding this comment

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

Maybe check-in a comment re. why it's not found? or you plan to fix it in a different way?

Message: fmt.Sprintf(
"Unknown cluster name: %v with given cluster information map: %v.",
cluster,
Expand Down Expand Up @@ -229,7 +229,7 @@ func (h *clientBeanImpl) GetRemoteFrontendClient(clusterName string) (grpc.Clien

clusterInfo, clusterFound := h.clusterMetadata.GetAllClusterInfo()[clusterName]
if !clusterFound {
return nil, nil, &serviceerror.NotFound{
return nil, nil, &serviceerror.Unavailable{
Message: fmt.Sprintf(
"Unknown clusterName name: %v with given clusterName information map: %v.",
clusterName,
Expand Down