-
Notifications
You must be signed in to change notification settings - Fork 3.3k
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
HBASE-27888 Record readBlock message in log when it takes too long time #5255
Conversation
💔 -1 overall
This message was automatically generated. |
f42e407
to
f305516
Compare
🎊 +1 overall
This message was automatically generated. |
🎊 +1 overall
This message was automatically generated. |
💔 -1 overall
This message was automatically generated. |
💔 -1 overall
This message was automatically generated. |
🎊 +1 overall
This message was automatically generated. |
/** | ||
* If reading block cost time more than the threshold, a warning will be logged. | ||
*/ | ||
public static final String FS_READER_WARN_TIME = "hbase.fs.reader.warn.time"; |
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.
Better add this somewhere in the hbase-server module?
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.
there are no constants for hbase-server module, i refer "hbase.writer.unified.encoded.blocksize.ratio" in HFileWriterImpl class, and define it in org.apache.hadoop.hbase.io.hfile.HFileBlock.FSReaderImpl.
@@ -2062,4 +2062,9 @@ possible configurations would overwhelm and obscure the important. | |||
hitting the namenode, if the DFSInputStream's block list is incomplete. | |||
</description> | |||
</property> | |||
<property> | |||
<name>hbase.fs.reader.warn.time</name> | |||
<value>100</value> |
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.
Is 100ms a good default value? Maybe we should set it to 0 or -1, means disable the logging, and if users want, they can set it to the value they want?
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 for reviewing, i set the default value to -1 in the lastest commit in this MR
@@ -2062,4 +2062,9 @@ possible configurations would overwhelm and obscure the important. | |||
hitting the namenode, if the DFSInputStream's block list is incomplete. | |||
</description> | |||
</property> | |||
<property> | |||
<name>hbase.fs.reader.warn.time</name> |
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.
Better add a '.ms' suffix so users know it is in milliseconds, without reading the description.
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.
fine, added it
f305516
to
3403e81
Compare
🎊 +1 overall
This message was automatically generated. |
3403e81
to
ef8584c
Compare
🎊 +1 overall
This message was automatically generated. |
🎊 +1 overall
This message was automatically generated. |
🎊 +1 overall
This message was automatically generated. |
💔 -1 overall
This message was automatically generated. |
🎊 +1 overall
This message was automatically generated. |
ef8584c
to
08335cd
Compare
🎊 +1 overall
This message was automatically generated. |
💔 -1 overall
This message was automatically generated. |
💔 -1 overall
This message was automatically generated. |
When not enable trace log, we also could record the slow read block message