-
Notifications
You must be signed in to change notification settings - Fork 3.4k
HBASE-29843 HBaseRPCController.setPriority(final TableName tn) is nev… #7692
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
base: master
Are you sure you want to change the base?
Conversation
|
🎊 +1 overall
This message was automatically generated. |
|
💔 -1 overall
This message was automatically generated. |
|
@stoty Please see if this could solve Phoenix's problem? I introduced a new setPriority method and the default implementation in the interface is call setPriority(int) and then setPriority(TableName). Thanks. |
| (int) Math.min(Integer.MAX_VALUE, TimeUnit.NANOSECONDS.toMillis(timeoutNs))); | ||
| } | ||
| controller.setPriority(priority); | ||
| controller.setPriority(priority, tableName); |
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.
Thank you for this change.
I think we could make this work from the Phoenix side with adding a function to https://github.com/apache/phoenix/blob/master/phoenix-core-client/src/main/java/org/apache/hadoop/hbase/ipc/controller/MetadataRpcController.java#L70
public void setPriority(int priority, final TableName tn) {
setPriority(tn);
}
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.
With this change in place, Phoenix does not need any change, since the default method of setPriority(int, TableName) is to call setPriority(int) and then setPriority(TableName).
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.
When we call controller.setPriority(priority, tableName); on the metadataRpcController which doesn't have a setPriority(priority, tableName) method it results calling the
DelegatingHBaseRpcController's setPriority(int priority, @Nullable TableName tableName) method
It calls the delegate.setPriority(priority, tableName) ( not setPriority(int) and then setPriority(TableName) )
Where the delegate is HBaseRpcControllerImpl
So we won't call the MetadataRpcController's setPriority(TableName)
…er called on branch-3+
…er called on branch-3+