-
Notifications
You must be signed in to change notification settings - Fork 477
log exception on failure set table prop #6057
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
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -579,10 +579,12 @@ private void alterTableProperty(TCredentials c, String tableName, String propert | |
| } | ||
| PropUtil.setProperties(manager.getContext(), TablePropKey.of(manager.getContext(), tableId), | ||
| Map.of(property, value)); | ||
| } else { | ||
| throw new UnsupportedOperationException("table operation:" + op.name()); | ||
| } | ||
| } catch (IllegalStateException ex) { | ||
| log.warn("Invalid table property, tried to set: tableId: " + tableId.canonical() + " to: " | ||
|
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Line 574 can also return an IllegalStateException This log message should include the table OP instead of assuming it's always a
Contributor
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Updated in 5480b83 |
||
| + property + "=" + value); | ||
| log.warn("Invalid table property, tried to {}: tableId: {} to: {}={}", op.name(), | ||
| tableId.canonical(), property, value, ex); | ||
| // race condition... table no longer exists? This call will throw an exception if the table | ||
| // was deleted: | ||
| ClientServiceHandler.checkTableId(manager.getContext(), tableName, op); | ||
|
|
||
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.
Currently the client code is only calling the RPC w/ the two values. However this server side code should not ignore seeing something else. This new throw should cause an error to be logged and TApplicationException on the client side should this ever happen.