You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@logging.apache.org by gg...@apache.org on 2015/12/31 01:49:55 UTC

logging-log4j2 git commit: [LOG4J2-1238] org.apache.logging.log4j.core.net.TcpSocketManager does not display stack traces.

Repository: logging-log4j2
Updated Branches:
  refs/heads/master aa2c0cdbd -> f965d5155


[LOG4J2-1238] org.apache.logging.log4j.core.net.TcpSocketManager does
not display stack traces.

Project: http://git-wip-us.apache.org/repos/asf/logging-log4j2/repo
Commit: http://git-wip-us.apache.org/repos/asf/logging-log4j2/commit/f965d515
Tree: http://git-wip-us.apache.org/repos/asf/logging-log4j2/tree/f965d515
Diff: http://git-wip-us.apache.org/repos/asf/logging-log4j2/diff/f965d515

Branch: refs/heads/master
Commit: f965d51552b29ec602378c9a3e1cff2b97c28ebf
Parents: aa2c0cd
Author: ggregory <gg...@apache.org>
Authored: Wed Dec 30 16:49:51 2015 -0800
Committer: ggregory <gg...@apache.org>
Committed: Wed Dec 30 16:49:51 2015 -0800

----------------------------------------------------------------------
 .../java/org/apache/logging/log4j/core/net/TcpSocketManager.java | 4 ++--
 src/changes/changes.xml                                          | 3 +++
 2 files changed, 5 insertions(+), 2 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/logging-log4j2/blob/f965d515/log4j-core/src/main/java/org/apache/logging/log4j/core/net/TcpSocketManager.java
----------------------------------------------------------------------
diff --git a/log4j-core/src/main/java/org/apache/logging/log4j/core/net/TcpSocketManager.java b/log4j-core/src/main/java/org/apache/logging/log4j/core/net/TcpSocketManager.java
index f9aabb3..a487438 100644
--- a/log4j-core/src/main/java/org/apache/logging/log4j/core/net/TcpSocketManager.java
+++ b/log4j-core/src/main/java/org/apache/logging/log4j/core/net/TcpSocketManager.java
@@ -278,7 +278,7 @@ public class TcpSocketManager extends AbstractSocketManager {
             try {
                 inetAddress = InetAddress.getByName(data.host);
             } catch (final UnknownHostException ex) {
-                LOGGER.error("Could not find address of " + data.host, ex);
+                LOGGER.error("Could not find address of " + data.host, ex, ex);
                 return null;
             }
             try {
@@ -289,7 +289,7 @@ public class TcpSocketManager extends AbstractSocketManager {
                 return new TcpSocketManager(name, os, socket, inetAddress, data.host, data.port,
                         data.connectTimeoutMillis, data.delayMillis, data.immediateFail, data.layout);
             } catch (final IOException ex) {
-                LOGGER.error("TcpSocketManager (" + name + ") " + ex);
+                LOGGER.error("TcpSocketManager (" + name + ") " + ex, ex);
                 os = new ByteArrayOutputStream();
             }
             if (data.delayMillis == 0) {

http://git-wip-us.apache.org/repos/asf/logging-log4j2/blob/f965d515/src/changes/changes.xml
----------------------------------------------------------------------
diff --git a/src/changes/changes.xml b/src/changes/changes.xml
index cd9ca6f..dee5215 100644
--- a/src/changes/changes.xml
+++ b/src/changes/changes.xml
@@ -31,6 +31,9 @@
       <action issue="LOG4J2-908" dev="ggregory" type="fix" due-to="Konstantinos Liakos, Patrick Flaherty, Robin Coe, Gary Gregory">
         JSONLayout doesn't add a comma between log events.
       </action>
+      <action issue="LOG4J2-1238" dev="ggregory" type="fix">
+        org.apache.logging.log4j.core.net.TcpSocketManager does not display stack traces.
+      </action>
       <action issue="LOG4J2-1212" dev="rpopma" type="fix">
         Fix documentation to correctly specify the blocking wait strategy as the default for async loggers.
       </action>