-
Notifications
You must be signed in to change notification settings - Fork 9.2k
HADOOP-18885. Add rpcCallsRejectedByObserver metric to quantify the number of rejected RPCs by Observer NameNode #6043
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
Conversation
|
💔 -1 overall
This message was automatically generated. |
|
Hi Sirs @Hexiaoqiao @ayushtkn @goiri @ZanderXu @simbadzina @slfan1989 Could you please help me review this pr when you have free time ? Thanks a lot~ |
|
🎊 +1 overall
This message was automatically generated. |
simbadzina
left a comment
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.
LGTM. Just one suggestion to make it easier to figure out where the retriable exception is coming from.
| } | ||
| } | ||
| } catch (IOException ioe) { | ||
| if (ioe instanceof RetriableException) { |
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.
Consider putting a try catch blocked around receiveRequestState. This makes it easier to see where the exception is coming from, instead of checking the type of exception later. So something like
try {
stateId = alignmentContext.receiveRequestState(header, getMaxIdleTime());
} catch (RetriableException re) {
rpcMetrics.incrRcRejectedByObserverCalls();
throw re;
}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.
Sir @simbadzina thanks help me review and suggestions.
I will update later PR.
…umber of rejected RPCs by Observer NameNode
d0c26cb to
22aa648
Compare
|
Update PR. |
simbadzina
left a comment
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 you push new commits please just push without using force push so that the pull request's history is preserved.
| /** | ||
| * Increments the Observer NameNode rejected RPC Calls Counter. | ||
| */ | ||
| public void incrRcRejectedByObserverCalls() { |
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.
Can you expand Rc to Rpc. You can rename this to incrRpcCallsRejectedByObserver.
| @Metric("Number of successful RPC calls") | ||
| MutableCounterLong rpcCallSuccesses; | ||
| @Metric("Number of observer namenode rejected RPC calls") | ||
| MutableCounterLong rpcRejectedByObserverCalls; |
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.
I suggest renaming to rpcCallsRejectedByObserver
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.
Thanks sir suggestions, i will update it.
|
Hi @simbadzina sir please help me review this pr again when you have free time. Thanks a lot~ |
|
💔 -1 overall
This message was automatically generated. |
|
💔 -1 overall
This message was automatically generated. |
|
💔 -1 overall
This message was automatically generated. |
|
Build failure looks unrelated to your changes. Try pushing an empty commit in order to retrigger Yetus. |
yeah,i will push an empty commit in order to retrigger Yetus again |
|
💔 -1 overall
This message was automatically generated. |
|
The failed unit test seems unrelated to the change. |
|
@goiri Hi Sir, Could you please help me push this modification forward when you have free time ? Thanks a lot~ |
|
Hi @goiri @simbadzina sirs , can you help me push this modification forward when you have free time ? Thank you very much. |
|
Hi @goiri @simbadzina excuse me, could you mind to push this modification forward when you have free time ? Thank you very much. |
| @Metric("Number of successful RPC calls") | ||
| MutableCounterLong rpcCallSuccesses; | ||
| @Metric("Number of observer namenode rejected RPC calls") | ||
| MutableCounterLong rpcCallsRejectedByObserver; |
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.
Thanks @haiyang1987 for your report. And thanks @simbadzina @goiri for your review.
I'm just concern if it's reasonable that rpcCallsRejectedByObserver is in RpcMetrics.java. I think rpcCallsRejectedByObserver is a logic of namenode, so how about changing this logic as a HDFS issue, not common issue?
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.
Thanks @ZanderXu for your comment.
@goiri @simbadzina What do you think? If necessary, I will modify it into an HDFS issue to achieve this requirement.
thanks~
|
We're closing this stale PR because it has been open for 100 days with no activity. This isn't a judgement on the merit of the PR in any way. It's just a way of keeping the PR queue manageable. |
Description of PR
https://issues.apache.org/jira/browse/HADOOP-18885
When observer Node's serverStateId is too far behind clientStateId will rejected client RPC request,
mabe we need add rpcRejectedByObserverCalls metric to RpcMetrics to quantify the number of rejected RPCs by Observer NameNode to help determine how well the server.