You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@activemq.apache.org by cl...@apache.org on 2020/05/16 15:40:18 UTC

[activemq-artemis] 01/03: ARTEMIS-2767 Perf Improvement. Routing = null should still reuse context

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

clebertsuconic pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/activemq-artemis.git

commit 55582772f9a17b75bee31f2613aab1551997c54a
Author: Clebert Suconic <cl...@apache.org>
AuthorDate: Sat May 16 00:13:29 2020 -0400

    ARTEMIS-2767 Perf Improvement. Routing = null should still reuse context
---
 .../apache/activemq/artemis/core/server/impl/RoutingContextImpl.java    | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/artemis-server/src/main/java/org/apache/activemq/artemis/core/server/impl/RoutingContextImpl.java b/artemis-server/src/main/java/org/apache/activemq/artemis/core/server/impl/RoutingContextImpl.java
index 2431ced..38f5dd7 100644
--- a/artemis-server/src/main/java/org/apache/activemq/artemis/core/server/impl/RoutingContextImpl.java
+++ b/artemis-server/src/main/java/org/apache/activemq/artemis/core/server/impl/RoutingContextImpl.java
@@ -210,7 +210,7 @@ public final class RoutingContextImpl implements RoutingContext {
 
    @Override
    public RoutingContext setRoutingType(RoutingType routingType) {
-      if (this.routingType == null || this.routingType != routingType) {
+      if (this.routingType == null && routingType != null || this.routingType != routingType) {
          this.clear();
       }
       this.routingType = routingType;