From 1bc42be7ffc219916cd37c9fb2105c11863fa817 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ville=20Skytt=C3=A4?= Date: Fri, 29 Jul 2016 11:44:24 +0300 Subject: [PATCH] Access static fields and methods directly --- .../java/org/apache/activemq/artemis/api/core/JsonUtil.java | 2 +- .../apache/activemq/artemis/maven/ArtemisAbstractPlugin.java | 4 ++-- .../artemis/core/protocol/proton/ProtonProtocolManager.java | 4 ++-- .../artemis/tests/integration/cluster/bridge/BridgeTest.java | 3 ++- 4 files changed, 7 insertions(+), 6 deletions(-) diff --git a/artemis-core-client/src/main/java/org/apache/activemq/artemis/api/core/JsonUtil.java b/artemis-core-client/src/main/java/org/apache/activemq/artemis/api/core/JsonUtil.java index 64d1f40bdb..62bb8713ff 100644 --- a/artemis-core-client/src/main/java/org/apache/activemq/artemis/api/core/JsonUtil.java +++ b/artemis-core-client/src/main/java/org/apache/activemq/artemis/api/core/JsonUtil.java @@ -156,7 +156,7 @@ public final class JsonUtil { array[i] = map; } else { - if (val == JsonObject.NULL) { + if (val == JsonValue.NULL) { array[i] = null; } else { diff --git a/artemis-maven-plugin/src/main/java/org/apache/activemq/artemis/maven/ArtemisAbstractPlugin.java b/artemis-maven-plugin/src/main/java/org/apache/activemq/artemis/maven/ArtemisAbstractPlugin.java index 8a1185732d..32a9f6ac88 100644 --- a/artemis-maven-plugin/src/main/java/org/apache/activemq/artemis/maven/ArtemisAbstractPlugin.java +++ b/artemis-maven-plugin/src/main/java/org/apache/activemq/artemis/maven/ArtemisAbstractPlugin.java @@ -26,7 +26,7 @@ import java.util.List; import java.util.Set; import java.util.concurrent.atomic.AtomicInteger; -import org.apache.activemq.artemis.cli.commands.tools.OptionalLocking; +import org.apache.activemq.artemis.cli.commands.tools.LockAbstract; import org.apache.maven.artifact.repository.ArtifactRepository; import org.apache.maven.plugin.AbstractMojo; import org.apache.maven.plugin.MojoExecutionException; @@ -76,7 +76,7 @@ public abstract class ArtemisAbstractPlugin extends AbstractMojo { // We could execute the maven plugins over and over on examples // For that reason we just unlock the server here // Notice this has no implementations if you are using spawn - OptionalLocking.unlock(); + LockAbstract.unlock(); } } diff --git a/artemis-protocols/artemis-amqp-protocol/src/main/java/org/apache/activemq/artemis/core/protocol/proton/ProtonProtocolManager.java b/artemis-protocols/artemis-amqp-protocol/src/main/java/org/apache/activemq/artemis/core/protocol/proton/ProtonProtocolManager.java index 1b1699f5e0..c42e95ed29 100644 --- a/artemis-protocols/artemis-amqp-protocol/src/main/java/org/apache/activemq/artemis/core/protocol/proton/ProtonProtocolManager.java +++ b/artemis-protocols/artemis-amqp-protocol/src/main/java/org/apache/activemq/artemis/core/protocol/proton/ProtonProtocolManager.java @@ -30,7 +30,7 @@ import org.apache.activemq.artemis.core.remoting.impl.netty.NettyServerConnectio import org.apache.activemq.artemis.core.server.ActiveMQServer; import org.apache.activemq.artemis.core.server.management.Notification; import org.apache.activemq.artemis.core.server.management.NotificationListener; -import org.apache.activemq.artemis.jms.client.ActiveMQTopic; +import org.apache.activemq.artemis.jms.client.ActiveMQDestination; import org.apache.activemq.artemis.spi.core.protocol.ConnectionEntry; import org.apache.activemq.artemis.spi.core.protocol.MessageConverter; import org.apache.activemq.artemis.spi.core.protocol.ProtocolManager; @@ -59,7 +59,7 @@ public class ProtonProtocolManager implements ProtocolManager, Noti * used when you want to treat senders as a subscription on an address rather than consuming from the actual queue for * the address. This can be changed on the acceptor. * */ - private String pubSubPrefix = ActiveMQTopic.JMS_TOPIC_ADDRESS_PREFIX; + private String pubSubPrefix = ActiveMQDestination.JMS_TOPIC_ADDRESS_PREFIX; public ProtonProtocolManager(ProtonProtocolManagerFactory factory, ActiveMQServer server) { this.factory = factory; diff --git a/tests/integration-tests/src/test/java/org/apache/activemq/artemis/tests/integration/cluster/bridge/BridgeTest.java b/tests/integration-tests/src/test/java/org/apache/activemq/artemis/tests/integration/cluster/bridge/BridgeTest.java index 0da45613a4..b8d746cec8 100644 --- a/tests/integration-tests/src/test/java/org/apache/activemq/artemis/tests/integration/cluster/bridge/BridgeTest.java +++ b/tests/integration-tests/src/test/java/org/apache/activemq/artemis/tests/integration/cluster/bridge/BridgeTest.java @@ -37,6 +37,7 @@ import java.util.concurrent.atomic.AtomicInteger; import org.apache.activemq.artemis.api.core.ActiveMQBuffer; import org.apache.activemq.artemis.api.core.ActiveMQException; import org.apache.activemq.artemis.api.core.Interceptor; +import org.apache.activemq.artemis.api.core.Message; import org.apache.activemq.artemis.api.core.SimpleString; import org.apache.activemq.artemis.api.core.TransportConfiguration; import org.apache.activemq.artemis.api.core.client.ActiveMQClient; @@ -1790,7 +1791,7 @@ public class BridgeTest extends ActiveMQTestBase { System.out.println("File created at: " + fileInput.getAbsolutePath()); - ClientMessage message = session.createMessage(ClientMessage.BYTES_TYPE, true); + ClientMessage message = session.createMessage(Message.BYTES_TYPE, true); FileInputStream fileInputStream = new FileInputStream(fileInput); BufferedInputStream bufferedInput = new BufferedInputStream(fileInputStream);