mirror of
https://github.com/valitydev/thrift.git
synced 2024-11-07 02:45:22 +00:00
THRIFT-4726: Remove SLF4J Logging Guards
This commit is contained in:
parent
d2c6dc8e44
commit
93e8ec2d6a
@ -320,11 +320,9 @@ public class TThreadPoolServer extends TServer {
|
||||
// Ignore err-logging all transport-level/type exceptions
|
||||
if ((realCause != null && realCause instanceof TTransportException)
|
||||
|| (x instanceof TTransportException)) {
|
||||
if (LOGGER.isDebugEnabled()) {
|
||||
// Write to debug, just in case the exception gets required
|
||||
LOGGER
|
||||
.debug("Received TTransportException during processing of message, ignoring: ", x);
|
||||
}
|
||||
LOGGER.debug(
|
||||
"Received TTransportException during processing of message. Ignoring.",
|
||||
x);
|
||||
} else {
|
||||
// Log the exception at error level and continue
|
||||
LOGGER.error("Error occurred during processing of message.", x);
|
||||
|
@ -158,9 +158,9 @@ abstract class TSaslTransport extends TTransport {
|
||||
messageHeader[0] = status.getValue();
|
||||
EncodingUtils.encodeBigEndian(payload.length, messageHeader, STATUS_BYTES);
|
||||
|
||||
if (LOGGER.isDebugEnabled())
|
||||
LOGGER.debug(getRole() + ": Writing message with status {} and payload length {}",
|
||||
status, payload.length);
|
||||
LOGGER.debug("{}: Writing message with status {} and payload length {}",
|
||||
getRole(), status, payload.length);
|
||||
|
||||
underlyingTransport.write(messageHeader);
|
||||
underlyingTransport.write(payload);
|
||||
underlyingTransport.flush();
|
||||
@ -197,10 +197,8 @@ abstract class TSaslTransport extends TTransport {
|
||||
String remoteMessage = new String(payload, StandardCharsets.UTF_8);
|
||||
throw new TTransportException("Peer indicated failure: " + remoteMessage);
|
||||
}
|
||||
|
||||
if (LOGGER.isDebugEnabled())
|
||||
LOGGER.debug(getRole() + ": Received message with status {} and payload length {}",
|
||||
status, payload.length);
|
||||
LOGGER.debug("{}: Received message with status {} and payload length {}",
|
||||
getRole(), status, payload.length);
|
||||
return new SaslResponse(status, payload);
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user