activemq-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From jbert...@apache.org
Subject [27/37] activemq-6 git commit: ACTIVEMQ6-51 Example server bootstrapping
Date Wed, 10 Dec 2014 16:11:53 GMT
http://git-wip-us.apache.org/repos/asf/activemq-6/blob/a102983d/examples/jms/jms-bridge/src/main/resources/activemq/server0/activemq-configuration.xml
----------------------------------------------------------------------
diff --git a/examples/jms/jms-bridge/src/main/resources/activemq/server0/activemq-configuration.xml b/examples/jms/jms-bridge/src/main/resources/activemq/server0/activemq-configuration.xml
new file mode 100644
index 0000000..b1a240c
--- /dev/null
+++ b/examples/jms/jms-bridge/src/main/resources/activemq/server0/activemq-configuration.xml
@@ -0,0 +1,28 @@
+ <configuration xmlns="urn:activemq"
+               xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+               xsi:schemaLocation="urn:activemq /schema/activemq-configuration.xsd">
+
+   <bindings-directory>${build.directory}/server0/data/messaging/bindings</bindings-directory>
+
+   <journal-directory>${build.directory}/server0/data/messaging/journal</journal-directory>
+
+   <large-messages-directory>${build.directory}/server0/data/messaging/largemessages</large-messages-directory>
+
+   <paging-directory>${build.directory}/server0/data/messaging/paging</paging-directory>
+
+   <acceptors>
+      <acceptor name="netty">
+         <factory-class>org.apache.activemq.core.remoting.impl.netty.NettyAcceptorFactory</factory-class>
+      </acceptor>
+   </acceptors>
+
+   <security-settings>
+         <security-setting match="jms.#">
+            <permission type="consume" roles="guest"/>
+            <permission type="send" roles="guest"/>
+            <permission type="createNonDurableQueue" roles="guest"/>
+            <permission type="deleteNonDurableQueue" roles="guest"/>
+         </security-setting>
+    </security-settings>
+</configuration>
+ 
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/activemq-6/blob/a102983d/examples/jms/jms-bridge/src/main/resources/activemq/server0/activemq-jms.xml
----------------------------------------------------------------------
diff --git a/examples/jms/jms-bridge/src/main/resources/activemq/server0/activemq-jms.xml b/examples/jms/jms-bridge/src/main/resources/activemq/server0/activemq-jms.xml
new file mode 100644
index 0000000..e2bb478
--- /dev/null
+++ b/examples/jms/jms-bridge/src/main/resources/activemq/server0/activemq-jms.xml
@@ -0,0 +1,7 @@
+<configuration xmlns="urn:activemq"
+            xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+            xsi:schemaLocation="urn:activemq /schema/activemq-jms.xsd">
+
+   <topic name="topic"/>
+
+</configuration>
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/activemq-6/blob/a102983d/examples/jms/jms-bridge/src/main/resources/activemq/server0/activemq-users.xml
----------------------------------------------------------------------
diff --git a/examples/jms/jms-bridge/src/main/resources/activemq/server0/activemq-users.xml b/examples/jms/jms-bridge/src/main/resources/activemq/server0/activemq-users.xml
new file mode 100644
index 0000000..ae30546
--- /dev/null
+++ b/examples/jms/jms-bridge/src/main/resources/activemq/server0/activemq-users.xml
@@ -0,0 +1,7 @@
+<configuration xmlns="urn:activemq" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+            xsi:schemaLocation="urn:activemq /schema/activemq-users.xsd">
+   <!-- the default user.  this is used where username is null-->
+   <defaultuser name="guest" password="guest">
+      <role name="guest"/>
+   </defaultuser>
+</configuration>
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/activemq-6/blob/a102983d/examples/jms/jms-bridge/src/main/resources/activemq/server1/activemq-configuration.xml
----------------------------------------------------------------------
diff --git a/examples/jms/jms-bridge/src/main/resources/activemq/server1/activemq-configuration.xml b/examples/jms/jms-bridge/src/main/resources/activemq/server1/activemq-configuration.xml
new file mode 100644
index 0000000..6240fb1
--- /dev/null
+++ b/examples/jms/jms-bridge/src/main/resources/activemq/server1/activemq-configuration.xml
@@ -0,0 +1,31 @@
+ <configuration xmlns="urn:activemq"
+               xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+               xsi:schemaLocation="urn:activemq /schema/activemq-configuration.xsd">
+
+   <bindings-directory>${build.directory}/server1/data/messaging/bindings</bindings-directory>
+
+   <journal-directory>${build.directory}/server1/data/messaging/journal</journal-directory>
+
+   <large-messages-directory>${build.directory}/server1/data/messaging/largemessages</large-messages-directory>
+
+   <paging-directory>${build.directory}/server1/data/messaging/paging</paging-directory>
+
+   <acceptors>
+      <acceptor name="netty">
+         <factory-class>org.apache.activemq.core.remoting.impl.netty.NettyAcceptorFactory</factory-class>
+         <!-- the server accepts connections on all the server addresses -->
+         <param key="host" value="localhost"/>
+         <param key="port" value="5455"/>
+      </acceptor>
+   </acceptors>
+
+   <security-settings>
+         <security-setting match="jms.#">
+            <permission type="consume" roles="guest"/>
+            <permission type="send" roles="guest"/>
+            <permission type="createNonDurableQueue" roles="guest"/>
+            <permission type="deleteNonDurableQueue" roles="guest"/>
+         </security-setting>
+    </security-settings>
+</configuration>
+ 
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/activemq-6/blob/a102983d/examples/jms/jms-bridge/src/main/resources/activemq/server1/activemq-jms.xml
----------------------------------------------------------------------
diff --git a/examples/jms/jms-bridge/src/main/resources/activemq/server1/activemq-jms.xml b/examples/jms/jms-bridge/src/main/resources/activemq/server1/activemq-jms.xml
new file mode 100644
index 0000000..0f89939
--- /dev/null
+++ b/examples/jms/jms-bridge/src/main/resources/activemq/server1/activemq-jms.xml
@@ -0,0 +1,7 @@
+<configuration xmlns="urn:activemq"
+            xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+            xsi:schemaLocation="urn:activemq /schema/activemq-jms.xsd">
+
+   <queue name="target"/>
+
+</configuration>
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/activemq-6/blob/a102983d/examples/jms/jms-bridge/src/main/resources/activemq/server1/activemq-users.xml
----------------------------------------------------------------------
diff --git a/examples/jms/jms-bridge/src/main/resources/activemq/server1/activemq-users.xml b/examples/jms/jms-bridge/src/main/resources/activemq/server1/activemq-users.xml
new file mode 100644
index 0000000..ae30546
--- /dev/null
+++ b/examples/jms/jms-bridge/src/main/resources/activemq/server1/activemq-users.xml
@@ -0,0 +1,7 @@
+<configuration xmlns="urn:activemq" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+            xsi:schemaLocation="urn:activemq /schema/activemq-users.xsd">
+   <!-- the default user.  this is used where username is null-->
+   <defaultuser name="guest" password="guest">
+      <role name="guest"/>
+   </defaultuser>
+</configuration>
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/activemq-6/blob/a102983d/examples/jms/jms-bridge/src/main/resources/hornetq/server0/activemq-configuration.xml
----------------------------------------------------------------------
diff --git a/examples/jms/jms-bridge/src/main/resources/hornetq/server0/activemq-configuration.xml b/examples/jms/jms-bridge/src/main/resources/hornetq/server0/activemq-configuration.xml
deleted file mode 100644
index 44d57f7..0000000
--- a/examples/jms/jms-bridge/src/main/resources/hornetq/server0/activemq-configuration.xml
+++ /dev/null
@@ -1,35 +0,0 @@
- <configuration xmlns="urn:activemq"
-               xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
-               xsi:schemaLocation="urn:activemq /schema/activemq-configuration.xsd">
-
-   <bindings-directory>${build.directory}/server0/data/messaging/bindings</bindings-directory>
-
-   <journal-directory>${build.directory}/server0/data/messaging/journal</journal-directory>
-
-   <large-messages-directory>${build.directory}/server0/data/messaging/largemessages</large-messages-directory>
-
-   <paging-directory>${build.directory}/server0/data/messaging/paging</paging-directory>
-
-   <connectors>
-      <connector name="netty">
-         <factory-class>org.apache.activemq.core.remoting.impl.netty.NettyConnectorFactory</factory-class>
-         <param key="host" value="localhost"/>
-      </connector>
-   </connectors>
-
-   <acceptors>
-      <acceptor name="netty">
-         <factory-class>org.apache.activemq.core.remoting.impl.netty.NettyAcceptorFactory</factory-class>
-      </acceptor>
-   </acceptors>
-
-   <security-settings>
-         <security-setting match="jms.#">
-            <permission type="consume" roles="guest"/>
-            <permission type="send" roles="guest"/>
-            <permission type="createNonDurableQueue" roles="guest"/>
-            <permission type="deleteNonDurableQueue" roles="guest"/>
-         </security-setting>
-    </security-settings>
-</configuration>
- 
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/activemq-6/blob/a102983d/examples/jms/jms-bridge/src/main/resources/hornetq/server0/activemq-jms.xml
----------------------------------------------------------------------
diff --git a/examples/jms/jms-bridge/src/main/resources/hornetq/server0/activemq-jms.xml b/examples/jms/jms-bridge/src/main/resources/hornetq/server0/activemq-jms.xml
deleted file mode 100644
index e2bb478..0000000
--- a/examples/jms/jms-bridge/src/main/resources/hornetq/server0/activemq-jms.xml
+++ /dev/null
@@ -1,7 +0,0 @@
-<configuration xmlns="urn:activemq"
-            xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
-            xsi:schemaLocation="urn:activemq /schema/activemq-jms.xsd">
-
-   <topic name="topic"/>
-
-</configuration>
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/activemq-6/blob/a102983d/examples/jms/jms-bridge/src/main/resources/hornetq/server0/hornetq-users.xml
----------------------------------------------------------------------
diff --git a/examples/jms/jms-bridge/src/main/resources/hornetq/server0/hornetq-users.xml b/examples/jms/jms-bridge/src/main/resources/hornetq/server0/hornetq-users.xml
deleted file mode 100644
index ae30546..0000000
--- a/examples/jms/jms-bridge/src/main/resources/hornetq/server0/hornetq-users.xml
+++ /dev/null
@@ -1,7 +0,0 @@
-<configuration xmlns="urn:activemq" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
-            xsi:schemaLocation="urn:activemq /schema/activemq-users.xsd">
-   <!-- the default user.  this is used where username is null-->
-   <defaultuser name="guest" password="guest">
-      <role name="guest"/>
-   </defaultuser>
-</configuration>
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/activemq-6/blob/a102983d/examples/jms/jms-bridge/src/main/resources/hornetq/server1/activemq-configuration.xml
----------------------------------------------------------------------
diff --git a/examples/jms/jms-bridge/src/main/resources/hornetq/server1/activemq-configuration.xml b/examples/jms/jms-bridge/src/main/resources/hornetq/server1/activemq-configuration.xml
deleted file mode 100644
index 47e2d2f..0000000
--- a/examples/jms/jms-bridge/src/main/resources/hornetq/server1/activemq-configuration.xml
+++ /dev/null
@@ -1,42 +0,0 @@
- <configuration xmlns="urn:activemq"
-               xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
-               xsi:schemaLocation="urn:activemq /schema/activemq-configuration.xsd">
-
-   <bindings-directory>${build.directory}/server1/data/messaging/bindings</bindings-directory>
-
-   <journal-directory>${build.directory}/server1/data/messaging/journal</journal-directory>
-
-   <large-messages-directory>${build.directory}/server1/data/messaging/largemessages</large-messages-directory>
-
-   <paging-directory>${build.directory}/server1/data/messaging/paging</paging-directory>
-
-   <connectors>
-      <connector name="netty">
-         <factory-class>org.apache.activemq.core.remoting.impl.netty.NettyConnectorFactory</factory-class>
-         <!-- **************************************** -->
-         <!-- Replace with the *target* server address -->
-         <!-- **************************************** -->
-         <param key="host" value="localhost"/>
-         <param key="port" value="5455"/>
-      </connector>
-   </connectors>
-
-   <acceptors>
-      <acceptor name="netty">
-         <factory-class>org.apache.activemq.core.remoting.impl.netty.NettyAcceptorFactory</factory-class>
-         <!-- the server accepts connections on all the server addresses -->
-         <param key="host" value="localhost"/>
-         <param key="port" value="5455"/>
-      </acceptor>
-   </acceptors>
-
-   <security-settings>
-         <security-setting match="jms.#">
-            <permission type="consume" roles="guest"/>
-            <permission type="send" roles="guest"/>
-            <permission type="createNonDurableQueue" roles="guest"/>
-            <permission type="deleteNonDurableQueue" roles="guest"/>
-         </security-setting>
-    </security-settings>
-</configuration>
- 
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/activemq-6/blob/a102983d/examples/jms/jms-bridge/src/main/resources/hornetq/server1/activemq-jms.xml
----------------------------------------------------------------------
diff --git a/examples/jms/jms-bridge/src/main/resources/hornetq/server1/activemq-jms.xml b/examples/jms/jms-bridge/src/main/resources/hornetq/server1/activemq-jms.xml
deleted file mode 100644
index 0f89939..0000000
--- a/examples/jms/jms-bridge/src/main/resources/hornetq/server1/activemq-jms.xml
+++ /dev/null
@@ -1,7 +0,0 @@
-<configuration xmlns="urn:activemq"
-            xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
-            xsi:schemaLocation="urn:activemq /schema/activemq-jms.xsd">
-
-   <queue name="target"/>
-
-</configuration>
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/activemq-6/blob/a102983d/examples/jms/jms-bridge/src/main/resources/hornetq/server1/activemq-users.xml
----------------------------------------------------------------------
diff --git a/examples/jms/jms-bridge/src/main/resources/hornetq/server1/activemq-users.xml b/examples/jms/jms-bridge/src/main/resources/hornetq/server1/activemq-users.xml
deleted file mode 100644
index ae30546..0000000
--- a/examples/jms/jms-bridge/src/main/resources/hornetq/server1/activemq-users.xml
+++ /dev/null
@@ -1,7 +0,0 @@
-<configuration xmlns="urn:activemq" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
-            xsi:schemaLocation="urn:activemq /schema/activemq-users.xsd">
-   <!-- the default user.  this is used where username is null-->
-   <defaultuser name="guest" password="guest">
-      <role name="guest"/>
-   </defaultuser>
-</configuration>
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/activemq-6/blob/a102983d/examples/jms/jms-completion-listener/pom.xml
----------------------------------------------------------------------
diff --git a/examples/jms/jms-completion-listener/pom.xml b/examples/jms/jms-completion-listener/pom.xml
index c7909ab..beb47d2 100644
--- a/examples/jms/jms-completion-listener/pom.xml
+++ b/examples/jms/jms-completion-listener/pom.xml
@@ -51,9 +51,6 @@
                   </goals>
                   <configuration>
                      <clientClass>org.apache.activemq.jms.example.JMSCompletionListenerExample</clientClass>
-                     <args>
-                        <param>tcp://localhost:5445</param>
-                     </args>
                   </configuration>
                </execution>
                <execution>
@@ -102,7 +99,7 @@
             </dependencies>
             <configuration>
                <waitOnStart>false</waitOnStart>
-               <hornetqConfigurationDir>${basedir}/target/classes/activemq/server0</hornetqConfigurationDir>
+               <configurationDir>${basedir}/target/classes/activemq/server0</configurationDir>
             </configuration>
          </plugin>
       </plugins>

http://git-wip-us.apache.org/repos/asf/activemq-6/blob/a102983d/examples/jms/jms-completion-listener/src/main/java/org/apache/activemq/jms/example/JMSCompletionListenerExample.java
----------------------------------------------------------------------
diff --git a/examples/jms/jms-completion-listener/src/main/java/org/apache/activemq/jms/example/JMSCompletionListenerExample.java b/examples/jms/jms-completion-listener/src/main/java/org/apache/activemq/jms/example/JMSCompletionListenerExample.java
index fdb66fe..af5b13d 100644
--- a/examples/jms/jms-completion-listener/src/main/java/org/apache/activemq/jms/example/JMSCompletionListenerExample.java
+++ b/examples/jms/jms-completion-listener/src/main/java/org/apache/activemq/jms/example/JMSCompletionListenerExample.java
@@ -49,7 +49,7 @@ public class JMSCompletionListenerExample extends ActiveMQExample
       try
       {
          // Step 1. Create an initial context to perform the JNDI lookup.
-         initialContext = getContext(0);
+         initialContext = new InitialContext();
 
          // Step 2. Perfom a lookup on the queue
          Queue queue = (Queue)initialContext.lookup("queue/exampleQueue");

http://git-wip-us.apache.org/repos/asf/activemq-6/blob/a102983d/examples/jms/jms-completion-listener/src/main/resources/activemq/server0/activemq-configuration.xml
----------------------------------------------------------------------
diff --git a/examples/jms/jms-completion-listener/src/main/resources/activemq/server0/activemq-configuration.xml b/examples/jms/jms-completion-listener/src/main/resources/activemq/server0/activemq-configuration.xml
new file mode 100644
index 0000000..52d9570
--- /dev/null
+++ b/examples/jms/jms-completion-listener/src/main/resources/activemq/server0/activemq-configuration.xml
@@ -0,0 +1,34 @@
+<configuration xmlns="urn:activemq"
+            xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+            xsi:schemaLocation="urn:activemq /schema/activemq-configuration.xsd">
+
+   <bindings-directory>${build.directory}/server0/data/messaging/bindings</bindings-directory>
+
+   <journal-directory>${build.directory}/server0/data/messaging/journal</journal-directory>
+
+   <large-messages-directory>${build.directory}/server0/data/messaging/largemessages</large-messages-directory>
+
+   <paging-directory>${build.directory}/server0/data/messaging/paging</paging-directory>
+   
+   <!-- Acceptors -->
+   <acceptors>
+      <acceptor name="netty-acceptor">
+         <factory-class>org.apache.activemq.core.remoting.impl.netty.NettyAcceptorFactory</factory-class>
+      </acceptor>
+   </acceptors>
+
+   <!-- Other config -->
+
+   <security-settings>
+      <!--security for example queue-->
+      <security-setting match="jms.queue.exampleQueue">
+         <permission type="createDurableQueue" roles="guest"/>
+         <permission type="deleteDurableQueue" roles="guest"/>
+         <permission type="createNonDurableQueue" roles="guest"/>
+         <permission type="deleteNonDurableQueue" roles="guest"/>
+         <permission type="consume" roles="guest"/>
+         <permission type="send" roles="guest"/>
+      </security-setting>
+   </security-settings>
+
+</configuration>

http://git-wip-us.apache.org/repos/asf/activemq-6/blob/a102983d/examples/jms/jms-completion-listener/src/main/resources/activemq/server0/activemq-jms.xml
----------------------------------------------------------------------
diff --git a/examples/jms/jms-completion-listener/src/main/resources/activemq/server0/activemq-jms.xml b/examples/jms/jms-completion-listener/src/main/resources/activemq/server0/activemq-jms.xml
new file mode 100644
index 0000000..0d5c953
--- /dev/null
+++ b/examples/jms/jms-completion-listener/src/main/resources/activemq/server0/activemq-jms.xml
@@ -0,0 +1,8 @@
+<configuration xmlns="urn:activemq"
+            xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+            xsi:schemaLocation="urn:activemq /schema/activemq-jms.xsd">
+
+   <!--the queue used by the example-->
+   <queue name="exampleQueue"/>
+
+</configuration>

http://git-wip-us.apache.org/repos/asf/activemq-6/blob/a102983d/examples/jms/jms-completion-listener/src/main/resources/activemq/server0/activemq-users.xml
----------------------------------------------------------------------
diff --git a/examples/jms/jms-completion-listener/src/main/resources/activemq/server0/activemq-users.xml b/examples/jms/jms-completion-listener/src/main/resources/activemq/server0/activemq-users.xml
new file mode 100644
index 0000000..ae30546
--- /dev/null
+++ b/examples/jms/jms-completion-listener/src/main/resources/activemq/server0/activemq-users.xml
@@ -0,0 +1,7 @@
+<configuration xmlns="urn:activemq" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+            xsi:schemaLocation="urn:activemq /schema/activemq-users.xsd">
+   <!-- the default user.  this is used where username is null-->
+   <defaultuser name="guest" password="guest">
+      <role name="guest"/>
+   </defaultuser>
+</configuration>
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/activemq-6/blob/a102983d/examples/jms/jms-completion-listener/src/main/resources/hornetq/server0/activemq-configuration.xml
----------------------------------------------------------------------
diff --git a/examples/jms/jms-completion-listener/src/main/resources/hornetq/server0/activemq-configuration.xml b/examples/jms/jms-completion-listener/src/main/resources/hornetq/server0/activemq-configuration.xml
deleted file mode 100644
index e0acd1d..0000000
--- a/examples/jms/jms-completion-listener/src/main/resources/hornetq/server0/activemq-configuration.xml
+++ /dev/null
@@ -1,43 +0,0 @@
-<configuration xmlns="urn:activemq"
-            xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
-            xsi:schemaLocation="urn:activemq /schema/activemq-configuration.xsd">
-
-   <bindings-directory>${build.directory}/server0/data/messaging/bindings</bindings-directory>
-
-   <journal-directory>${build.directory}/server0/data/messaging/journal</journal-directory>
-
-   <large-messages-directory>${build.directory}/server0/data/messaging/largemessages</large-messages-directory>
-
-   <paging-directory>${build.directory}/server0/data/messaging/paging</paging-directory>
-
-
-   <!-- Connectors -->
-
-   <connectors>
-      <connector name="netty-connector">
-         <factory-class>org.apache.activemq.core.remoting.impl.netty.NettyConnectorFactory</factory-class>
-      </connector>
-   </connectors>
-   
-   <!-- Acceptors -->
-   <acceptors>
-      <acceptor name="netty-acceptor">
-         <factory-class>org.apache.activemq.core.remoting.impl.netty.NettyAcceptorFactory</factory-class>
-      </acceptor>
-   </acceptors>
-
-   <!-- Other config -->
-
-   <security-settings>
-      <!--security for example queue-->
-      <security-setting match="jms.queue.exampleQueue">
-         <permission type="createDurableQueue" roles="guest"/>
-         <permission type="deleteDurableQueue" roles="guest"/>
-         <permission type="createNonDurableQueue" roles="guest"/>
-         <permission type="deleteNonDurableQueue" roles="guest"/>
-         <permission type="consume" roles="guest"/>
-         <permission type="send" roles="guest"/>
-      </security-setting>
-   </security-settings>
-
-</configuration>

http://git-wip-us.apache.org/repos/asf/activemq-6/blob/a102983d/examples/jms/jms-completion-listener/src/main/resources/hornetq/server0/activemq-jms.xml
----------------------------------------------------------------------
diff --git a/examples/jms/jms-completion-listener/src/main/resources/hornetq/server0/activemq-jms.xml b/examples/jms/jms-completion-listener/src/main/resources/hornetq/server0/activemq-jms.xml
deleted file mode 100644
index 0d5c953..0000000
--- a/examples/jms/jms-completion-listener/src/main/resources/hornetq/server0/activemq-jms.xml
+++ /dev/null
@@ -1,8 +0,0 @@
-<configuration xmlns="urn:activemq"
-            xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
-            xsi:schemaLocation="urn:activemq /schema/activemq-jms.xsd">
-
-   <!--the queue used by the example-->
-   <queue name="exampleQueue"/>
-
-</configuration>

http://git-wip-us.apache.org/repos/asf/activemq-6/blob/a102983d/examples/jms/jms-completion-listener/src/main/resources/hornetq/server0/activemq-users.xml
----------------------------------------------------------------------
diff --git a/examples/jms/jms-completion-listener/src/main/resources/hornetq/server0/activemq-users.xml b/examples/jms/jms-completion-listener/src/main/resources/hornetq/server0/activemq-users.xml
deleted file mode 100644
index ae30546..0000000
--- a/examples/jms/jms-completion-listener/src/main/resources/hornetq/server0/activemq-users.xml
+++ /dev/null
@@ -1,7 +0,0 @@
-<configuration xmlns="urn:activemq" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
-            xsi:schemaLocation="urn:activemq /schema/activemq-users.xsd">
-   <!-- the default user.  this is used where username is null-->
-   <defaultuser name="guest" password="guest">
-      <role name="guest"/>
-   </defaultuser>
-</configuration>
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/activemq-6/blob/a102983d/examples/jms/jms-completion-listener/src/main/resources/jndi.properties
----------------------------------------------------------------------
diff --git a/examples/jms/jms-completion-listener/src/main/resources/jndi.properties b/examples/jms/jms-completion-listener/src/main/resources/jndi.properties
new file mode 100644
index 0000000..d9b5c6a
--- /dev/null
+++ b/examples/jms/jms-completion-listener/src/main/resources/jndi.properties
@@ -0,0 +1,3 @@
+java.naming.factory.initial=org.apache.activemq.jndi.ActiveMQInitialContextFactory
+java.naming.provider.url=tcp://localhost:5445
+queue.queue/exampleQueue=exampleQueue
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/activemq-6/blob/a102983d/examples/jms/jms-context/pom.xml
----------------------------------------------------------------------
diff --git a/examples/jms/jms-context/pom.xml b/examples/jms/jms-context/pom.xml
index 8371058..1283603 100644
--- a/examples/jms/jms-context/pom.xml
+++ b/examples/jms/jms-context/pom.xml
@@ -51,9 +51,6 @@
                   </goals>
                   <configuration>
                      <clientClass>org.apache.activemq.jms.example.JMSContextExample</clientClass>
-                     <args>
-                        <param>tcp://localhost:5445</param>
-                     </args>
                   </configuration>
                </execution>
                <execution>
@@ -102,7 +99,7 @@
             </dependencies>
             <configuration>
                <waitOnStart>false</waitOnStart>
-               <hornetqConfigurationDir>${basedir}/target/classes/activemq/server0</hornetqConfigurationDir>
+               <configurationDir>${basedir}/target/classes/activemq/server0</configurationDir>
             </configuration>
          </plugin>
       </plugins>

http://git-wip-us.apache.org/repos/asf/activemq-6/blob/a102983d/examples/jms/jms-context/src/main/java/org/apache/activemq/jms/example/JMSContextExample.java
----------------------------------------------------------------------
diff --git a/examples/jms/jms-context/src/main/java/org/apache/activemq/jms/example/JMSContextExample.java b/examples/jms/jms-context/src/main/java/org/apache/activemq/jms/example/JMSContextExample.java
index 9a78e7c..616574b 100644
--- a/examples/jms/jms-context/src/main/java/org/apache/activemq/jms/example/JMSContextExample.java
+++ b/examples/jms/jms-context/src/main/java/org/apache/activemq/jms/example/JMSContextExample.java
@@ -44,7 +44,7 @@ public class JMSContextExample extends ActiveMQExample
       try
       {
          // Step 1. Create an initial context to perform the JNDI lookup.
-         initialContext = getContext(0);
+         initialContext = new InitialContext();
 
          // Step 2. Perfom a lookup on the queue
          Queue queue = (Queue)initialContext.lookup("queue/exampleQueue");

http://git-wip-us.apache.org/repos/asf/activemq-6/blob/a102983d/examples/jms/jms-context/src/main/resources/activemq/server0/activemq-configuration.xml
----------------------------------------------------------------------
diff --git a/examples/jms/jms-context/src/main/resources/activemq/server0/activemq-configuration.xml b/examples/jms/jms-context/src/main/resources/activemq/server0/activemq-configuration.xml
new file mode 100644
index 0000000..52d9570
--- /dev/null
+++ b/examples/jms/jms-context/src/main/resources/activemq/server0/activemq-configuration.xml
@@ -0,0 +1,34 @@
+<configuration xmlns="urn:activemq"
+            xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+            xsi:schemaLocation="urn:activemq /schema/activemq-configuration.xsd">
+
+   <bindings-directory>${build.directory}/server0/data/messaging/bindings</bindings-directory>
+
+   <journal-directory>${build.directory}/server0/data/messaging/journal</journal-directory>
+
+   <large-messages-directory>${build.directory}/server0/data/messaging/largemessages</large-messages-directory>
+
+   <paging-directory>${build.directory}/server0/data/messaging/paging</paging-directory>
+   
+   <!-- Acceptors -->
+   <acceptors>
+      <acceptor name="netty-acceptor">
+         <factory-class>org.apache.activemq.core.remoting.impl.netty.NettyAcceptorFactory</factory-class>
+      </acceptor>
+   </acceptors>
+
+   <!-- Other config -->
+
+   <security-settings>
+      <!--security for example queue-->
+      <security-setting match="jms.queue.exampleQueue">
+         <permission type="createDurableQueue" roles="guest"/>
+         <permission type="deleteDurableQueue" roles="guest"/>
+         <permission type="createNonDurableQueue" roles="guest"/>
+         <permission type="deleteNonDurableQueue" roles="guest"/>
+         <permission type="consume" roles="guest"/>
+         <permission type="send" roles="guest"/>
+      </security-setting>
+   </security-settings>
+
+</configuration>

http://git-wip-us.apache.org/repos/asf/activemq-6/blob/a102983d/examples/jms/jms-context/src/main/resources/activemq/server0/activemq-jms.xml
----------------------------------------------------------------------
diff --git a/examples/jms/jms-context/src/main/resources/activemq/server0/activemq-jms.xml b/examples/jms/jms-context/src/main/resources/activemq/server0/activemq-jms.xml
new file mode 100644
index 0000000..0d5c953
--- /dev/null
+++ b/examples/jms/jms-context/src/main/resources/activemq/server0/activemq-jms.xml
@@ -0,0 +1,8 @@
+<configuration xmlns="urn:activemq"
+            xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+            xsi:schemaLocation="urn:activemq /schema/activemq-jms.xsd">
+
+   <!--the queue used by the example-->
+   <queue name="exampleQueue"/>
+
+</configuration>

http://git-wip-us.apache.org/repos/asf/activemq-6/blob/a102983d/examples/jms/jms-context/src/main/resources/activemq/server0/activemq-users.xml
----------------------------------------------------------------------
diff --git a/examples/jms/jms-context/src/main/resources/activemq/server0/activemq-users.xml b/examples/jms/jms-context/src/main/resources/activemq/server0/activemq-users.xml
new file mode 100644
index 0000000..ae30546
--- /dev/null
+++ b/examples/jms/jms-context/src/main/resources/activemq/server0/activemq-users.xml
@@ -0,0 +1,7 @@
+<configuration xmlns="urn:activemq" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+            xsi:schemaLocation="urn:activemq /schema/activemq-users.xsd">
+   <!-- the default user.  this is used where username is null-->
+   <defaultuser name="guest" password="guest">
+      <role name="guest"/>
+   </defaultuser>
+</configuration>
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/activemq-6/blob/a102983d/examples/jms/jms-context/src/main/resources/hornetq/server0/activemq-configuration.xml
----------------------------------------------------------------------
diff --git a/examples/jms/jms-context/src/main/resources/hornetq/server0/activemq-configuration.xml b/examples/jms/jms-context/src/main/resources/hornetq/server0/activemq-configuration.xml
deleted file mode 100644
index e0acd1d..0000000
--- a/examples/jms/jms-context/src/main/resources/hornetq/server0/activemq-configuration.xml
+++ /dev/null
@@ -1,43 +0,0 @@
-<configuration xmlns="urn:activemq"
-            xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
-            xsi:schemaLocation="urn:activemq /schema/activemq-configuration.xsd">
-
-   <bindings-directory>${build.directory}/server0/data/messaging/bindings</bindings-directory>
-
-   <journal-directory>${build.directory}/server0/data/messaging/journal</journal-directory>
-
-   <large-messages-directory>${build.directory}/server0/data/messaging/largemessages</large-messages-directory>
-
-   <paging-directory>${build.directory}/server0/data/messaging/paging</paging-directory>
-
-
-   <!-- Connectors -->
-
-   <connectors>
-      <connector name="netty-connector">
-         <factory-class>org.apache.activemq.core.remoting.impl.netty.NettyConnectorFactory</factory-class>
-      </connector>
-   </connectors>
-   
-   <!-- Acceptors -->
-   <acceptors>
-      <acceptor name="netty-acceptor">
-         <factory-class>org.apache.activemq.core.remoting.impl.netty.NettyAcceptorFactory</factory-class>
-      </acceptor>
-   </acceptors>
-
-   <!-- Other config -->
-
-   <security-settings>
-      <!--security for example queue-->
-      <security-setting match="jms.queue.exampleQueue">
-         <permission type="createDurableQueue" roles="guest"/>
-         <permission type="deleteDurableQueue" roles="guest"/>
-         <permission type="createNonDurableQueue" roles="guest"/>
-         <permission type="deleteNonDurableQueue" roles="guest"/>
-         <permission type="consume" roles="guest"/>
-         <permission type="send" roles="guest"/>
-      </security-setting>
-   </security-settings>
-
-</configuration>

http://git-wip-us.apache.org/repos/asf/activemq-6/blob/a102983d/examples/jms/jms-context/src/main/resources/hornetq/server0/activemq-users.xml
----------------------------------------------------------------------
diff --git a/examples/jms/jms-context/src/main/resources/hornetq/server0/activemq-users.xml b/examples/jms/jms-context/src/main/resources/hornetq/server0/activemq-users.xml
deleted file mode 100644
index ae30546..0000000
--- a/examples/jms/jms-context/src/main/resources/hornetq/server0/activemq-users.xml
+++ /dev/null
@@ -1,7 +0,0 @@
-<configuration xmlns="urn:activemq" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
-            xsi:schemaLocation="urn:activemq /schema/activemq-users.xsd">
-   <!-- the default user.  this is used where username is null-->
-   <defaultuser name="guest" password="guest">
-      <role name="guest"/>
-   </defaultuser>
-</configuration>
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/activemq-6/blob/a102983d/examples/jms/jms-context/src/main/resources/jndi.properties
----------------------------------------------------------------------
diff --git a/examples/jms/jms-context/src/main/resources/jndi.properties b/examples/jms/jms-context/src/main/resources/jndi.properties
new file mode 100644
index 0000000..d9b5c6a
--- /dev/null
+++ b/examples/jms/jms-context/src/main/resources/jndi.properties
@@ -0,0 +1,3 @@
+java.naming.factory.initial=org.apache.activemq.jndi.ActiveMQInitialContextFactory
+java.naming.provider.url=tcp://localhost:5445
+queue.queue/exampleQueue=exampleQueue
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/activemq-6/blob/a102983d/examples/jms/jms-shared-consumer/pom.xml
----------------------------------------------------------------------
diff --git a/examples/jms/jms-shared-consumer/pom.xml b/examples/jms/jms-shared-consumer/pom.xml
index c59597a..9e9bcee 100644
--- a/examples/jms/jms-shared-consumer/pom.xml
+++ b/examples/jms/jms-shared-consumer/pom.xml
@@ -102,7 +102,7 @@
             </dependencies>
             <configuration>
                <waitOnStart>false</waitOnStart>
-               <hornetqConfigurationDir>${basedir}/target/classes/activemq/server0</hornetqConfigurationDir>
+               <configurationDir>${basedir}/target/classes/activemq/server0</configurationDir>
             </configuration>
          </plugin>
       </plugins>

http://git-wip-us.apache.org/repos/asf/activemq-6/blob/a102983d/examples/jms/jms-shared-consumer/src/main/java/org/apache/activemq/jms/example/JMSSharedConsumerExample.java
----------------------------------------------------------------------
diff --git a/examples/jms/jms-shared-consumer/src/main/java/org/apache/activemq/jms/example/JMSSharedConsumerExample.java b/examples/jms/jms-shared-consumer/src/main/java/org/apache/activemq/jms/example/JMSSharedConsumerExample.java
index 70c8ec5..23d72ca 100644
--- a/examples/jms/jms-shared-consumer/src/main/java/org/apache/activemq/jms/example/JMSSharedConsumerExample.java
+++ b/examples/jms/jms-shared-consumer/src/main/java/org/apache/activemq/jms/example/JMSSharedConsumerExample.java
@@ -52,7 +52,7 @@ public class JMSSharedConsumerExample extends ActiveMQExample
       try
       {
          // Step 1. Create an initial context to perform the JNDI lookup.
-         initialContext = getContext(0);
+         initialContext = new InitialContext();
 
          // Step 2. Perfom a lookup on the queue
          Topic topic = (Topic) initialContext.lookup("topic/exampleTopic");

http://git-wip-us.apache.org/repos/asf/activemq-6/blob/a102983d/examples/jms/jms-shared-consumer/src/main/resources/activemq/server0/activemq-configuration.xml
----------------------------------------------------------------------
diff --git a/examples/jms/jms-shared-consumer/src/main/resources/activemq/server0/activemq-configuration.xml b/examples/jms/jms-shared-consumer/src/main/resources/activemq/server0/activemq-configuration.xml
new file mode 100644
index 0000000..b3db2a6
--- /dev/null
+++ b/examples/jms/jms-shared-consumer/src/main/resources/activemq/server0/activemq-configuration.xml
@@ -0,0 +1,34 @@
+<configuration xmlns="urn:activemq"
+            xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+            xsi:schemaLocation="urn:activemq /schema/activemq-configuration.xsd">
+
+   <bindings-directory>${build.directory}/server0/data/messaging/bindings</bindings-directory>
+
+   <journal-directory>${build.directory}/server0/data/messaging/journal</journal-directory>
+
+   <large-messages-directory>${build.directory}/server0/data/messaging/largemessages</large-messages-directory>
+
+   <paging-directory>${build.directory}/server0/data/messaging/paging</paging-directory>
+   
+   <!-- Acceptors -->
+   <acceptors>
+      <acceptor name="netty-acceptor">
+         <factory-class>org.apache.activemq.core.remoting.impl.netty.NettyAcceptorFactory</factory-class>
+      </acceptor>
+   </acceptors>
+
+   <!-- Other config -->
+
+   <security-settings>
+      <!--security for example queue-->
+      <security-setting match="jms.topic.exampleTopic">
+         <permission type="createDurableQueue" roles="guest"/>
+         <permission type="deleteDurableQueue" roles="guest"/>
+         <permission type="createNonDurableQueue" roles="guest"/>
+         <permission type="deleteNonDurableQueue" roles="guest"/>
+         <permission type="consume" roles="guest"/>
+         <permission type="send" roles="guest"/>
+      </security-setting>
+   </security-settings>
+
+</configuration>

http://git-wip-us.apache.org/repos/asf/activemq-6/blob/a102983d/examples/jms/jms-shared-consumer/src/main/resources/activemq/server0/activemq-jms.xml
----------------------------------------------------------------------
diff --git a/examples/jms/jms-shared-consumer/src/main/resources/activemq/server0/activemq-jms.xml b/examples/jms/jms-shared-consumer/src/main/resources/activemq/server0/activemq-jms.xml
new file mode 100644
index 0000000..a053116
--- /dev/null
+++ b/examples/jms/jms-shared-consumer/src/main/resources/activemq/server0/activemq-jms.xml
@@ -0,0 +1,8 @@
+<configuration xmlns="urn:activemq"
+            xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+            xsi:schemaLocation="urn:activemq /schema/activemq-jms.xsd">
+
+    <!--the topic used by the example-->
+    <topic name="exampleTopic"/>
+
+</configuration>

http://git-wip-us.apache.org/repos/asf/activemq-6/blob/a102983d/examples/jms/jms-shared-consumer/src/main/resources/activemq/server0/activemq-users.xml
----------------------------------------------------------------------
diff --git a/examples/jms/jms-shared-consumer/src/main/resources/activemq/server0/activemq-users.xml b/examples/jms/jms-shared-consumer/src/main/resources/activemq/server0/activemq-users.xml
new file mode 100644
index 0000000..ae30546
--- /dev/null
+++ b/examples/jms/jms-shared-consumer/src/main/resources/activemq/server0/activemq-users.xml
@@ -0,0 +1,7 @@
+<configuration xmlns="urn:activemq" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+            xsi:schemaLocation="urn:activemq /schema/activemq-users.xsd">
+   <!-- the default user.  this is used where username is null-->
+   <defaultuser name="guest" password="guest">
+      <role name="guest"/>
+   </defaultuser>
+</configuration>
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/activemq-6/blob/a102983d/examples/jms/jms-shared-consumer/src/main/resources/hornetq/server0/activemq-configuration.xml
----------------------------------------------------------------------
diff --git a/examples/jms/jms-shared-consumer/src/main/resources/hornetq/server0/activemq-configuration.xml b/examples/jms/jms-shared-consumer/src/main/resources/hornetq/server0/activemq-configuration.xml
deleted file mode 100644
index e83d7a4..0000000
--- a/examples/jms/jms-shared-consumer/src/main/resources/hornetq/server0/activemq-configuration.xml
+++ /dev/null
@@ -1,43 +0,0 @@
-<configuration xmlns="urn:activemq"
-            xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
-            xsi:schemaLocation="urn:activemq /schema/activemq-configuration.xsd">
-
-   <bindings-directory>${build.directory}/server0/data/messaging/bindings</bindings-directory>
-
-   <journal-directory>${build.directory}/server0/data/messaging/journal</journal-directory>
-
-   <large-messages-directory>${build.directory}/server0/data/messaging/largemessages</large-messages-directory>
-
-   <paging-directory>${build.directory}/server0/data/messaging/paging</paging-directory>
-
-
-   <!-- Connectors -->
-
-   <connectors>
-      <connector name="netty-connector">
-         <factory-class>org.apache.activemq.core.remoting.impl.netty.NettyConnectorFactory</factory-class>
-      </connector>
-   </connectors>
-   
-   <!-- Acceptors -->
-   <acceptors>
-      <acceptor name="netty-acceptor">
-         <factory-class>org.apache.activemq.core.remoting.impl.netty.NettyAcceptorFactory</factory-class>
-      </acceptor>
-   </acceptors>
-
-   <!-- Other config -->
-
-   <security-settings>
-      <!--security for example queue-->
-      <security-setting match="jms.topic.exampleTopic">
-         <permission type="createDurableQueue" roles="guest"/>
-         <permission type="deleteDurableQueue" roles="guest"/>
-         <permission type="createNonDurableQueue" roles="guest"/>
-         <permission type="deleteNonDurableQueue" roles="guest"/>
-         <permission type="consume" roles="guest"/>
-         <permission type="send" roles="guest"/>
-      </security-setting>
-   </security-settings>
-
-</configuration>

http://git-wip-us.apache.org/repos/asf/activemq-6/blob/a102983d/examples/jms/jms-shared-consumer/src/main/resources/hornetq/server0/activemq-jms.xml
----------------------------------------------------------------------
diff --git a/examples/jms/jms-shared-consumer/src/main/resources/hornetq/server0/activemq-jms.xml b/examples/jms/jms-shared-consumer/src/main/resources/hornetq/server0/activemq-jms.xml
deleted file mode 100644
index a053116..0000000
--- a/examples/jms/jms-shared-consumer/src/main/resources/hornetq/server0/activemq-jms.xml
+++ /dev/null
@@ -1,8 +0,0 @@
-<configuration xmlns="urn:activemq"
-            xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
-            xsi:schemaLocation="urn:activemq /schema/activemq-jms.xsd">
-
-    <!--the topic used by the example-->
-    <topic name="exampleTopic"/>
-
-</configuration>

http://git-wip-us.apache.org/repos/asf/activemq-6/blob/a102983d/examples/jms/jms-shared-consumer/src/main/resources/hornetq/server0/activemq-users.xml
----------------------------------------------------------------------
diff --git a/examples/jms/jms-shared-consumer/src/main/resources/hornetq/server0/activemq-users.xml b/examples/jms/jms-shared-consumer/src/main/resources/hornetq/server0/activemq-users.xml
deleted file mode 100644
index ae30546..0000000
--- a/examples/jms/jms-shared-consumer/src/main/resources/hornetq/server0/activemq-users.xml
+++ /dev/null
@@ -1,7 +0,0 @@
-<configuration xmlns="urn:activemq" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
-            xsi:schemaLocation="urn:activemq /schema/activemq-users.xsd">
-   <!-- the default user.  this is used where username is null-->
-   <defaultuser name="guest" password="guest">
-      <role name="guest"/>
-   </defaultuser>
-</configuration>
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/activemq-6/blob/a102983d/examples/jms/jms-shared-consumer/src/main/resources/jndi.properties
----------------------------------------------------------------------
diff --git a/examples/jms/jms-shared-consumer/src/main/resources/jndi.properties b/examples/jms/jms-shared-consumer/src/main/resources/jndi.properties
new file mode 100644
index 0000000..4faa790
--- /dev/null
+++ b/examples/jms/jms-shared-consumer/src/main/resources/jndi.properties
@@ -0,0 +1,3 @@
+java.naming.factory.initial=org.apache.activemq.jndi.ActiveMQInitialContextFactory
+java.naming.provider.url=tcp://localhost:5445
+topic.topic/exampleTopic=exampleTopic
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/activemq-6/blob/a102983d/examples/jms/jmx/pom.xml
----------------------------------------------------------------------
diff --git a/examples/jms/jmx/pom.xml b/examples/jms/jmx/pom.xml
index 88d0ae6..2fd219f 100644
--- a/examples/jms/jmx/pom.xml
+++ b/examples/jms/jmx/pom.xml
@@ -79,9 +79,6 @@
                   </goals>
                   <configuration>
                      <clientClass>org.apache.activemq.jms.example.JMXExample</clientClass>
-                     <args>
-                        <param>tcp://localhost:5445</param>
-                     </args>
                   </configuration>
                </execution>
                <execution>
@@ -130,7 +127,7 @@
             </dependencies>
             <configuration>
                <waitOnStart>false</waitOnStart>
-               <hornetqConfigurationDir>${basedir}/target/classes/activemq/server0</hornetqConfigurationDir>
+               <configurationDir>${basedir}/target/classes/activemq/server0</configurationDir>
             </configuration>
          </plugin>
       </plugins>

http://git-wip-us.apache.org/repos/asf/activemq-6/blob/a102983d/examples/jms/jmx/src/main/java/org/apache/activemq/jms/example/JMXExample.java
----------------------------------------------------------------------
diff --git a/examples/jms/jmx/src/main/java/org/apache/activemq/jms/example/JMXExample.java b/examples/jms/jmx/src/main/java/org/apache/activemq/jms/example/JMXExample.java
index af7e21f..6027479 100644
--- a/examples/jms/jmx/src/main/java/org/apache/activemq/jms/example/JMXExample.java
+++ b/examples/jms/jmx/src/main/java/org/apache/activemq/jms/example/JMXExample.java
@@ -60,7 +60,7 @@ public class JMXExample extends ActiveMQExample
       try
       {
          // Step 1. Create an initial context to perform the JNDI lookup.
-         initialContext = getContext(0);
+         initialContext = new InitialContext();
 
          // Step 2. Perfom a lookup on the queue
          Queue queue = (Queue)initialContext.lookup("queue/exampleQueue");

http://git-wip-us.apache.org/repos/asf/activemq-6/blob/a102983d/examples/jms/jmx/src/main/resources/activemq/server0/activemq-configuration.xml
----------------------------------------------------------------------
diff --git a/examples/jms/jmx/src/main/resources/activemq/server0/activemq-configuration.xml b/examples/jms/jmx/src/main/resources/activemq/server0/activemq-configuration.xml
new file mode 100644
index 0000000..b698b1c
--- /dev/null
+++ b/examples/jms/jmx/src/main/resources/activemq/server0/activemq-configuration.xml
@@ -0,0 +1,38 @@
+<configuration xmlns="urn:activemq"
+            xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+            xsi:schemaLocation="urn:activemq /schema/activemq-configuration.xsd">
+
+   <bindings-directory>${build.directory}/server0/data/messaging/bindings</bindings-directory>
+
+   <journal-directory>${build.directory}/server0/data/messaging/journal</journal-directory>
+
+   <large-messages-directory>${build.directory}/server0/data/messaging/largemessages</large-messages-directory>
+
+   <paging-directory>${build.directory}/server0/data/messaging/paging</paging-directory>
+
+
+    <!-- true to expose ActiveMQ resources through JMX -->
+    <jmx-management-enabled>true</jmx-management-enabled>
+   
+   <!-- Acceptors -->
+   <acceptors>
+      <acceptor name="netty">
+         <factory-class>org.apache.activemq.core.remoting.impl.netty.NettyAcceptorFactory</factory-class>
+      </acceptor>
+   </acceptors>
+
+   <!-- Other config -->
+
+   <security-settings>
+      <!--security for example queue-->
+      <security-setting match="jms.queue.exampleQueue">
+         <permission type="createDurableQueue" roles="guest"/>
+         <permission type="deleteDurableQueue" roles="guest"/>
+         <permission type="createNonDurableQueue" roles="guest"/>
+         <permission type="deleteNonDurableQueue" roles="guest"/>
+         <permission type="consume" roles="guest"/>
+         <permission type="send" roles="guest"/>
+      </security-setting>
+   </security-settings>
+
+</configuration>

http://git-wip-us.apache.org/repos/asf/activemq-6/blob/a102983d/examples/jms/jmx/src/main/resources/activemq/server0/activemq-jms.xml
----------------------------------------------------------------------
diff --git a/examples/jms/jmx/src/main/resources/activemq/server0/activemq-jms.xml b/examples/jms/jmx/src/main/resources/activemq/server0/activemq-jms.xml
new file mode 100644
index 0000000..0d5c953
--- /dev/null
+++ b/examples/jms/jmx/src/main/resources/activemq/server0/activemq-jms.xml
@@ -0,0 +1,8 @@
+<configuration xmlns="urn:activemq"
+            xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+            xsi:schemaLocation="urn:activemq /schema/activemq-jms.xsd">
+
+   <!--the queue used by the example-->
+   <queue name="exampleQueue"/>
+
+</configuration>

http://git-wip-us.apache.org/repos/asf/activemq-6/blob/a102983d/examples/jms/jmx/src/main/resources/activemq/server0/activemq-users.xml
----------------------------------------------------------------------
diff --git a/examples/jms/jmx/src/main/resources/activemq/server0/activemq-users.xml b/examples/jms/jmx/src/main/resources/activemq/server0/activemq-users.xml
new file mode 100644
index 0000000..ae30546
--- /dev/null
+++ b/examples/jms/jmx/src/main/resources/activemq/server0/activemq-users.xml
@@ -0,0 +1,7 @@
+<configuration xmlns="urn:activemq" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+            xsi:schemaLocation="urn:activemq /schema/activemq-users.xsd">
+   <!-- the default user.  this is used where username is null-->
+   <defaultuser name="guest" password="guest">
+      <role name="guest"/>
+   </defaultuser>
+</configuration>
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/activemq-6/blob/a102983d/examples/jms/jmx/src/main/resources/hornetq/server0/activemq-configuration.xml
----------------------------------------------------------------------
diff --git a/examples/jms/jmx/src/main/resources/hornetq/server0/activemq-configuration.xml b/examples/jms/jmx/src/main/resources/hornetq/server0/activemq-configuration.xml
deleted file mode 100644
index f21d154..0000000
--- a/examples/jms/jmx/src/main/resources/hornetq/server0/activemq-configuration.xml
+++ /dev/null
@@ -1,45 +0,0 @@
-<configuration xmlns="urn:activemq"
-            xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
-            xsi:schemaLocation="urn:activemq /schema/activemq-configuration.xsd">
-
-   <bindings-directory>${build.directory}/server0/data/messaging/bindings</bindings-directory>
-
-   <journal-directory>${build.directory}/server0/data/messaging/journal</journal-directory>
-
-   <large-messages-directory>${build.directory}/server0/data/messaging/largemessages</large-messages-directory>
-
-   <paging-directory>${build.directory}/server0/data/messaging/paging</paging-directory>
-
-
-    <!-- true to expose ActiveMQ resources through JMX -->
-    <jmx-management-enabled>true</jmx-management-enabled>
-
-   <!-- Connectors -->
-   <connectors>
-      <connector name="netty">
-         <factory-class>org.apache.activemq.core.remoting.impl.netty.NettyConnectorFactory</factory-class>
-      </connector>
-   </connectors>
-   
-   <!-- Acceptors -->
-   <acceptors>
-      <acceptor name="netty">
-         <factory-class>org.apache.activemq.core.remoting.impl.netty.NettyAcceptorFactory</factory-class>
-      </acceptor>
-   </acceptors>
-
-   <!-- Other config -->
-
-   <security-settings>
-      <!--security for example queue-->
-      <security-setting match="jms.queue.exampleQueue">
-         <permission type="createDurableQueue" roles="guest"/>
-         <permission type="deleteDurableQueue" roles="guest"/>
-         <permission type="createNonDurableQueue" roles="guest"/>
-         <permission type="deleteNonDurableQueue" roles="guest"/>
-         <permission type="consume" roles="guest"/>
-         <permission type="send" roles="guest"/>
-      </security-setting>
-   </security-settings>
-
-</configuration>

http://git-wip-us.apache.org/repos/asf/activemq-6/blob/a102983d/examples/jms/jmx/src/main/resources/hornetq/server0/activemq-jms.xml
----------------------------------------------------------------------
diff --git a/examples/jms/jmx/src/main/resources/hornetq/server0/activemq-jms.xml b/examples/jms/jmx/src/main/resources/hornetq/server0/activemq-jms.xml
deleted file mode 100644
index b53cafe..0000000
--- a/examples/jms/jmx/src/main/resources/hornetq/server0/activemq-jms.xml
+++ /dev/null
@@ -1,9 +0,0 @@
-<configuration xmlns="urn:activemq"
-            xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
-            xsi:schemaLocation="urn:activemq /schema/activemq-jms.xsd">
-
-   <!--the queue used by the example-->
-   <queue name="exampleQueue"/>
-   </queue>
-
-</configuration>

http://git-wip-us.apache.org/repos/asf/activemq-6/blob/a102983d/examples/jms/jmx/src/main/resources/hornetq/server0/activemq-users.xml
----------------------------------------------------------------------
diff --git a/examples/jms/jmx/src/main/resources/hornetq/server0/activemq-users.xml b/examples/jms/jmx/src/main/resources/hornetq/server0/activemq-users.xml
deleted file mode 100644
index ae30546..0000000
--- a/examples/jms/jmx/src/main/resources/hornetq/server0/activemq-users.xml
+++ /dev/null
@@ -1,7 +0,0 @@
-<configuration xmlns="urn:activemq" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
-            xsi:schemaLocation="urn:activemq /schema/activemq-users.xsd">
-   <!-- the default user.  this is used where username is null-->
-   <defaultuser name="guest" password="guest">
-      <role name="guest"/>
-   </defaultuser>
-</configuration>
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/activemq-6/blob/a102983d/examples/jms/jmx/src/main/resources/jndi.properties
----------------------------------------------------------------------
diff --git a/examples/jms/jmx/src/main/resources/jndi.properties b/examples/jms/jmx/src/main/resources/jndi.properties
new file mode 100644
index 0000000..d9b5c6a
--- /dev/null
+++ b/examples/jms/jmx/src/main/resources/jndi.properties
@@ -0,0 +1,3 @@
+java.naming.factory.initial=org.apache.activemq.jndi.ActiveMQInitialContextFactory
+java.naming.provider.url=tcp://localhost:5445
+queue.queue/exampleQueue=exampleQueue
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/activemq-6/blob/a102983d/examples/jms/large-message/pom.xml
----------------------------------------------------------------------
diff --git a/examples/jms/large-message/pom.xml b/examples/jms/large-message/pom.xml
index 312ca1a..33fd123 100644
--- a/examples/jms/large-message/pom.xml
+++ b/examples/jms/large-message/pom.xml
@@ -51,9 +51,6 @@
                   </goals>
                   <configuration>
                      <clientClass>org.apache.activemq.jms.example.LargeMessageExample</clientClass>
-                     <args>
-                        <param>tcp://localhost:5445</param>
-                     </args>
                      <systemProperties>
                         <property>
                            <name>exampleConfigDir</name>
@@ -108,7 +105,7 @@
             </dependencies>
             <configuration>
                <waitOnStart>false</waitOnStart>
-               <hornetqConfigurationDir>${basedir}/target/classes/activemq/server0</hornetqConfigurationDir>
+               <configurationDir>${basedir}/target/classes/activemq/server0</configurationDir>
             </configuration>
          </plugin>
       </plugins>

http://git-wip-us.apache.org/repos/asf/activemq-6/blob/a102983d/examples/jms/large-message/src/main/java/org/apache/activemq/jms/example/LargeMessageExample.java
----------------------------------------------------------------------
diff --git a/examples/jms/large-message/src/main/java/org/apache/activemq/jms/example/LargeMessageExample.java b/examples/jms/large-message/src/main/java/org/apache/activemq/jms/example/LargeMessageExample.java
index 7ffc7b9..2b9bf0e 100644
--- a/examples/jms/large-message/src/main/java/org/apache/activemq/jms/example/LargeMessageExample.java
+++ b/examples/jms/large-message/src/main/java/org/apache/activemq/jms/example/LargeMessageExample.java
@@ -50,13 +50,13 @@ public class LargeMessageExample extends ActiveMQExample
    }
 
    /**
-    * The message we will send is size 10GiB, even though we are only running in 50MB of RAM on both
+    * The message we will send is size 2GiB, even though we are only running in 50MB of RAM on both
     * client and server.
     * <p>
     * This may take some considerable time to create, send and consume - if it takes too long or you
     * don't have enough disk space just reduce the file size here
     */
-   private static final long FILE_SIZE = 2L * 1024 * 1024 * 1024; // 10 GiB message
+   private static final long FILE_SIZE = 2L * 1024 * 1024 * 1024; // 2 GiB message
 
    @Override
    public boolean runExample() throws Exception
@@ -67,7 +67,7 @@ public class LargeMessageExample extends ActiveMQExample
       try
       {
          // Step 1. Create an initial context to perform the JNDI lookup.
-         initialContext = getContext(0);
+         initialContext = new InitialContext();
 
          // Step 2. Perfom a lookup on the queue
          Queue queue = (Queue)initialContext.lookup("queue/exampleQueue");
@@ -137,7 +137,7 @@ public class LargeMessageExample extends ActiveMQExample
 
          // Step 11. Now the server is restarted we can recreate the JMS Objects, and start the new connection
 
-         initialContext = getContext(0);
+         initialContext = new InitialContext();
 
          queue = (Queue)initialContext.lookup("queue/exampleQueue");
 

http://git-wip-us.apache.org/repos/asf/activemq-6/blob/a102983d/examples/jms/large-message/src/main/resources/activemq/server0/activemq-configuration.xml
----------------------------------------------------------------------
diff --git a/examples/jms/large-message/src/main/resources/activemq/server0/activemq-configuration.xml b/examples/jms/large-message/src/main/resources/activemq/server0/activemq-configuration.xml
new file mode 100644
index 0000000..52d9570
--- /dev/null
+++ b/examples/jms/large-message/src/main/resources/activemq/server0/activemq-configuration.xml
@@ -0,0 +1,34 @@
+<configuration xmlns="urn:activemq"
+            xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+            xsi:schemaLocation="urn:activemq /schema/activemq-configuration.xsd">
+
+   <bindings-directory>${build.directory}/server0/data/messaging/bindings</bindings-directory>
+
+   <journal-directory>${build.directory}/server0/data/messaging/journal</journal-directory>
+
+   <large-messages-directory>${build.directory}/server0/data/messaging/largemessages</large-messages-directory>
+
+   <paging-directory>${build.directory}/server0/data/messaging/paging</paging-directory>
+   
+   <!-- Acceptors -->
+   <acceptors>
+      <acceptor name="netty-acceptor">
+         <factory-class>org.apache.activemq.core.remoting.impl.netty.NettyAcceptorFactory</factory-class>
+      </acceptor>
+   </acceptors>
+
+   <!-- Other config -->
+
+   <security-settings>
+      <!--security for example queue-->
+      <security-setting match="jms.queue.exampleQueue">
+         <permission type="createDurableQueue" roles="guest"/>
+         <permission type="deleteDurableQueue" roles="guest"/>
+         <permission type="createNonDurableQueue" roles="guest"/>
+         <permission type="deleteNonDurableQueue" roles="guest"/>
+         <permission type="consume" roles="guest"/>
+         <permission type="send" roles="guest"/>
+      </security-setting>
+   </security-settings>
+
+</configuration>

http://git-wip-us.apache.org/repos/asf/activemq-6/blob/a102983d/examples/jms/large-message/src/main/resources/activemq/server0/activemq-jms.xml
----------------------------------------------------------------------
diff --git a/examples/jms/large-message/src/main/resources/activemq/server0/activemq-jms.xml b/examples/jms/large-message/src/main/resources/activemq/server0/activemq-jms.xml
new file mode 100644
index 0000000..0d5c953
--- /dev/null
+++ b/examples/jms/large-message/src/main/resources/activemq/server0/activemq-jms.xml
@@ -0,0 +1,8 @@
+<configuration xmlns="urn:activemq"
+            xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+            xsi:schemaLocation="urn:activemq /schema/activemq-jms.xsd">
+
+   <!--the queue used by the example-->
+   <queue name="exampleQueue"/>
+
+</configuration>

http://git-wip-us.apache.org/repos/asf/activemq-6/blob/a102983d/examples/jms/large-message/src/main/resources/activemq/server0/activemq-users.xml
----------------------------------------------------------------------
diff --git a/examples/jms/large-message/src/main/resources/activemq/server0/activemq-users.xml b/examples/jms/large-message/src/main/resources/activemq/server0/activemq-users.xml
new file mode 100644
index 0000000..ae30546
--- /dev/null
+++ b/examples/jms/large-message/src/main/resources/activemq/server0/activemq-users.xml
@@ -0,0 +1,7 @@
+<configuration xmlns="urn:activemq" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+            xsi:schemaLocation="urn:activemq /schema/activemq-users.xsd">
+   <!-- the default user.  this is used where username is null-->
+   <defaultuser name="guest" password="guest">
+      <role name="guest"/>
+   </defaultuser>
+</configuration>
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/activemq-6/blob/a102983d/examples/jms/large-message/src/main/resources/hornetq/server0/activemq-configuration.xml
----------------------------------------------------------------------
diff --git a/examples/jms/large-message/src/main/resources/hornetq/server0/activemq-configuration.xml b/examples/jms/large-message/src/main/resources/hornetq/server0/activemq-configuration.xml
deleted file mode 100644
index 9fa4061..0000000
--- a/examples/jms/large-message/src/main/resources/hornetq/server0/activemq-configuration.xml
+++ /dev/null
@@ -1,42 +0,0 @@
-<configuration xmlns="urn:activemq"
-            xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
-            xsi:schemaLocation="urn:activemq /schema/activemq-configuration.xsd">
-
-   <bindings-directory>${build.directory}/server0/data/messaging/bindings</bindings-directory>
-
-   <journal-directory>${build.directory}/server0/data/messaging/journal</journal-directory>
-
-   <large-messages-directory>${build.directory}/server0/data/messaging/largemessages</large-messages-directory>
-
-   <paging-directory>${build.directory}/server0/data/messaging/paging</paging-directory>
-
-
-   <!-- Connectors -->
-   <connectors>
-      <connector name="netty-connector">
-         <factory-class>org.apache.activemq.core.remoting.impl.netty.NettyConnectorFactory</factory-class>
-      </connector>
-   </connectors>
-   
-   <!-- Acceptors -->
-   <acceptors>
-      <acceptor name="netty-acceptor">
-         <factory-class>org.apache.activemq.core.remoting.impl.netty.NettyAcceptorFactory</factory-class>
-      </acceptor>
-   </acceptors>
-
-   <!-- Other config -->
-
-   <security-settings>
-      <!--security for example queue-->
-      <security-setting match="jms.queue.exampleQueue">
-         <permission type="createDurableQueue" roles="guest"/>
-         <permission type="deleteDurableQueue" roles="guest"/>
-         <permission type="createNonDurableQueue" roles="guest"/>
-         <permission type="deleteNonDurableQueue" roles="guest"/>
-         <permission type="consume" roles="guest"/>
-         <permission type="send" roles="guest"/>
-      </security-setting>
-   </security-settings>
-
-</configuration>

http://git-wip-us.apache.org/repos/asf/activemq-6/blob/a102983d/examples/jms/large-message/src/main/resources/hornetq/server0/activemq-jms.xml
----------------------------------------------------------------------
diff --git a/examples/jms/large-message/src/main/resources/hornetq/server0/activemq-jms.xml b/examples/jms/large-message/src/main/resources/hornetq/server0/activemq-jms.xml
deleted file mode 100644
index 0d5c953..0000000
--- a/examples/jms/large-message/src/main/resources/hornetq/server0/activemq-jms.xml
+++ /dev/null
@@ -1,8 +0,0 @@
-<configuration xmlns="urn:activemq"
-            xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
-            xsi:schemaLocation="urn:activemq /schema/activemq-jms.xsd">
-
-   <!--the queue used by the example-->
-   <queue name="exampleQueue"/>
-
-</configuration>

http://git-wip-us.apache.org/repos/asf/activemq-6/blob/a102983d/examples/jms/large-message/src/main/resources/hornetq/server0/activemq-users.xml
----------------------------------------------------------------------
diff --git a/examples/jms/large-message/src/main/resources/hornetq/server0/activemq-users.xml b/examples/jms/large-message/src/main/resources/hornetq/server0/activemq-users.xml
deleted file mode 100644
index ae30546..0000000
--- a/examples/jms/large-message/src/main/resources/hornetq/server0/activemq-users.xml
+++ /dev/null
@@ -1,7 +0,0 @@
-<configuration xmlns="urn:activemq" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
-            xsi:schemaLocation="urn:activemq /schema/activemq-users.xsd">
-   <!-- the default user.  this is used where username is null-->
-   <defaultuser name="guest" password="guest">
-      <role name="guest"/>
-   </defaultuser>
-</configuration>
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/activemq-6/blob/a102983d/examples/jms/large-message/src/main/resources/jndi.properties
----------------------------------------------------------------------
diff --git a/examples/jms/large-message/src/main/resources/jndi.properties b/examples/jms/large-message/src/main/resources/jndi.properties
new file mode 100644
index 0000000..d9b5c6a
--- /dev/null
+++ b/examples/jms/large-message/src/main/resources/jndi.properties
@@ -0,0 +1,3 @@
+java.naming.factory.initial=org.apache.activemq.jndi.ActiveMQInitialContextFactory
+java.naming.provider.url=tcp://localhost:5445
+queue.queue/exampleQueue=exampleQueue
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/activemq-6/blob/a102983d/examples/jms/last-value-queue/pom.xml
----------------------------------------------------------------------
diff --git a/examples/jms/last-value-queue/pom.xml b/examples/jms/last-value-queue/pom.xml
index bfefd5f..2bcc97e 100644
--- a/examples/jms/last-value-queue/pom.xml
+++ b/examples/jms/last-value-queue/pom.xml
@@ -51,9 +51,6 @@
                   </goals>
                   <configuration>
                      <clientClass>org.apache.activemq.jms.example.LastValueQueueExample</clientClass>
-                     <args>
-                        <param>tcp://localhost:5445</param>
-                     </args>
                   </configuration>
                </execution>
                <execution>
@@ -102,7 +99,7 @@
             </dependencies>
             <configuration>
                <waitOnStart>false</waitOnStart>
-               <hornetqConfigurationDir>${basedir}/target/classes/activemq/server0</hornetqConfigurationDir>
+               <configurationDir>${basedir}/target/classes/activemq/server0</configurationDir>
             </configuration>
          </plugin>
       </plugins>

http://git-wip-us.apache.org/repos/asf/activemq-6/blob/a102983d/examples/jms/last-value-queue/src/main/java/org/apache/activemq/jms/example/LastValueQueueExample.java
----------------------------------------------------------------------
diff --git a/examples/jms/last-value-queue/src/main/java/org/apache/activemq/jms/example/LastValueQueueExample.java b/examples/jms/last-value-queue/src/main/java/org/apache/activemq/jms/example/LastValueQueueExample.java
index d62ea0b..be7992a 100644
--- a/examples/jms/last-value-queue/src/main/java/org/apache/activemq/jms/example/LastValueQueueExample.java
+++ b/examples/jms/last-value-queue/src/main/java/org/apache/activemq/jms/example/LastValueQueueExample.java
@@ -52,7 +52,7 @@ public class LastValueQueueExample extends ActiveMQExample
       try
       {
          // Step 1. Create an initial context to perform the JNDI lookup.
-         initialContext = getContext(0);
+         initialContext = new InitialContext();
 
          // Step 2. Perfom a lookup on the queue
          Queue queue = (Queue)initialContext.lookup("queue/exampleQueue");

http://git-wip-us.apache.org/repos/asf/activemq-6/blob/a102983d/examples/jms/last-value-queue/src/main/resources/activemq/server0/activemq-configuration.xml
----------------------------------------------------------------------
diff --git a/examples/jms/last-value-queue/src/main/resources/activemq/server0/activemq-configuration.xml b/examples/jms/last-value-queue/src/main/resources/activemq/server0/activemq-configuration.xml
new file mode 100644
index 0000000..7cc74d7
--- /dev/null
+++ b/examples/jms/last-value-queue/src/main/resources/activemq/server0/activemq-configuration.xml
@@ -0,0 +1,41 @@
+<configuration xmlns="urn:activemq"
+            xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+            xsi:schemaLocation="urn:activemq /schema/activemq-configuration.xsd">
+
+   <bindings-directory>${build.directory}/server0/data/messaging/bindings</bindings-directory>
+
+   <journal-directory>${build.directory}/server0/data/messaging/journal</journal-directory>
+
+   <large-messages-directory>${build.directory}/server0/data/messaging/largemessages</large-messages-directory>
+
+   <paging-directory>${build.directory}/server0/data/messaging/paging</paging-directory>
+   
+   <!-- Acceptors -->
+   <acceptors>
+      <acceptor name="netty-acceptor">
+         <factory-class>org.apache.activemq.core.remoting.impl.netty.NettyAcceptorFactory</factory-class>
+      </acceptor>
+   </acceptors>
+
+   <!-- Other config -->
+
+   <security-settings>
+      <!--security for example queue-->
+      <security-setting match="jms.queue.exampleQueue">
+         <permission type="createDurableQueue" roles="guest"/>
+         <permission type="deleteDurableQueue" roles="guest"/>
+         <permission type="createNonDurableQueue" roles="guest"/>
+         <permission type="deleteNonDurableQueue" roles="guest"/>
+         <permission type="consume" roles="guest"/>
+         <permission type="send" roles="guest"/>
+      </security-setting>
+   </security-settings>
+
+   <address-settings>
+      <!--override the expiry address for the example-->
+      <address-setting match="jms.queue.lastValueQueue">
+         <last-value-queue>true</last-value-queue>
+      </address-setting>
+   </address-settings>
+
+</configuration>

http://git-wip-us.apache.org/repos/asf/activemq-6/blob/a102983d/examples/jms/last-value-queue/src/main/resources/activemq/server0/activemq-jms.xml
----------------------------------------------------------------------
diff --git a/examples/jms/last-value-queue/src/main/resources/activemq/server0/activemq-jms.xml b/examples/jms/last-value-queue/src/main/resources/activemq/server0/activemq-jms.xml
new file mode 100644
index 0000000..847659f
--- /dev/null
+++ b/examples/jms/last-value-queue/src/main/resources/activemq/server0/activemq-jms.xml
@@ -0,0 +1,8 @@
+<configuration xmlns="urn:activemq"
+            xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+            xsi:schemaLocation="urn:activemq /schema/activemq-jms.xsd">
+
+   <!--the queue used by the example-->
+   <queue name="exampleQueue"/>
+
+</configuration>
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/activemq-6/blob/a102983d/examples/jms/last-value-queue/src/main/resources/activemq/server0/activemq-users.xml
----------------------------------------------------------------------
diff --git a/examples/jms/last-value-queue/src/main/resources/activemq/server0/activemq-users.xml b/examples/jms/last-value-queue/src/main/resources/activemq/server0/activemq-users.xml
new file mode 100644
index 0000000..ae30546
--- /dev/null
+++ b/examples/jms/last-value-queue/src/main/resources/activemq/server0/activemq-users.xml
@@ -0,0 +1,7 @@
+<configuration xmlns="urn:activemq" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+            xsi:schemaLocation="urn:activemq /schema/activemq-users.xsd">
+   <!-- the default user.  this is used where username is null-->
+   <defaultuser name="guest" password="guest">
+      <role name="guest"/>
+   </defaultuser>
+</configuration>
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/activemq-6/blob/a102983d/examples/jms/last-value-queue/src/main/resources/hornetq/server0/activemq-configuration.xml
----------------------------------------------------------------------
diff --git a/examples/jms/last-value-queue/src/main/resources/hornetq/server0/activemq-configuration.xml b/examples/jms/last-value-queue/src/main/resources/hornetq/server0/activemq-configuration.xml
deleted file mode 100644
index 7e8ce42..0000000
--- a/examples/jms/last-value-queue/src/main/resources/hornetq/server0/activemq-configuration.xml
+++ /dev/null
@@ -1,50 +0,0 @@
-<configuration xmlns="urn:activemq"
-            xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
-            xsi:schemaLocation="urn:activemq /schema/activemq-configuration.xsd">
-
-   <bindings-directory>${build.directory}/server0/data/messaging/bindings</bindings-directory>
-
-   <journal-directory>${build.directory}/server0/data/messaging/journal</journal-directory>
-
-   <large-messages-directory>${build.directory}/server0/data/messaging/largemessages</large-messages-directory>
-
-   <paging-directory>${build.directory}/server0/data/messaging/paging</paging-directory>
-
-
-   <!-- Connectors -->
-
-   <connectors>
-      <connector name="netty-connector">
-         <factory-class>org.apache.activemq.core.remoting.impl.netty.NettyConnectorFactory</factory-class>
-      </connector>
-   </connectors>
-   
-   <!-- Acceptors -->
-   <acceptors>
-      <acceptor name="netty-acceptor">
-         <factory-class>org.apache.activemq.core.remoting.impl.netty.NettyAcceptorFactory</factory-class>
-      </acceptor>
-   </acceptors>
-
-   <!-- Other config -->
-
-   <security-settings>
-      <!--security for example queue-->
-      <security-setting match="jms.queue.lastValueQueue">
-         <permission type="createDurableQueue" roles="guest"/>
-         <permission type="deleteDurableQueue" roles="guest"/>
-         <permission type="createNonDurableQueue" roles="guest"/>
-         <permission type="deleteNonDurableQueue" roles="guest"/>
-         <permission type="consume" roles="guest"/>
-         <permission type="send" roles="guest"/>
-      </security-setting>
-   </security-settings>
-
-   <address-settings>
-      <!--override the expiry address for the example-->
-      <address-setting match="jms.queue.lastValueQueue">
-         <last-value-queue>true</last-value-queue>
-      </address-setting>
-   </address-settings>
-
-</configuration>

http://git-wip-us.apache.org/repos/asf/activemq-6/blob/a102983d/examples/jms/last-value-queue/src/main/resources/hornetq/server0/activemq-jms.xml
----------------------------------------------------------------------
diff --git a/examples/jms/last-value-queue/src/main/resources/hornetq/server0/activemq-jms.xml b/examples/jms/last-value-queue/src/main/resources/hornetq/server0/activemq-jms.xml
deleted file mode 100644
index 847659f..0000000
--- a/examples/jms/last-value-queue/src/main/resources/hornetq/server0/activemq-jms.xml
+++ /dev/null
@@ -1,8 +0,0 @@
-<configuration xmlns="urn:activemq"
-            xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
-            xsi:schemaLocation="urn:activemq /schema/activemq-jms.xsd">
-
-   <!--the queue used by the example-->
-   <queue name="exampleQueue"/>
-
-</configuration>
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/activemq-6/blob/a102983d/examples/jms/last-value-queue/src/main/resources/hornetq/server0/activemq-users.xml
----------------------------------------------------------------------
diff --git a/examples/jms/last-value-queue/src/main/resources/hornetq/server0/activemq-users.xml b/examples/jms/last-value-queue/src/main/resources/hornetq/server0/activemq-users.xml
deleted file mode 100644
index ae30546..0000000
--- a/examples/jms/last-value-queue/src/main/resources/hornetq/server0/activemq-users.xml
+++ /dev/null
@@ -1,7 +0,0 @@
-<configuration xmlns="urn:activemq" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
-            xsi:schemaLocation="urn:activemq /schema/activemq-users.xsd">
-   <!-- the default user.  this is used where username is null-->
-   <defaultuser name="guest" password="guest">
-      <role name="guest"/>
-   </defaultuser>
-</configuration>
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/activemq-6/blob/a102983d/examples/jms/last-value-queue/src/main/resources/jndi.properties
----------------------------------------------------------------------
diff --git a/examples/jms/last-value-queue/src/main/resources/jndi.properties b/examples/jms/last-value-queue/src/main/resources/jndi.properties
new file mode 100644
index 0000000..d9b5c6a
--- /dev/null
+++ b/examples/jms/last-value-queue/src/main/resources/jndi.properties
@@ -0,0 +1,3 @@
+java.naming.factory.initial=org.apache.activemq.jndi.ActiveMQInitialContextFactory
+java.naming.provider.url=tcp://localhost:5445
+queue.queue/exampleQueue=exampleQueue
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/activemq-6/blob/a102983d/examples/jms/management-notifications/pom.xml
----------------------------------------------------------------------
diff --git a/examples/jms/management-notifications/pom.xml b/examples/jms/management-notifications/pom.xml
index 4afe1d4..dd70dc0 100644
--- a/examples/jms/management-notifications/pom.xml
+++ b/examples/jms/management-notifications/pom.xml
@@ -51,9 +51,6 @@
                   </goals>
                   <configuration>
                      <clientClass>org.apache.activemq.jms.example.ManagementNotificationExample</clientClass>
-                     <args>
-                        <param>tcp://localhost:5445</param>
-                     </args>
                   </configuration>
                </execution>
                <execution>
@@ -102,7 +99,7 @@
             </dependencies>
             <configuration>
                <waitOnStart>false</waitOnStart>
-               <hornetqConfigurationDir>${basedir}/target/classes/activemq/server0</hornetqConfigurationDir>
+               <configurationDir>${basedir}/target/classes/activemq/server0</configurationDir>
             </configuration>
          </plugin>
       </plugins>

http://git-wip-us.apache.org/repos/asf/activemq-6/blob/a102983d/examples/jms/management-notifications/src/main/java/org/apache/activemq/jms/example/ManagementNotificationExample.java
----------------------------------------------------------------------
diff --git a/examples/jms/management-notifications/src/main/java/org/apache/activemq/jms/example/ManagementNotificationExample.java b/examples/jms/management-notifications/src/main/java/org/apache/activemq/jms/example/ManagementNotificationExample.java
index b98f825..de631dc 100644
--- a/examples/jms/management-notifications/src/main/java/org/apache/activemq/jms/example/ManagementNotificationExample.java
+++ b/examples/jms/management-notifications/src/main/java/org/apache/activemq/jms/example/ManagementNotificationExample.java
@@ -52,7 +52,7 @@ public class ManagementNotificationExample extends ActiveMQExample
       try
       {
          // Step 1. Create an initial context to perform the JNDI lookup.
-         initialContext = getContext(0);
+         initialContext = new InitialContext();
 
          // Step 2. Perform a lookup on the queue
          Queue queue = (Queue)initialContext.lookup("queue/exampleQueue");

http://git-wip-us.apache.org/repos/asf/activemq-6/blob/a102983d/examples/jms/management-notifications/src/main/resources/activemq/server0/activemq-configuration.xml
----------------------------------------------------------------------
diff --git a/examples/jms/management-notifications/src/main/resources/activemq/server0/activemq-configuration.xml b/examples/jms/management-notifications/src/main/resources/activemq/server0/activemq-configuration.xml
new file mode 100644
index 0000000..64680fb
--- /dev/null
+++ b/examples/jms/management-notifications/src/main/resources/activemq/server0/activemq-configuration.xml
@@ -0,0 +1,52 @@
+<configuration xmlns="urn:activemq"
+            xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+            xsi:schemaLocation="urn:activemq ../../../../src/schema/activemq-configuration.xsd">
+
+   <bindings-directory>${build.directory}/server0/data/messaging/bindings</bindings-directory>
+
+   <journal-directory>${build.directory}/server0/data/messaging/journal</journal-directory>
+
+   <large-messages-directory>${build.directory}/server0/data/messaging/largemessages</large-messages-directory>
+
+   <paging-directory>${build.directory}/server0/data/messaging/paging</paging-directory>
+
+
+   <management-notification-address>jms.topic.notificationsTopic</management-notification-address>
+   
+   <!-- Netty standard TCP acceptor -->
+   <acceptors>
+      <acceptor name="netty">
+         <factory-class>org.apache.activemq.core.remoting.impl.netty.NettyAcceptorFactory</factory-class>
+      </acceptor>
+   </acceptors>
+
+   <!--  Other configs -->      
+
+   <security-settings>
+      <!--security for example queue-->
+      <security-setting match="jms.queue.exampleQueue">
+         <permission type="createDurableQueue" roles="guest"/>
+         <permission type="deleteDurableQueue" roles="guest"/>
+         <permission type="createNonDurableQueue" roles="guest"/>
+         <permission type="deleteNonDurableQueue" roles="guest"/>
+         <permission type="consume" roles="guest"/>
+         <permission type="send" roles="guest"/>
+      </security-setting>
+
+      <!--security for notification queue-->
+      <security-setting match="jms.topic.notificationsTopic">
+         <permission type="consume" roles="guest"/>
+         <permission type="createNonDurableQueue" roles="guest"/>
+         <permission type="deleteNonDurableQueue" roles="guest"/>
+      </security-setting>
+
+      <!-- security settings for JMS temporary queue -->
+      <security-setting match="queuetempjms.*">
+         <permission type="createNonDurableQueue" roles="guest"/>
+         <permission type="deleteNonDurableQueue" roles="guest"/>
+         <permission type="consume" roles="guest"/>
+         <permission type="send" roles="guest"/>
+      </security-setting>
+   </security-settings>
+
+</configuration>

http://git-wip-us.apache.org/repos/asf/activemq-6/blob/a102983d/examples/jms/management-notifications/src/main/resources/activemq/server0/activemq-jms.xml
----------------------------------------------------------------------
diff --git a/examples/jms/management-notifications/src/main/resources/activemq/server0/activemq-jms.xml b/examples/jms/management-notifications/src/main/resources/activemq/server0/activemq-jms.xml
new file mode 100644
index 0000000..65e5a5c
--- /dev/null
+++ b/examples/jms/management-notifications/src/main/resources/activemq/server0/activemq-jms.xml
@@ -0,0 +1,11 @@
+<configuration xmlns="urn:activemq"
+            xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+            xsi:schemaLocation="urn:activemq /schema/activemq-jms.xsd">
+
+   <!--the queue used by the example-->
+   <queue name="exampleQueue"/>
+
+   <!--the notifications topic used by the example-->
+   <topic name="notificationsTopic"/>
+
+</configuration>
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/activemq-6/blob/a102983d/examples/jms/management-notifications/src/main/resources/activemq/server0/activemq-users.xml
----------------------------------------------------------------------
diff --git a/examples/jms/management-notifications/src/main/resources/activemq/server0/activemq-users.xml b/examples/jms/management-notifications/src/main/resources/activemq/server0/activemq-users.xml
new file mode 100644
index 0000000..5db43ea
--- /dev/null
+++ b/examples/jms/management-notifications/src/main/resources/activemq/server0/activemq-users.xml
@@ -0,0 +1,7 @@
+<configuration xmlns="urn:activemq" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+            xsi:schemaLocation="urn:activemq /schema/activemq-security.xsd">
+   <!-- the default user.  this is used where username is null-->
+   <defaultuser name="guest" password="guest">
+      <role name="guest"/>
+   </defaultuser>
+</configuration>
\ No newline at end of file


Mime
View raw message