sijie closed pull request #909: BookieProtoEncoding: log messages at TRACE
rather than DEBUG
URL: https://github.com/apache/bookkeeper/pull/909
This is a PR merged from a forked repository.
As GitHub hides the original diff on merge, it is displayed below for
the sake of provenance:
As this is a foreign pull request (from a fork), the diff is supplied
below (as it won't show otherwise due to GitHub magic):
diff --git
a/bookkeeper-server/src/main/java/org/apache/bookkeeper/proto/BookieProtoEncoding.java
b/bookkeeper-server/src/main/java/org/apache/bookkeeper/proto/BookieProtoEncoding.java
index 18cecf83a..00db67cff 100644
---
a/bookkeeper-server/src/main/java/org/apache/bookkeeper/proto/BookieProtoEncoding.java
+++
b/bookkeeper-server/src/main/java/org/apache/bookkeeper/proto/BookieProtoEncoding.java
@@ -385,6 +385,9 @@ public RequestEncoder(ExtensionRegistry extensionRegistry) {
@Override
protected void encode(ChannelHandlerContext ctx, Object msg,
List<Object> out) throws Exception {
+ if (LOG.isTraceEnabled()) {
+ LOG.trace("Encode request {} to channel {}.", msg,
ctx.channel());
+ }
if (msg instanceof BookkeeperProtocol.Request) {
out.add(reqV3.encode(msg, ctx.alloc()));
} else if (msg instanceof BookieProtocol.Request) {
@@ -413,8 +416,8 @@ protected void encode(ChannelHandlerContext ctx, Object
msg, List<Object> out) t
@Override
protected void decode(ChannelHandlerContext ctx, Object msg,
List<Object> out) throws Exception {
- if (LOG.isDebugEnabled()) {
- LOG.debug("Received request {} from channel {} to decode.",
msg, ctx.channel());
+ if (LOG.isTraceEnabled()) {
+ LOG.trace("Received request {} from channel {} to decode.",
msg, ctx.channel());
}
if (!(msg instanceof ByteBuf)) {
out.add(msg);
@@ -453,8 +456,8 @@ protected void decode(ChannelHandlerContext ctx, Object
msg, List<Object> out) t
@Override
protected void encode(ChannelHandlerContext ctx, Object msg,
List<Object> out)
throws Exception {
- if (LOG.isDebugEnabled()) {
- LOG.debug("Encode response {} to channel {}.", msg,
ctx.channel());
+ if (LOG.isTraceEnabled()) {
+ LOG.trace("Encode response {} to channel {}.", msg,
ctx.channel());
}
if (msg instanceof BookkeeperProtocol.Response) {
out.add(repV3.encode(msg, ctx.alloc()));
@@ -484,8 +487,8 @@ protected void encode(ChannelHandlerContext ctx, Object
msg, List<Object> out)
@Override
protected void decode(ChannelHandlerContext ctx, Object msg,
List<Object> out) throws Exception {
- if (LOG.isDebugEnabled()) {
- LOG.debug("Received response {} from channel {} to decode.",
msg, ctx.channel());
+ if (LOG.isTraceEnabled()) {
+ LOG.trace("Received response {} from channel {} to decode.",
msg, ctx.channel());
}
if (!(msg instanceof ByteBuf)) {
out.add(msg);
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
[email protected]
With regards,
Apache Git Services