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
HDDS-2461. Logging by ChunkUtils is misleading #144
Conversation
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.
WBMT (was bothering me, too) :)
LGTM, with one question.
...ner-service/src/main/java/org/apache/hadoop/ozone/container/keyvalue/helpers/ChunkUtils.java
Outdated
Show resolved
Hide resolved
private static final Logger LOG = LoggerFactory.getLogger( | ||
ChunkManagerDummyImpl.class); |
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.
Sorry, I didn't notice this one earlier: we should keep this, since writeChunk
uses it. (If removed it will use the one inherited from ChunkManagerImpl
, resulting in wrong class name in log message.)
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.
Yes, thanks. And the LOG should be private in ChunkManagerImpl to avoid such mistakes.
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.
+1 LGTM.
Thank You @elek for the contribution and @adoroszlai for the review. |
What changes were proposed in this pull request?
During a k8s based test I found a lot of log message like:
I was very surprised as at
ChunkManagerImpl:209
there was no related lines.It turned out that it's logged by
ChunkUtils
but it's used the logger ofChunkManagerImpl
.What is the link to the Apache JIRA
https://issues.apache.org/jira/browse/HDDS-2461
How was this patch tested?
I deployed a new version from Ozone to the kubernetes cluster. But I also added a new test method TestChunkUtil to have at least one unit test method which uses the logger.