-
Notifications
You must be signed in to change notification settings - Fork 2.1k
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
Wrap errors happening during PRS in a new vterrors
code
#17669
base: main
Are you sure you want to change the base?
Conversation
Signed-off-by: Florent Poinsard <[email protected]>
Review ChecklistHello reviewers! 👋 Please follow this checklist when reviewing this Pull Request. General
Tests
Documentation
New flags
If a workflow is added or modified:
Backward compatibility
|
vterrors
errorvterrors
code
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #17669 +/- ##
==========================================
- Coverage 67.75% 67.74% -0.02%
==========================================
Files 1587 1587
Lines 255778 255808 +30
==========================================
- Hits 173309 173287 -22
- Misses 82469 82521 +52 ☔ View full report in Codecov by Sentry. |
@@ -120,6 +120,8 @@ var ( | |||
VT14004 = errorWithoutState("VT14004", vtrpcpb.Code_UNAVAILABLE, "cannot find keyspace for: %s", "The specified keyspace could not be found.") | |||
VT14005 = errorWithoutState("VT14005", vtrpcpb.Code_UNAVAILABLE, "cannot lookup sidecar database for keyspace: %s", "Failed to read sidecar database identifier.") | |||
|
|||
VT15001 = errorWithNoCode("VT15001", "session invalidated: close/reopen connection if applicable: %s", "This error means that the opened transaction should be closed by the application and re-opened.") |
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.
"session invalidated" may be misleading
- if you are in a transaction, that needs to be closed, and a new transaction opened.
- if you are not in a transaction, a retry is probably what you need to do.
@harshit-gangal wdyt?
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.
It is the transaction which no longer exists. They can continue to use the same connection.
"rollback", followed by a retry is fine.
outside of transaction, retry is enough as Deepthi pointed.
All 3 error message should have different error code as they happen at different point in time of PRS/ERS
Notes from further offline discussion:
We need to spend some more time exploring these options. |
Signed-off-by: Florent Poinsard <[email protected]>
Signed-off-by: Florent Poinsard <[email protected]>
Description
This Pull Request adds a new
vterrors
code (VT15001
) that will wrap the common errors found in the situation described by #17668.The errors listed in #17668 now look like this:
Related Issue(s)