-
Notifications
You must be signed in to change notification settings - Fork 37
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Project import generated by Copybara.
FolderOrigin-RevId: /usr/local/google/home/gdennis/copybara/temp/folder-destination11691081639859657791/.
- Loading branch information
GGN Engprod Team
authored and
greg-dennis
committed
Aug 8, 2023
1 parent
15c812a
commit 2fd9deb
Showing
13 changed files
with
46,472 additions
and
49,870 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -160,13 +160,10 @@ func isContextErr(err error) bool { | |
GRPCStatus() *status.Status | ||
} | ||
ok := errors.As(err, &st) | ||
return ok && (st.GRPCStatus().Code() == codes.DeadlineExceeded || st.GRPCStatus().Code() == codes.Canceled) | ||
} | ||
|
||
// statusErr is an interface implemented by errors returned by gRPC. | ||
// https://pkg.go.dev/google.golang.org/[email protected]/internal/status#Error | ||
type statusErr interface { | ||
GRPCStatus() *status.Status | ||
if !ok { | ||
return errors.Is(err, context.DeadlineExceeded) || errors.Is(err, context.Canceled) | ||
} | ||
return st.GRPCStatus().Code() == codes.DeadlineExceeded || st.GRPCStatus().Code() == codes.Canceled | ||
} | ||
|
||
// Await waits for the watch to finish and returns the last received value | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.