diff --git a/core/src/main/java/org/elasticsearch/action/support/broadcast/node/TransportBroadcastByNodeAction.java b/core/src/main/java/org/elasticsearch/action/support/broadcast/node/TransportBroadcastByNodeAction.java index bc78f13433f..8bcba8ad544 100644 --- a/core/src/main/java/org/elasticsearch/action/support/broadcast/node/TransportBroadcastByNodeAction.java +++ b/core/src/main/java/org/elasticsearch/action/support/broadcast/node/TransportBroadcastByNodeAction.java @@ -223,7 +223,9 @@ public abstract class TransportBroadcastByNodeAction(); @@ -300,7 +302,9 @@ public abstract class TransportBroadcastByNodeAction shards = request.getShards(); final int totalShards = shards.size(); - logger.trace("[{}] executing operation on [{}] shards", actionName, totalShards); + if (logger.isTraceEnabled()) { + logger.trace("[{}] executing operation on [{}] shards", actionName, totalShards); + } final Object[] shardResultOrExceptions = new Object[totalShards]; int shardIndex = -1; @@ -375,10 +381,14 @@ public abstract class TransportBroadcastByNodeAction