You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@geode.apache.org by bu...@apache.org on 2021/03/02 18:03:11 UTC

[geode] branch support/1.14 updated: GEODE-8920: Modify debug logging to make it easier to trace a message (#6041) (#6071)

This is an automated email from the ASF dual-hosted git repository.

burcham pushed a commit to branch support/1.14
in repository https://gitbox.apache.org/repos/asf/geode.git


The following commit(s) were added to refs/heads/support/1.14 by this push:
     new bce7a19  GEODE-8920: Modify debug logging to make it easier to trace a message (#6041) (#6071)
bce7a19 is described below

commit bce7a19b55b51a8809e71c9a2c776eba31a4e92c
Author: Kamilla Aslami <ka...@vmware.com>
AuthorDate: Tue Mar 2 11:58:09 2021 -0600

    GEODE-8920: Modify debug logging to make it easier to trace a message (#6041) (#6071)
    
    (cherry picked from commit fc2fc9f890c5673bd6d0954048efb525b0098126)
---
 .../geode/distributed/internal/direct/DirectChannel.java       | 10 +++++-----
 .../main/java/org/apache/geode/internal/tcp/Connection.java    |  2 +-
 2 files changed, 6 insertions(+), 6 deletions(-)

diff --git a/geode-core/src/main/java/org/apache/geode/distributed/internal/direct/DirectChannel.java b/geode-core/src/main/java/org/apache/geode/distributed/internal/direct/DirectChannel.java
index fc8800f..8f65c2d 100644
--- a/geode-core/src/main/java/org/apache/geode/distributed/internal/direct/DirectChannel.java
+++ b/geode-core/src/main/java/org/apache/geode/distributed/internal/direct/DirectChannel.java
@@ -211,7 +211,7 @@ public class DirectChannel {
       InternalDistributedMember[] p_destinations,
       final DistributionMessage msg, long ackWaitThreshold, long ackSAThreshold)
       throws ConnectExceptions, NotSerializableException {
-    InternalDistributedMember destinations[] = p_destinations;
+    InternalDistributedMember[] destinations = p_destinations;
 
     // Collects connect exceptions that happened during previous attempts to send.
     // These represent members we are not able to distribute to.
@@ -276,7 +276,7 @@ public class DirectChannel {
           retryInfo = null;
           retry = true;
         }
-        final List cons = new ArrayList(destinations.length);
+        final List<Connection> cons = new ArrayList<>(destinations.length);
         ConnectExceptions ce = getConnections(mgr, msg, destinations, orderedMsg, retry, ackTimeout,
             ackSDTimeout, cons);
 
@@ -299,9 +299,9 @@ public class DirectChannel {
           return bytesWritten;
         }
 
-        if (retry && logger.isDebugEnabled()) {
-          logger.debug("Retrying send ({}{}) to {} peers ({}) via tcp/ip",
-              msg, cons.size(), cons);
+        if (logger.isDebugEnabled()) {
+          logger.debug("{} on these {} connections: {}",
+              (retry ? "Retrying send" : "Sending"), cons.size(), cons);
         }
         DMStats stats = getDMStats();
         List<?> sentCons; // used for cons we sent to this time
diff --git a/geode-core/src/main/java/org/apache/geode/internal/tcp/Connection.java b/geode-core/src/main/java/org/apache/geode/internal/tcp/Connection.java
index 6d4c675..60c418e 100644
--- a/geode-core/src/main/java/org/apache/geode/internal/tcp/Connection.java
+++ b/geode-core/src/main/java/org/apache/geode/internal/tcp/Connection.java
@@ -3224,7 +3224,7 @@ public class Connection implements Runnable {
   private void setThreadName(int dominoNumber) {
     Thread.currentThread().setName(THREAD_KIND_IDENTIFIER + " for " + remoteAddr + " "
         + (sharedResource ? "" : "un") + "shared" + " " + (preserveOrder ? "" : "un")
-        + "ordered" + " uid=" + uniqueId + (dominoNumber > 0 ? " dom #" + dominoNumber : "")
+        + "ordered sender uid=" + uniqueId + (dominoNumber > 0 ? " dom #" + dominoNumber : "")
         + " local port=" + socket.getLocalPort() + " remote port=" + socket.getPort());
   }