http://git-wip-us.apache.org/repos/asf/activemq-6/blob/4b63891a/examples/jms/transaction-failover/src/main/resources/activemq/server0/activemq-configuration.xml ---------------------------------------------------------------------- diff --git a/examples/jms/transaction-failover/src/main/resources/activemq/server0/activemq-configuration.xml b/examples/jms/transaction-failover/src/main/resources/activemq/server0/activemq-configuration.xml index 24ebec6..911b4b3 100644 --- a/examples/jms/transaction-failover/src/main/resources/activemq/server0/activemq-configuration.xml +++ b/examples/jms/transaction-failover/src/main/resources/activemq/server0/activemq-configuration.xml @@ -18,77 +18,85 @@ specific language governing permissions and limitations under the License. --> -<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> - - <ha-policy> - <shared-store> - <master/> - </shared-store> - </ha-policy> - - <!-- Connectors --> - - <connectors> - <connector name="netty-connector"> - <factory-class>org.apache.activemq.core.remoting.impl.netty.NettyConnectorFactory</factory-class> - <param key="port" value="5445"/> - </connector> - </connectors> - - <!-- Acceptors --> - <acceptors> - <acceptor name="netty-acceptor"> - <factory-class>org.apache.activemq.core.remoting.impl.netty.NettyAcceptorFactory</factory-class> - <param key="port" value="5445"/> - </acceptor> - </acceptors> - - <broadcast-groups> - <broadcast-group name="bg-group1"> - <group-address>${udp-address:231.7.7.7}</group-address> - <group-port>9876</group-port> - <broadcast-period>1000</broadcast-period> - <connector-ref>netty-connector</connector-ref> - </broadcast-group> - </broadcast-groups> - - <discovery-groups> - <discovery-group name="dg-group1"> - <group-address>${udp-address:231.7.7.7}</group-address> - <group-port>9876</group-port> - <refresh-timeout>60000</refresh-timeout> - </discovery-group> - </discovery-groups> - - <cluster-connections> - <cluster-connection name="my-cluster"> - <address>jms</address> - <connector-ref>netty-connector</connector-ref> - <discovery-group-ref discovery-group-name="dg-group1"/> - </cluster-connection> - </cluster-connections> - <!-- 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 xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" + xmlns="urn:activemq" + xsi:schemaLocation="urn:activemq /schema/activemq-server.xsd"> + <jms xmlns="urn:activemq:jms"> + <!--the queue used by the example--> + <queue name="exampleQueue"/> + </jms> + + <core xmlns="urn:activemq:core"> + + <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> + + <ha-policy> + <shared-store> + <master/> + </shared-store> + </ha-policy> + + <!-- Connectors --> + + <connectors> + <connector name="netty-connector"> + <factory-class>org.apache.activemq.core.remoting.impl.netty.NettyConnectorFactory</factory-class> + <param key="port" value="5445"/> + </connector> + </connectors> + + <!-- Acceptors --> + <acceptors> + <acceptor name="netty-acceptor"> + <factory-class>org.apache.activemq.core.remoting.impl.netty.NettyAcceptorFactory</factory-class> + <param key="port" value="5445"/> + </acceptor> + </acceptors> + + <broadcast-groups> + <broadcast-group name="bg-group1"> + <group-address>${udp-address:231.7.7.7}</group-address> + <group-port>9876</group-port> + <broadcast-period>1000</broadcast-period> + <connector-ref>netty-connector</connector-ref> + </broadcast-group> + </broadcast-groups> + + <discovery-groups> + <discovery-group name="dg-group1"> + <group-address>${udp-address:231.7.7.7}</group-address> + <group-port>9876</group-port> + <refresh-timeout>60000</refresh-timeout> + </discovery-group> + </discovery-groups> + + <cluster-connections> + <cluster-connection name="my-cluster"> + <address>jms</address> + <connector-ref>netty-connector</connector-ref> + <discovery-group-ref discovery-group-name="dg-group1"/> + </cluster-connection> + </cluster-connections> + <!-- 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> + + </core> </configuration>
http://git-wip-us.apache.org/repos/asf/activemq-6/blob/4b63891a/examples/jms/transaction-failover/src/main/resources/activemq/server0/activemq-jms.xml ---------------------------------------------------------------------- diff --git a/examples/jms/transaction-failover/src/main/resources/activemq/server0/activemq-jms.xml b/examples/jms/transaction-failover/src/main/resources/activemq/server0/activemq-jms.xml deleted file mode 100644 index 8ca9fd6..0000000 --- a/examples/jms/transaction-failover/src/main/resources/activemq/server0/activemq-jms.xml +++ /dev/null @@ -1,28 +0,0 @@ -<?xml version='1.0'?> -<!-- -Licensed to the Apache Software Foundation (ASF) under one -or more contributor license agreements. See the NOTICE file -distributed with this work for additional information -regarding copyright ownership. The ASF licenses this file -to you under the Apache License, Version 2.0 (the -"License"); you may not use this file except in compliance -with the License. You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - -Unless required by applicable law or agreed to in writing, -software distributed under the License is distributed on an -"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY -KIND, either express or implied. See the License for the -specific language governing permissions and limitations -under the License. ---> - -<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/4b63891a/examples/jms/transaction-failover/src/main/resources/activemq/server0/activemq-roles.properties ---------------------------------------------------------------------- diff --git a/examples/jms/transaction-failover/src/main/resources/activemq/server0/activemq-roles.properties b/examples/jms/transaction-failover/src/main/resources/activemq/server0/activemq-roles.properties new file mode 100644 index 0000000..4e2d44c --- /dev/null +++ b/examples/jms/transaction-failover/src/main/resources/activemq/server0/activemq-roles.properties @@ -0,0 +1,17 @@ +## --------------------------------------------------------------------------- +## Licensed to the Apache Software Foundation (ASF) under one or more +## contributor license agreements. See the NOTICE file distributed with +## this work for additional information regarding copyright ownership. +## The ASF licenses this file to You under the Apache License, Version 2.0 +## (the "License"); you may not use this file except in compliance with +## the License. You may obtain a copy of the License at +## +## http://www.apache.org/licenses/LICENSE-2.0 +## +## Unless required by applicable law or agreed to in writing, software +## distributed under the License is distributed on an "AS IS" BASIS, +## WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +## See the License for the specific language governing permissions and +## limitations under the License. +## --------------------------------------------------------------------------- +guest=guest \ No newline at end of file http://git-wip-us.apache.org/repos/asf/activemq-6/blob/4b63891a/examples/jms/transaction-failover/src/main/resources/activemq/server0/activemq-users.properties ---------------------------------------------------------------------- diff --git a/examples/jms/transaction-failover/src/main/resources/activemq/server0/activemq-users.properties b/examples/jms/transaction-failover/src/main/resources/activemq/server0/activemq-users.properties new file mode 100644 index 0000000..4e2d44c --- /dev/null +++ b/examples/jms/transaction-failover/src/main/resources/activemq/server0/activemq-users.properties @@ -0,0 +1,17 @@ +## --------------------------------------------------------------------------- +## Licensed to the Apache Software Foundation (ASF) under one or more +## contributor license agreements. See the NOTICE file distributed with +## this work for additional information regarding copyright ownership. +## The ASF licenses this file to You under the Apache License, Version 2.0 +## (the "License"); you may not use this file except in compliance with +## the License. You may obtain a copy of the License at +## +## http://www.apache.org/licenses/LICENSE-2.0 +## +## Unless required by applicable law or agreed to in writing, software +## distributed under the License is distributed on an "AS IS" BASIS, +## WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +## See the License for the specific language governing permissions and +## limitations under the License. +## --------------------------------------------------------------------------- +guest=guest \ No newline at end of file http://git-wip-us.apache.org/repos/asf/activemq-6/blob/4b63891a/examples/jms/transaction-failover/src/main/resources/activemq/server0/activemq-users.xml ---------------------------------------------------------------------- diff --git a/examples/jms/transaction-failover/src/main/resources/activemq/server0/activemq-users.xml b/examples/jms/transaction-failover/src/main/resources/activemq/server0/activemq-users.xml deleted file mode 100644 index f63079d..0000000 --- a/examples/jms/transaction-failover/src/main/resources/activemq/server0/activemq-users.xml +++ /dev/null @@ -1,27 +0,0 @@ -<?xml version='1.0'?> -<!-- -Licensed to the Apache Software Foundation (ASF) under one -or more contributor license agreements. See the NOTICE file -distributed with this work for additional information -regarding copyright ownership. The ASF licenses this file -to you under the Apache License, Version 2.0 (the -"License"); you may not use this file except in compliance -with the License. You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - -Unless required by applicable law or agreed to in writing, -software distributed under the License is distributed on an -"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY -KIND, either express or implied. See the License for the -specific language governing permissions and limitations -under the License. ---> - -<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> http://git-wip-us.apache.org/repos/asf/activemq-6/blob/4b63891a/examples/jms/transaction-failover/src/main/resources/activemq/server1/activemq-configuration.xml ---------------------------------------------------------------------- diff --git a/examples/jms/transaction-failover/src/main/resources/activemq/server1/activemq-configuration.xml b/examples/jms/transaction-failover/src/main/resources/activemq/server1/activemq-configuration.xml index f24508f..e53b603 100644 --- a/examples/jms/transaction-failover/src/main/resources/activemq/server1/activemq-configuration.xml +++ b/examples/jms/transaction-failover/src/main/resources/activemq/server1/activemq-configuration.xml @@ -18,77 +18,85 @@ specific language governing permissions and limitations under the License. --> -<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> - - <ha-policy> - <shared-store> - <slave/> - </shared-store> - </ha-policy> - - <!-- Connectors --> - <connectors> - <connector name="netty-connector"> - <factory-class>org.apache.activemq.core.remoting.impl.netty.NettyConnectorFactory</factory-class> - <param key="port" value="5446"/> - </connector> - </connectors> - - <!-- Acceptors --> - <acceptors> - <acceptor name="netty-acceptor"> - <factory-class>org.apache.activemq.core.remoting.impl.netty.NettyAcceptorFactory</factory-class> - <param key="port" value="5446"/> - </acceptor> - </acceptors> - - <broadcast-groups> - <broadcast-group name="bg-group1"> - <group-address>${udp-address:231.7.7.7}</group-address> - <group-port>9876</group-port> - <broadcast-period>1000</broadcast-period> - <connector-ref>netty-connector</connector-ref> - </broadcast-group> - </broadcast-groups> - - <discovery-groups> - <discovery-group name="dg-group1"> - <group-address>${udp-address:231.7.7.7}</group-address> - <group-port>9876</group-port> - <refresh-timeout>60000</refresh-timeout> - </discovery-group> - </discovery-groups> - - <cluster-connections> - <cluster-connection name="my-cluster"> - <address>jms</address> - <connector-ref>netty-connector</connector-ref> - <discovery-group-ref discovery-group-name="dg-group1"/> - </cluster-connection> - </cluster-connections> - - <!-- 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 xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" + xmlns="urn:activemq" + xsi:schemaLocation="urn:activemq /schema/activemq-server.xsd"> + + <jms xmlns="urn:activemq:jms"> + <!--the queue used by the example--> + <queue name="exampleQueue"/> + </jms> + + <core xmlns="urn:activemq:core"> + + <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> + + <ha-policy> + <shared-store> + <slave/> + </shared-store> + </ha-policy> + + <!-- Connectors --> + <connectors> + <connector name="netty-connector"> + <factory-class>org.apache.activemq.core.remoting.impl.netty.NettyConnectorFactory</factory-class> + <param key="port" value="5446"/> + </connector> + </connectors> + + <!-- Acceptors --> + <acceptors> + <acceptor name="netty-acceptor"> + <factory-class>org.apache.activemq.core.remoting.impl.netty.NettyAcceptorFactory</factory-class> + <param key="port" value="5446"/> + </acceptor> + </acceptors> + + <broadcast-groups> + <broadcast-group name="bg-group1"> + <group-address>${udp-address:231.7.7.7}</group-address> + <group-port>9876</group-port> + <broadcast-period>1000</broadcast-period> + <connector-ref>netty-connector</connector-ref> + </broadcast-group> + </broadcast-groups> + + <discovery-groups> + <discovery-group name="dg-group1"> + <group-address>${udp-address:231.7.7.7}</group-address> + <group-port>9876</group-port> + <refresh-timeout>60000</refresh-timeout> + </discovery-group> + </discovery-groups> + + <cluster-connections> + <cluster-connection name="my-cluster"> + <address>jms</address> + <connector-ref>netty-connector</connector-ref> + <discovery-group-ref discovery-group-name="dg-group1"/> + </cluster-connection> + </cluster-connections> + + <!-- 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> + + </core> </configuration> http://git-wip-us.apache.org/repos/asf/activemq-6/blob/4b63891a/examples/jms/transaction-failover/src/main/resources/activemq/server1/activemq-jms.xml ---------------------------------------------------------------------- diff --git a/examples/jms/transaction-failover/src/main/resources/activemq/server1/activemq-jms.xml b/examples/jms/transaction-failover/src/main/resources/activemq/server1/activemq-jms.xml deleted file mode 100644 index 8ca9fd6..0000000 --- a/examples/jms/transaction-failover/src/main/resources/activemq/server1/activemq-jms.xml +++ /dev/null @@ -1,28 +0,0 @@ -<?xml version='1.0'?> -<!-- -Licensed to the Apache Software Foundation (ASF) under one -or more contributor license agreements. See the NOTICE file -distributed with this work for additional information -regarding copyright ownership. The ASF licenses this file -to you under the Apache License, Version 2.0 (the -"License"); you may not use this file except in compliance -with the License. You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - -Unless required by applicable law or agreed to in writing, -software distributed under the License is distributed on an -"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY -KIND, either express or implied. See the License for the -specific language governing permissions and limitations -under the License. ---> - -<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/4b63891a/examples/jms/transaction-failover/src/main/resources/activemq/server1/activemq-roles.properties ---------------------------------------------------------------------- diff --git a/examples/jms/transaction-failover/src/main/resources/activemq/server1/activemq-roles.properties b/examples/jms/transaction-failover/src/main/resources/activemq/server1/activemq-roles.properties new file mode 100644 index 0000000..4e2d44c --- /dev/null +++ b/examples/jms/transaction-failover/src/main/resources/activemq/server1/activemq-roles.properties @@ -0,0 +1,17 @@ +## --------------------------------------------------------------------------- +## Licensed to the Apache Software Foundation (ASF) under one or more +## contributor license agreements. See the NOTICE file distributed with +## this work for additional information regarding copyright ownership. +## The ASF licenses this file to You under the Apache License, Version 2.0 +## (the "License"); you may not use this file except in compliance with +## the License. You may obtain a copy of the License at +## +## http://www.apache.org/licenses/LICENSE-2.0 +## +## Unless required by applicable law or agreed to in writing, software +## distributed under the License is distributed on an "AS IS" BASIS, +## WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +## See the License for the specific language governing permissions and +## limitations under the License. +## --------------------------------------------------------------------------- +guest=guest \ No newline at end of file http://git-wip-us.apache.org/repos/asf/activemq-6/blob/4b63891a/examples/jms/transaction-failover/src/main/resources/activemq/server1/activemq-users.properties ---------------------------------------------------------------------- diff --git a/examples/jms/transaction-failover/src/main/resources/activemq/server1/activemq-users.properties b/examples/jms/transaction-failover/src/main/resources/activemq/server1/activemq-users.properties new file mode 100644 index 0000000..4e2d44c --- /dev/null +++ b/examples/jms/transaction-failover/src/main/resources/activemq/server1/activemq-users.properties @@ -0,0 +1,17 @@ +## --------------------------------------------------------------------------- +## Licensed to the Apache Software Foundation (ASF) under one or more +## contributor license agreements. See the NOTICE file distributed with +## this work for additional information regarding copyright ownership. +## The ASF licenses this file to You under the Apache License, Version 2.0 +## (the "License"); you may not use this file except in compliance with +## the License. You may obtain a copy of the License at +## +## http://www.apache.org/licenses/LICENSE-2.0 +## +## Unless required by applicable law or agreed to in writing, software +## distributed under the License is distributed on an "AS IS" BASIS, +## WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +## See the License for the specific language governing permissions and +## limitations under the License. +## --------------------------------------------------------------------------- +guest=guest \ No newline at end of file http://git-wip-us.apache.org/repos/asf/activemq-6/blob/4b63891a/examples/jms/transaction-failover/src/main/resources/activemq/server1/activemq-users.xml ---------------------------------------------------------------------- diff --git a/examples/jms/transaction-failover/src/main/resources/activemq/server1/activemq-users.xml b/examples/jms/transaction-failover/src/main/resources/activemq/server1/activemq-users.xml deleted file mode 100644 index f63079d..0000000 --- a/examples/jms/transaction-failover/src/main/resources/activemq/server1/activemq-users.xml +++ /dev/null @@ -1,27 +0,0 @@ -<?xml version='1.0'?> -<!-- -Licensed to the Apache Software Foundation (ASF) under one -or more contributor license agreements. See the NOTICE file -distributed with this work for additional information -regarding copyright ownership. The ASF licenses this file -to you under the Apache License, Version 2.0 (the -"License"); you may not use this file except in compliance -with the License. You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - -Unless required by applicable law or agreed to in writing, -software distributed under the License is distributed on an -"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY -KIND, either express or implied. See the License for the -specific language governing permissions and limitations -under the License. ---> - -<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> http://git-wip-us.apache.org/repos/asf/activemq-6/blob/4b63891a/examples/jms/transactional/src/main/resources/activemq/server0/activemq-configuration.xml ---------------------------------------------------------------------- diff --git a/examples/jms/transactional/src/main/resources/activemq/server0/activemq-configuration.xml b/examples/jms/transactional/src/main/resources/activemq/server0/activemq-configuration.xml index 9f7ef1c..bb8c2d1 100644 --- a/examples/jms/transactional/src/main/resources/activemq/server0/activemq-configuration.xml +++ b/examples/jms/transactional/src/main/resources/activemq/server0/activemq-configuration.xml @@ -18,37 +18,45 @@ specific language governing permissions and limitations under the License. --> -<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 xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" + xmlns="urn:activemq" + xsi:schemaLocation="urn:activemq /schema/activemq-server.xsd"> + + <jms xmlns="urn:activemq:jms"> + <!--the queue used by the example--> + <queue name="exampleQueue"/> + </jms> + + <core xmlns="urn:activemq:core"> + + <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> + + </core> </configuration> http://git-wip-us.apache.org/repos/asf/activemq-6/blob/4b63891a/examples/jms/transactional/src/main/resources/activemq/server0/activemq-jms.xml ---------------------------------------------------------------------- diff --git a/examples/jms/transactional/src/main/resources/activemq/server0/activemq-jms.xml b/examples/jms/transactional/src/main/resources/activemq/server0/activemq-jms.xml deleted file mode 100644 index 8ca9fd6..0000000 --- a/examples/jms/transactional/src/main/resources/activemq/server0/activemq-jms.xml +++ /dev/null @@ -1,28 +0,0 @@ -<?xml version='1.0'?> -<!-- -Licensed to the Apache Software Foundation (ASF) under one -or more contributor license agreements. See the NOTICE file -distributed with this work for additional information -regarding copyright ownership. The ASF licenses this file -to you under the Apache License, Version 2.0 (the -"License"); you may not use this file except in compliance -with the License. You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - -Unless required by applicable law or agreed to in writing, -software distributed under the License is distributed on an -"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY -KIND, either express or implied. See the License for the -specific language governing permissions and limitations -under the License. ---> - -<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/4b63891a/examples/jms/transactional/src/main/resources/activemq/server0/activemq-roles.properties ---------------------------------------------------------------------- diff --git a/examples/jms/transactional/src/main/resources/activemq/server0/activemq-roles.properties b/examples/jms/transactional/src/main/resources/activemq/server0/activemq-roles.properties new file mode 100644 index 0000000..4e2d44c --- /dev/null +++ b/examples/jms/transactional/src/main/resources/activemq/server0/activemq-roles.properties @@ -0,0 +1,17 @@ +## --------------------------------------------------------------------------- +## Licensed to the Apache Software Foundation (ASF) under one or more +## contributor license agreements. See the NOTICE file distributed with +## this work for additional information regarding copyright ownership. +## The ASF licenses this file to You under the Apache License, Version 2.0 +## (the "License"); you may not use this file except in compliance with +## the License. You may obtain a copy of the License at +## +## http://www.apache.org/licenses/LICENSE-2.0 +## +## Unless required by applicable law or agreed to in writing, software +## distributed under the License is distributed on an "AS IS" BASIS, +## WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +## See the License for the specific language governing permissions and +## limitations under the License. +## --------------------------------------------------------------------------- +guest=guest \ No newline at end of file http://git-wip-us.apache.org/repos/asf/activemq-6/blob/4b63891a/examples/jms/transactional/src/main/resources/activemq/server0/activemq-users.properties ---------------------------------------------------------------------- diff --git a/examples/jms/transactional/src/main/resources/activemq/server0/activemq-users.properties b/examples/jms/transactional/src/main/resources/activemq/server0/activemq-users.properties new file mode 100644 index 0000000..4e2d44c --- /dev/null +++ b/examples/jms/transactional/src/main/resources/activemq/server0/activemq-users.properties @@ -0,0 +1,17 @@ +## --------------------------------------------------------------------------- +## Licensed to the Apache Software Foundation (ASF) under one or more +## contributor license agreements. See the NOTICE file distributed with +## this work for additional information regarding copyright ownership. +## The ASF licenses this file to You under the Apache License, Version 2.0 +## (the "License"); you may not use this file except in compliance with +## the License. You may obtain a copy of the License at +## +## http://www.apache.org/licenses/LICENSE-2.0 +## +## Unless required by applicable law or agreed to in writing, software +## distributed under the License is distributed on an "AS IS" BASIS, +## WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +## See the License for the specific language governing permissions and +## limitations under the License. +## --------------------------------------------------------------------------- +guest=guest \ No newline at end of file http://git-wip-us.apache.org/repos/asf/activemq-6/blob/4b63891a/examples/jms/transactional/src/main/resources/activemq/server0/activemq-users.xml ---------------------------------------------------------------------- diff --git a/examples/jms/transactional/src/main/resources/activemq/server0/activemq-users.xml b/examples/jms/transactional/src/main/resources/activemq/server0/activemq-users.xml deleted file mode 100644 index f63079d..0000000 --- a/examples/jms/transactional/src/main/resources/activemq/server0/activemq-users.xml +++ /dev/null @@ -1,27 +0,0 @@ -<?xml version='1.0'?> -<!-- -Licensed to the Apache Software Foundation (ASF) under one -or more contributor license agreements. See the NOTICE file -distributed with this work for additional information -regarding copyright ownership. The ASF licenses this file -to you under the Apache License, Version 2.0 (the -"License"); you may not use this file except in compliance -with the License. You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - -Unless required by applicable law or agreed to in writing, -software distributed under the License is distributed on an -"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY -KIND, either express or implied. See the License for the -specific language governing permissions and limitations -under the License. ---> - -<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> http://git-wip-us.apache.org/repos/asf/activemq-6/blob/4b63891a/examples/jms/xa-heuristic/src/main/resources/activemq/server0/activemq-configuration.xml ---------------------------------------------------------------------- diff --git a/examples/jms/xa-heuristic/src/main/resources/activemq/server0/activemq-configuration.xml b/examples/jms/xa-heuristic/src/main/resources/activemq/server0/activemq-configuration.xml index 9f7ef1c..bb8c2d1 100644 --- a/examples/jms/xa-heuristic/src/main/resources/activemq/server0/activemq-configuration.xml +++ b/examples/jms/xa-heuristic/src/main/resources/activemq/server0/activemq-configuration.xml @@ -18,37 +18,45 @@ specific language governing permissions and limitations under the License. --> -<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 xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" + xmlns="urn:activemq" + xsi:schemaLocation="urn:activemq /schema/activemq-server.xsd"> + + <jms xmlns="urn:activemq:jms"> + <!--the queue used by the example--> + <queue name="exampleQueue"/> + </jms> + + <core xmlns="urn:activemq:core"> + + <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> + + </core> </configuration> http://git-wip-us.apache.org/repos/asf/activemq-6/blob/4b63891a/examples/jms/xa-heuristic/src/main/resources/activemq/server0/activemq-jms.xml ---------------------------------------------------------------------- diff --git a/examples/jms/xa-heuristic/src/main/resources/activemq/server0/activemq-jms.xml b/examples/jms/xa-heuristic/src/main/resources/activemq/server0/activemq-jms.xml deleted file mode 100644 index 8ca9fd6..0000000 --- a/examples/jms/xa-heuristic/src/main/resources/activemq/server0/activemq-jms.xml +++ /dev/null @@ -1,28 +0,0 @@ -<?xml version='1.0'?> -<!-- -Licensed to the Apache Software Foundation (ASF) under one -or more contributor license agreements. See the NOTICE file -distributed with this work for additional information -regarding copyright ownership. The ASF licenses this file -to you under the Apache License, Version 2.0 (the -"License"); you may not use this file except in compliance -with the License. You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - -Unless required by applicable law or agreed to in writing, -software distributed under the License is distributed on an -"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY -KIND, either express or implied. See the License for the -specific language governing permissions and limitations -under the License. ---> - -<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/4b63891a/examples/jms/xa-heuristic/src/main/resources/activemq/server0/activemq-roles.properties ---------------------------------------------------------------------- diff --git a/examples/jms/xa-heuristic/src/main/resources/activemq/server0/activemq-roles.properties b/examples/jms/xa-heuristic/src/main/resources/activemq/server0/activemq-roles.properties new file mode 100644 index 0000000..4e2d44c --- /dev/null +++ b/examples/jms/xa-heuristic/src/main/resources/activemq/server0/activemq-roles.properties @@ -0,0 +1,17 @@ +## --------------------------------------------------------------------------- +## Licensed to the Apache Software Foundation (ASF) under one or more +## contributor license agreements. See the NOTICE file distributed with +## this work for additional information regarding copyright ownership. +## The ASF licenses this file to You under the Apache License, Version 2.0 +## (the "License"); you may not use this file except in compliance with +## the License. You may obtain a copy of the License at +## +## http://www.apache.org/licenses/LICENSE-2.0 +## +## Unless required by applicable law or agreed to in writing, software +## distributed under the License is distributed on an "AS IS" BASIS, +## WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +## See the License for the specific language governing permissions and +## limitations under the License. +## --------------------------------------------------------------------------- +guest=guest \ No newline at end of file http://git-wip-us.apache.org/repos/asf/activemq-6/blob/4b63891a/examples/jms/xa-heuristic/src/main/resources/activemq/server0/activemq-users.properties ---------------------------------------------------------------------- diff --git a/examples/jms/xa-heuristic/src/main/resources/activemq/server0/activemq-users.properties b/examples/jms/xa-heuristic/src/main/resources/activemq/server0/activemq-users.properties new file mode 100644 index 0000000..4e2d44c --- /dev/null +++ b/examples/jms/xa-heuristic/src/main/resources/activemq/server0/activemq-users.properties @@ -0,0 +1,17 @@ +## --------------------------------------------------------------------------- +## Licensed to the Apache Software Foundation (ASF) under one or more +## contributor license agreements. See the NOTICE file distributed with +## this work for additional information regarding copyright ownership. +## The ASF licenses this file to You under the Apache License, Version 2.0 +## (the "License"); you may not use this file except in compliance with +## the License. You may obtain a copy of the License at +## +## http://www.apache.org/licenses/LICENSE-2.0 +## +## Unless required by applicable law or agreed to in writing, software +## distributed under the License is distributed on an "AS IS" BASIS, +## WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +## See the License for the specific language governing permissions and +## limitations under the License. +## --------------------------------------------------------------------------- +guest=guest \ No newline at end of file http://git-wip-us.apache.org/repos/asf/activemq-6/blob/4b63891a/examples/jms/xa-heuristic/src/main/resources/activemq/server0/activemq-users.xml ---------------------------------------------------------------------- diff --git a/examples/jms/xa-heuristic/src/main/resources/activemq/server0/activemq-users.xml b/examples/jms/xa-heuristic/src/main/resources/activemq/server0/activemq-users.xml deleted file mode 100644 index f63079d..0000000 --- a/examples/jms/xa-heuristic/src/main/resources/activemq/server0/activemq-users.xml +++ /dev/null @@ -1,27 +0,0 @@ -<?xml version='1.0'?> -<!-- -Licensed to the Apache Software Foundation (ASF) under one -or more contributor license agreements. See the NOTICE file -distributed with this work for additional information -regarding copyright ownership. The ASF licenses this file -to you under the Apache License, Version 2.0 (the -"License"); you may not use this file except in compliance -with the License. You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - -Unless required by applicable law or agreed to in writing, -software distributed under the License is distributed on an -"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY -KIND, either express or implied. See the License for the -specific language governing permissions and limitations -under the License. ---> - -<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> http://git-wip-us.apache.org/repos/asf/activemq-6/blob/4b63891a/examples/jms/xa-receive/src/main/resources/activemq/server0/activemq-configuration.xml ---------------------------------------------------------------------- diff --git a/examples/jms/xa-receive/src/main/resources/activemq/server0/activemq-configuration.xml b/examples/jms/xa-receive/src/main/resources/activemq/server0/activemq-configuration.xml index 9f7ef1c..bb8c2d1 100644 --- a/examples/jms/xa-receive/src/main/resources/activemq/server0/activemq-configuration.xml +++ b/examples/jms/xa-receive/src/main/resources/activemq/server0/activemq-configuration.xml @@ -18,37 +18,45 @@ specific language governing permissions and limitations under the License. --> -<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 xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" + xmlns="urn:activemq" + xsi:schemaLocation="urn:activemq /schema/activemq-server.xsd"> + + <jms xmlns="urn:activemq:jms"> + <!--the queue used by the example--> + <queue name="exampleQueue"/> + </jms> + + <core xmlns="urn:activemq:core"> + + <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> + + </core> </configuration> http://git-wip-us.apache.org/repos/asf/activemq-6/blob/4b63891a/examples/jms/xa-receive/src/main/resources/activemq/server0/activemq-jms.xml ---------------------------------------------------------------------- diff --git a/examples/jms/xa-receive/src/main/resources/activemq/server0/activemq-jms.xml b/examples/jms/xa-receive/src/main/resources/activemq/server0/activemq-jms.xml deleted file mode 100644 index 8ca9fd6..0000000 --- a/examples/jms/xa-receive/src/main/resources/activemq/server0/activemq-jms.xml +++ /dev/null @@ -1,28 +0,0 @@ -<?xml version='1.0'?> -<!-- -Licensed to the Apache Software Foundation (ASF) under one -or more contributor license agreements. See the NOTICE file -distributed with this work for additional information -regarding copyright ownership. The ASF licenses this file -to you under the Apache License, Version 2.0 (the -"License"); you may not use this file except in compliance -with the License. You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - -Unless required by applicable law or agreed to in writing, -software distributed under the License is distributed on an -"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY -KIND, either express or implied. See the License for the -specific language governing permissions and limitations -under the License. ---> - -<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/4b63891a/examples/jms/xa-receive/src/main/resources/activemq/server0/activemq-roles.properties ---------------------------------------------------------------------- diff --git a/examples/jms/xa-receive/src/main/resources/activemq/server0/activemq-roles.properties b/examples/jms/xa-receive/src/main/resources/activemq/server0/activemq-roles.properties new file mode 100644 index 0000000..4e2d44c --- /dev/null +++ b/examples/jms/xa-receive/src/main/resources/activemq/server0/activemq-roles.properties @@ -0,0 +1,17 @@ +## --------------------------------------------------------------------------- +## Licensed to the Apache Software Foundation (ASF) under one or more +## contributor license agreements. See the NOTICE file distributed with +## this work for additional information regarding copyright ownership. +## The ASF licenses this file to You under the Apache License, Version 2.0 +## (the "License"); you may not use this file except in compliance with +## the License. You may obtain a copy of the License at +## +## http://www.apache.org/licenses/LICENSE-2.0 +## +## Unless required by applicable law or agreed to in writing, software +## distributed under the License is distributed on an "AS IS" BASIS, +## WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +## See the License for the specific language governing permissions and +## limitations under the License. +## --------------------------------------------------------------------------- +guest=guest \ No newline at end of file http://git-wip-us.apache.org/repos/asf/activemq-6/blob/4b63891a/examples/jms/xa-receive/src/main/resources/activemq/server0/activemq-users.properties ---------------------------------------------------------------------- diff --git a/examples/jms/xa-receive/src/main/resources/activemq/server0/activemq-users.properties b/examples/jms/xa-receive/src/main/resources/activemq/server0/activemq-users.properties new file mode 100644 index 0000000..4e2d44c --- /dev/null +++ b/examples/jms/xa-receive/src/main/resources/activemq/server0/activemq-users.properties @@ -0,0 +1,17 @@ +## --------------------------------------------------------------------------- +## Licensed to the Apache Software Foundation (ASF) under one or more +## contributor license agreements. See the NOTICE file distributed with +## this work for additional information regarding copyright ownership. +## The ASF licenses this file to You under the Apache License, Version 2.0 +## (the "License"); you may not use this file except in compliance with +## the License. You may obtain a copy of the License at +## +## http://www.apache.org/licenses/LICENSE-2.0 +## +## Unless required by applicable law or agreed to in writing, software +## distributed under the License is distributed on an "AS IS" BASIS, +## WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +## See the License for the specific language governing permissions and +## limitations under the License. +## --------------------------------------------------------------------------- +guest=guest \ No newline at end of file http://git-wip-us.apache.org/repos/asf/activemq-6/blob/4b63891a/examples/jms/xa-receive/src/main/resources/activemq/server0/activemq-users.xml ---------------------------------------------------------------------- diff --git a/examples/jms/xa-receive/src/main/resources/activemq/server0/activemq-users.xml b/examples/jms/xa-receive/src/main/resources/activemq/server0/activemq-users.xml deleted file mode 100644 index f63079d..0000000 --- a/examples/jms/xa-receive/src/main/resources/activemq/server0/activemq-users.xml +++ /dev/null @@ -1,27 +0,0 @@ -<?xml version='1.0'?> -<!-- -Licensed to the Apache Software Foundation (ASF) under one -or more contributor license agreements. See the NOTICE file -distributed with this work for additional information -regarding copyright ownership. The ASF licenses this file -to you under the Apache License, Version 2.0 (the -"License"); you may not use this file except in compliance -with the License. You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - -Unless required by applicable law or agreed to in writing, -software distributed under the License is distributed on an -"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY -KIND, either express or implied. See the License for the -specific language governing permissions and limitations -under the License. ---> - -<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> http://git-wip-us.apache.org/repos/asf/activemq-6/blob/4b63891a/examples/jms/xa-send/src/main/resources/activemq/server0/activemq-configuration.xml ---------------------------------------------------------------------- diff --git a/examples/jms/xa-send/src/main/resources/activemq/server0/activemq-configuration.xml b/examples/jms/xa-send/src/main/resources/activemq/server0/activemq-configuration.xml index 9f7ef1c..bb8c2d1 100644 --- a/examples/jms/xa-send/src/main/resources/activemq/server0/activemq-configuration.xml +++ b/examples/jms/xa-send/src/main/resources/activemq/server0/activemq-configuration.xml @@ -18,37 +18,45 @@ specific language governing permissions and limitations under the License. --> -<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 xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" + xmlns="urn:activemq" + xsi:schemaLocation="urn:activemq /schema/activemq-server.xsd"> + + <jms xmlns="urn:activemq:jms"> + <!--the queue used by the example--> + <queue name="exampleQueue"/> + </jms> + + <core xmlns="urn:activemq:core"> + + <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> + + </core> </configuration> http://git-wip-us.apache.org/repos/asf/activemq-6/blob/4b63891a/examples/jms/xa-send/src/main/resources/activemq/server0/activemq-jms.xml ---------------------------------------------------------------------- diff --git a/examples/jms/xa-send/src/main/resources/activemq/server0/activemq-jms.xml b/examples/jms/xa-send/src/main/resources/activemq/server0/activemq-jms.xml deleted file mode 100644 index 8ca9fd6..0000000 --- a/examples/jms/xa-send/src/main/resources/activemq/server0/activemq-jms.xml +++ /dev/null @@ -1,28 +0,0 @@ -<?xml version='1.0'?> -<!-- -Licensed to the Apache Software Foundation (ASF) under one -or more contributor license agreements. See the NOTICE file -distributed with this work for additional information -regarding copyright ownership. The ASF licenses this file -to you under the Apache License, Version 2.0 (the -"License"); you may not use this file except in compliance -with the License. You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - -Unless required by applicable law or agreed to in writing, -software distributed under the License is distributed on an -"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY -KIND, either express or implied. See the License for the -specific language governing permissions and limitations -under the License. ---> - -<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/4b63891a/examples/jms/xa-send/src/main/resources/activemq/server0/activemq-roles.properties ---------------------------------------------------------------------- diff --git a/examples/jms/xa-send/src/main/resources/activemq/server0/activemq-roles.properties b/examples/jms/xa-send/src/main/resources/activemq/server0/activemq-roles.properties new file mode 100644 index 0000000..4e2d44c --- /dev/null +++ b/examples/jms/xa-send/src/main/resources/activemq/server0/activemq-roles.properties @@ -0,0 +1,17 @@ +## --------------------------------------------------------------------------- +## Licensed to the Apache Software Foundation (ASF) under one or more +## contributor license agreements. See the NOTICE file distributed with +## this work for additional information regarding copyright ownership. +## The ASF licenses this file to You under the Apache License, Version 2.0 +## (the "License"); you may not use this file except in compliance with +## the License. You may obtain a copy of the License at +## +## http://www.apache.org/licenses/LICENSE-2.0 +## +## Unless required by applicable law or agreed to in writing, software +## distributed under the License is distributed on an "AS IS" BASIS, +## WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +## See the License for the specific language governing permissions and +## limitations under the License. +## --------------------------------------------------------------------------- +guest=guest \ No newline at end of file http://git-wip-us.apache.org/repos/asf/activemq-6/blob/4b63891a/examples/jms/xa-send/src/main/resources/activemq/server0/activemq-users.properties ---------------------------------------------------------------------- diff --git a/examples/jms/xa-send/src/main/resources/activemq/server0/activemq-users.properties b/examples/jms/xa-send/src/main/resources/activemq/server0/activemq-users.properties new file mode 100644 index 0000000..4e2d44c --- /dev/null +++ b/examples/jms/xa-send/src/main/resources/activemq/server0/activemq-users.properties @@ -0,0 +1,17 @@ +## --------------------------------------------------------------------------- +## Licensed to the Apache Software Foundation (ASF) under one or more +## contributor license agreements. See the NOTICE file distributed with +## this work for additional information regarding copyright ownership. +## The ASF licenses this file to You under the Apache License, Version 2.0 +## (the "License"); you may not use this file except in compliance with +## the License. You may obtain a copy of the License at +## +## http://www.apache.org/licenses/LICENSE-2.0 +## +## Unless required by applicable law or agreed to in writing, software +## distributed under the License is distributed on an "AS IS" BASIS, +## WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +## See the License for the specific language governing permissions and +## limitations under the License. +## --------------------------------------------------------------------------- +guest=guest \ No newline at end of file http://git-wip-us.apache.org/repos/asf/activemq-6/blob/4b63891a/examples/jms/xa-send/src/main/resources/activemq/server0/activemq-users.xml ---------------------------------------------------------------------- diff --git a/examples/jms/xa-send/src/main/resources/activemq/server0/activemq-users.xml b/examples/jms/xa-send/src/main/resources/activemq/server0/activemq-users.xml deleted file mode 100644 index f63079d..0000000 --- a/examples/jms/xa-send/src/main/resources/activemq/server0/activemq-users.xml +++ /dev/null @@ -1,27 +0,0 @@ -<?xml version='1.0'?> -<!-- -Licensed to the Apache Software Foundation (ASF) under one -or more contributor license agreements. See the NOTICE file -distributed with this work for additional information -regarding copyright ownership. The ASF licenses this file -to you under the Apache License, Version 2.0 (the -"License"); you may not use this file except in compliance -with the License. You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - -Unless required by applicable law or agreed to in writing, -software distributed under the License is distributed on an -"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY -KIND, either express or implied. See the License for the -specific language governing permissions and limitations -under the License. ---> - -<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> http://git-wip-us.apache.org/repos/asf/activemq-6/blob/4b63891a/examples/soak/normal/server0/activemq-configuration.xml ---------------------------------------------------------------------- diff --git a/examples/soak/normal/server0/activemq-configuration.xml b/examples/soak/normal/server0/activemq-configuration.xml index 0c2bf2d..a8d5536 100644 --- a/examples/soak/normal/server0/activemq-configuration.xml +++ b/examples/soak/normal/server0/activemq-configuration.xml @@ -20,39 +20,43 @@ under the License. <configuration xmlns="urn:activemq" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" - xsi:schemaLocation="urn:activemq /schema/activemq-configuration.xsd"> - - <connectors> - <connector name="netty-connector"> - <factory-class>org.apache.activemq.core.remoting.impl.netty.NettyConnectorFactory</factory-class> - <param key="tcp-no-delay" value="false"/> - <param key="tcp-send-buffer-size" value="1048576"/> - <param key="tcp-receive-buffer-size" value="1048576"/> - <param key="host" value="localhost"/> - </connector> - </connectors> - - <!-- Acceptors --> - <acceptors> - <acceptor name="netty-acceptor"> - <factory-class>org.apache.activemq.core.remoting.impl.netty.NettyAcceptorFactory</factory-class> - <param key="tcp-no-delay" value="false"/> - <param key="tcp-send-buffer-size" value="1048576"/> - <param key="tcp-receive-buffer-size" value="1048576"/> - <param key="host" value="localhost"/> - </acceptor> - </acceptors> - - <security-enabled>false</security-enabled> - - <persistence-enabled>false</persistence-enabled> - - <server-dump-interval>30000</server-dump-interval> - - <queues> - <queue name="soakQueue"> - <address>soakAddress</address> - </queue> - </queues> + xsi:schemaLocation="urn:activemq /schema/activemq-server.xsd"> + <jms xmlns="urn:activemq:jms"> + <queue name="soakQueue"/> + </jms> + <core xmlns="urn:activemq:core"> + <connectors> + <connector name="netty-connector"> + <factory-class>org.apache.activemq.core.remoting.impl.netty.NettyConnectorFactory</factory-class> + <param key="tcp-no-delay" value="false"/> + <param key="tcp-send-buffer-size" value="1048576"/> + <param key="tcp-receive-buffer-size" value="1048576"/> + <param key="host" value="localhost"/> + </connector> + </connectors> + + <!-- Acceptors --> + <acceptors> + <acceptor name="netty-acceptor"> + <factory-class>org.apache.activemq.core.remoting.impl.netty.NettyAcceptorFactory</factory-class> + <param key="tcp-no-delay" value="false"/> + <param key="tcp-send-buffer-size" value="1048576"/> + <param key="tcp-receive-buffer-size" value="1048576"/> + <param key="host" value="localhost"/> + </acceptor> + </acceptors> + + <security-enabled>false</security-enabled> + + <persistence-enabled>false</persistence-enabled> + + <server-dump-interval>30000</server-dump-interval> + + <queues> + <queue name="soakQueue"> + <address>soakAddress</address> + </queue> + </queues> + </core> </configuration> http://git-wip-us.apache.org/repos/asf/activemq-6/blob/4b63891a/examples/soak/normal/server0/activemq-jms.xml ---------------------------------------------------------------------- diff --git a/examples/soak/normal/server0/activemq-jms.xml b/examples/soak/normal/server0/activemq-jms.xml deleted file mode 100644 index 14a6558..0000000 --- a/examples/soak/normal/server0/activemq-jms.xml +++ /dev/null @@ -1,27 +0,0 @@ -<?xml version='1.0'?> -<!-- -Licensed to the Apache Software Foundation (ASF) under one -or more contributor license agreements. See the NOTICE file -distributed with this work for additional information -regarding copyright ownership. The ASF licenses this file -to you under the Apache License, Version 2.0 (the -"License"); you may not use this file except in compliance -with the License. You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - -Unless required by applicable law or agreed to in writing, -software distributed under the License is distributed on an -"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY -KIND, either express or implied. See the License for the -specific language governing permissions and limitations -under the License. ---> - -<configuration xmlns="urn:activemq" - xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" - xsi:schemaLocation="urn:activemq /schema/activemq-jms.xsd"> - - <queue name="soakQueue"/> - -</configuration> http://git-wip-us.apache.org/repos/asf/activemq-6/blob/4b63891a/tests/integration-tests/src/test/java/org/apache/activemq/tests/integration/InterceptorTest.java ---------------------------------------------------------------------- diff --git a/tests/integration-tests/src/test/java/org/apache/activemq/tests/integration/InterceptorTest.java b/tests/integration-tests/src/test/java/org/apache/activemq/tests/integration/InterceptorTest.java index 1f0aaca..3395e61 100644 --- a/tests/integration-tests/src/test/java/org/apache/activemq/tests/integration/InterceptorTest.java +++ b/tests/integration-tests/src/test/java/org/apache/activemq/tests/integration/InterceptorTest.java @@ -41,6 +41,7 @@ import org.apache.activemq.core.protocol.core.impl.wireformat.SessionSendMessage import org.apache.activemq.core.server.ActiveMQServer; import org.apache.activemq.core.server.ServerMessage; import org.apache.activemq.spi.core.protocol.RemotingConnection; +import org.apache.activemq.spi.core.security.ActiveMQSecurityManagerImpl; import org.apache.activemq.tests.util.ServiceTestBase; import org.junit.Assert; import org.junit.Before; @@ -485,8 +486,9 @@ public class InterceptorTest extends ServiceTestBase { SimpleString ANOTHER_QUEUE = QUEUE.concat("another"); - server.getSecurityManager().addUser("dumb", "dumber"); - server.getSecurityManager().addUser("an", "other"); + ActiveMQSecurityManagerImpl securityManager = (ActiveMQSecurityManagerImpl) server.getSecurityManager(); + securityManager.getConfiguration().addUser("dumb", "dumber"); + securityManager.getConfiguration().addUser("an", "other"); server.getRemotingService().addIncomingInterceptor(new InterceptUserOnCreateQueue()); @@ -540,9 +542,9 @@ public class InterceptorTest extends ServiceTestBase @Test public void testInterceptUsernameOnConsumer() throws Exception { - - server.getSecurityManager().addUser("dumb", "dumber"); - server.getSecurityManager().addUser("an", "other"); + ActiveMQSecurityManagerImpl securityManager = (ActiveMQSecurityManagerImpl) server.getSecurityManager(); + securityManager.getConfiguration().addUser("dumb", "dumber"); + securityManager.getConfiguration().addUser("an", "other"); server.getRemotingService().addIncomingInterceptor(new InterceptUserOnCreateConsumer()); http://git-wip-us.apache.org/repos/asf/activemq-6/blob/4b63891a/tests/integration-tests/src/test/java/org/apache/activemq/tests/integration/client/AutoCreateJmsQueueTest.java ---------------------------------------------------------------------- diff --git a/tests/integration-tests/src/test/java/org/apache/activemq/tests/integration/client/AutoCreateJmsQueueTest.java b/tests/integration-tests/src/test/java/org/apache/activemq/tests/integration/client/AutoCreateJmsQueueTest.java index f76d631..975f535 100644 --- a/tests/integration-tests/src/test/java/org/apache/activemq/tests/integration/client/AutoCreateJmsQueueTest.java +++ b/tests/integration-tests/src/test/java/org/apache/activemq/tests/integration/client/AutoCreateJmsQueueTest.java @@ -32,6 +32,7 @@ import org.apache.activemq.api.core.SimpleString; import org.apache.activemq.api.jms.ActiveMQJMSClient; import org.apache.activemq.core.security.Role; import org.apache.activemq.core.server.Queue; +import org.apache.activemq.spi.core.security.ActiveMQSecurityManagerImpl; import org.apache.activemq.tests.util.JMSTestBase; import org.junit.Assert; import org.junit.Before; @@ -77,9 +78,9 @@ public class AutoCreateJmsQueueTest extends JMSTestBase @Test public void testAutoCreateOnSendToQueueSecurity() throws Exception { - server.getSecurityManager().addUser("guest", "guest"); - server.getSecurityManager().setDefaultUser("guest"); - server.getSecurityManager().addRole("guest", "rejectAll"); + ((ActiveMQSecurityManagerImpl)server.getSecurityManager()).getConfiguration().addUser("guest", "guest"); + ((ActiveMQSecurityManagerImpl)server.getSecurityManager()).getConfiguration().setDefaultUser("guest"); + ((ActiveMQSecurityManagerImpl)server.getSecurityManager()).getConfiguration().addRole("guest", "rejectAll"); Role role = new Role("rejectAll", false, false, false, false, false, false, false); Set<Role> roles = new HashSet<Role>(); roles.add(role); @@ -171,9 +172,9 @@ public class AutoCreateJmsQueueTest extends JMSTestBase public void setUp() throws Exception { super.setUp(); - server.getSecurityManager().addUser("guest", "guest"); - server.getSecurityManager().setDefaultUser("guest"); - server.getSecurityManager().addRole("guest", "allowAll"); + ((ActiveMQSecurityManagerImpl)server.getSecurityManager()).getConfiguration().addUser("guest", "guest"); + ((ActiveMQSecurityManagerImpl)server.getSecurityManager()).getConfiguration().setDefaultUser("guest"); + ((ActiveMQSecurityManagerImpl)server.getSecurityManager()).getConfiguration().addRole("guest", "allowAll"); Role role = new Role("allowAll", true, true, true, true, true, true, true); Set<Role> roles = new HashSet<Role>(); roles.add(role); http://git-wip-us.apache.org/repos/asf/activemq-6/blob/4b63891a/tests/integration-tests/src/test/java/org/apache/activemq/tests/integration/cluster/failover/SecurityFailoverTest.java ---------------------------------------------------------------------- diff --git a/tests/integration-tests/src/test/java/org/apache/activemq/tests/integration/cluster/failover/SecurityFailoverTest.java b/tests/integration-tests/src/test/java/org/apache/activemq/tests/integration/cluster/failover/SecurityFailoverTest.java index 82500d5..cf9c997 100644 --- a/tests/integration-tests/src/test/java/org/apache/activemq/tests/integration/cluster/failover/SecurityFailoverTest.java +++ b/tests/integration-tests/src/test/java/org/apache/activemq/tests/integration/cluster/failover/SecurityFailoverTest.java @@ -26,7 +26,7 @@ import org.apache.activemq.core.config.ha.SharedStoreMasterPolicyConfiguration; import org.apache.activemq.core.config.ha.SharedStoreSlavePolicyConfiguration; import org.apache.activemq.core.security.Role; import org.apache.activemq.core.server.impl.InVMNodeManager; -import org.apache.activemq.spi.core.security.ActiveMQSecurityManager; +import org.apache.activemq.spi.core.security.ActiveMQSecurityManagerImpl; import org.apache.activemq.tests.integration.cluster.util.TestableServer; /** @@ -112,8 +112,8 @@ public class SecurityFailoverTest extends FailoverTest .addClusterConfiguration(basicClusterConnectionConfig(backupConnector.getName(), liveConnector.getName())); backupServer = createTestableServer(backupConfig); - ActiveMQSecurityManager securityManager = installSecurity(backupServer); - securityManager.setDefaultUser(null); + ActiveMQSecurityManagerImpl securityManager = installSecurity(backupServer); + securityManager.getConfiguration().setDefaultUser(null); liveConfig = super.createDefaultConfig() .clearAcceptorConfigurations() @@ -137,15 +137,15 @@ public class SecurityFailoverTest extends FailoverTest /** * @return */ - protected ActiveMQSecurityManager installSecurity(TestableServer server) + protected ActiveMQSecurityManagerImpl installSecurity(TestableServer server) { - ActiveMQSecurityManager securityManager = server.getServer().getSecurityManager(); - securityManager.addUser("a", "b"); + ActiveMQSecurityManagerImpl securityManager = (ActiveMQSecurityManagerImpl) server.getServer().getSecurityManager(); + securityManager.getConfiguration().addUser("a", "b"); Role role = new Role("arole", true, true, true, true, true, true, true); Set<Role> roles = new HashSet<Role>(); roles.add(role); server.getServer().getSecurityRepository().addMatch("#", roles); - securityManager.addRole("a", "arole"); + securityManager.getConfiguration().addRole("a", "arole"); return securityManager; } } http://git-wip-us.apache.org/repos/asf/activemq-6/blob/4b63891a/tests/integration-tests/src/test/java/org/apache/activemq/tests/integration/core/deployers/impl/QueueDeployerTest.java ---------------------------------------------------------------------- diff --git a/tests/integration-tests/src/test/java/org/apache/activemq/tests/integration/core/deployers/impl/QueueDeployerTest.java b/tests/integration-tests/src/test/java/org/apache/activemq/tests/integration/core/deployers/impl/QueueDeployerTest.java deleted file mode 100644 index fb847c9..0000000 --- a/tests/integration-tests/src/test/java/org/apache/activemq/tests/integration/core/deployers/impl/QueueDeployerTest.java +++ /dev/null @@ -1,96 +0,0 @@ -/** - * Licensed to the Apache Software Foundation (ASF) under one or more - * contributor license agreements. See the NOTICE file distributed with - * this work for additional information regarding copyright ownership. - * The ASF licenses this file to You under the Apache License, Version 2.0 - * (the "License"); you may not use this file except in compliance with - * the License. You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -package org.apache.activemq.tests.integration.core.deployers.impl; -import org.junit.Before; - -import org.junit.Test; - -import org.apache.activemq.api.core.SimpleString; -import org.apache.activemq.core.deployers.DeploymentManager; -import org.apache.activemq.core.deployers.impl.FileDeploymentManager; -import org.apache.activemq.core.deployers.impl.QueueDeployer; -import org.apache.activemq.core.postoffice.Binding; -import org.apache.activemq.core.postoffice.Bindings; -import org.apache.activemq.core.postoffice.impl.LocalQueueBinding; -import org.apache.activemq.core.server.ActiveMQServer; -import org.apache.activemq.tests.util.ServiceTestBase; -import org.w3c.dom.Element; -import org.w3c.dom.NodeList; - -/** - * A QueueDeployerTest - * - * @author <a href="[email protected]">Jeff Mesnil</a> - * - */ -public class QueueDeployerTest extends ServiceTestBase -{ - - // Constants ----------------------------------------------------- - - // Attributes ---------------------------------------------------- - - private QueueDeployer deployer; - - private ActiveMQServer server; - - @Test - public void testParseQueueConfiguration() throws Exception - { - String xml = "<configuration xmlns='urn:activemq'>" - + " <queues>" - + " <queue name='foo'>" - + " <address>bar</address>" - + " <filter string='speed > 88' />" - + " <durable>false</durable>" - + " </queue>" - + " </queues>" - + "</configuration>"; - - Element rootNode = org.apache.activemq.utils.XMLUtil.stringToElement(xml); - deployer.validate(rootNode); - NodeList queueNodes = rootNode.getElementsByTagName("queue"); - assertEquals(1, queueNodes.getLength()); - deployer.deploy(queueNodes.item(0)); - - Bindings bindings = server.getPostOffice().getBindingsForAddress(SimpleString.toSimpleString("bar")); - assertEquals(1, bindings.getBindings().size()); - Binding binding = bindings.getBindings().iterator().next(); - assertTrue(binding instanceof LocalQueueBinding); - LocalQueueBinding queueBinding = (LocalQueueBinding)binding; - - assertEquals("foo", queueBinding.getQueue().getName().toString()); - assertEquals("speed > 88", queueBinding.getQueue().getFilter().getFilterString().toString()); - assertEquals(false, queueBinding.getQueue().isDurable()); - } - - // Package protected --------------------------------------------- - - // Protected ----------------------------------------------------- - - @Override - @Before - public void setUp() throws Exception - { - super.setUp(); - - server = createServer(true); - DeploymentManager deploymentManager = new FileDeploymentManager(500); - deployer = new QueueDeployer(deploymentManager, server); - server.start(); - } -} http://git-wip-us.apache.org/repos/asf/activemq-6/blob/4b63891a/tests/integration-tests/src/test/java/org/apache/activemq/tests/integration/jms/JMSSecurityTest.java ---------------------------------------------------------------------- diff --git a/tests/integration-tests/src/test/java/org/apache/activemq/tests/integration/jms/JMSSecurityTest.java b/tests/integration-tests/src/test/java/org/apache/activemq/tests/integration/jms/JMSSecurityTest.java index 50c6263..9713a83 100644 --- a/tests/integration-tests/src/test/java/org/apache/activemq/tests/integration/jms/JMSSecurityTest.java +++ b/tests/integration-tests/src/test/java/org/apache/activemq/tests/integration/jms/JMSSecurityTest.java @@ -22,6 +22,7 @@ import javax.jms.JMSSecurityRuntimeException; import javax.jms.QueueConnection; import javax.jms.QueueConnectionFactory; +import org.apache.activemq.spi.core.security.ActiveMQSecurityManagerImpl; import org.apache.activemq.tests.util.JMSTestBase; import org.junit.Before; import org.junit.Test; @@ -48,8 +49,8 @@ public class JMSSecurityTest extends JMSTestBase @Test public void testSecurityOnJMSContext() throws Exception { - - server.getSecurityManager().addUser("IDo", "Exist"); + ActiveMQSecurityManagerImpl securityManager = (ActiveMQSecurityManagerImpl) server.getSecurityManager(); + securityManager.getConfiguration().addUser("IDo", "Exist"); try { JMSContext ctx = cf.createContext("Idont", "exist"); @@ -66,8 +67,8 @@ public class JMSSecurityTest extends JMSTestBase @Test public void testCreateQueueConnection() throws Exception { - - server.getSecurityManager().addUser("IDo", "Exist"); + ActiveMQSecurityManagerImpl securityManager = (ActiveMQSecurityManagerImpl) server.getSecurityManager(); + securityManager.getConfiguration().addUser("IDo", "Exist"); try { QueueConnection queueC = ((QueueConnectionFactory)cf).createQueueConnection("IDont", "Exist"); http://git-wip-us.apache.org/repos/asf/activemq-6/blob/4b63891a/tests/integration-tests/src/test/java/org/apache/activemq/tests/integration/jms/server/JMSServerDeployerTest.java ---------------------------------------------------------------------- diff --git a/tests/integration-tests/src/test/java/org/apache/activemq/tests/integration/jms/server/JMSServerDeployerTest.java b/tests/integration-tests/src/test/java/org/apache/activemq/tests/integration/jms/server/JMSServerDeployerTest.java index ba00340..c3b3de3 100644 --- a/tests/integration-tests/src/test/java/org/apache/activemq/tests/integration/jms/server/JMSServerDeployerTest.java +++ b/tests/integration-tests/src/test/java/org/apache/activemq/tests/integration/jms/server/JMSServerDeployerTest.java @@ -24,13 +24,10 @@ import org.apache.activemq.api.core.DiscoveryGroupConfiguration; import org.apache.activemq.api.core.TransportConfiguration; import org.apache.activemq.api.core.UDPBroadcastGroupConfiguration; import org.apache.activemq.core.config.Configuration; -import org.apache.activemq.core.deployers.DeploymentManager; -import org.apache.activemq.core.deployers.impl.FileDeploymentManager; import org.apache.activemq.core.registry.JndiBindingRegistry; import org.apache.activemq.core.remoting.impl.netty.NettyConnectorFactory; import org.apache.activemq.core.server.ActiveMQServer; import org.apache.activemq.jms.server.JMSServerManager; -import org.apache.activemq.jms.server.impl.JMSServerDeployer; import org.apache.activemq.jms.server.impl.JMSServerManagerImpl; import org.apache.activemq.tests.integration.IntegrationTestLogger; import org.apache.activemq.tests.unit.util.InVMNamingContext; @@ -39,7 +36,6 @@ import org.junit.After; import org.junit.Assert; import org.junit.Before; import org.junit.Test; -import org.w3c.dom.Element; /** * A JMSServerDeployerTest @@ -62,24 +58,11 @@ public class JMSServerDeployerTest extends ServiceTestBase private Context context; - private DeploymentManager deploymentManager; - private Configuration config; // Public -------------------------------------------------------- @Test - public void testValidateEmptyConfiguration() throws Exception - { - JMSServerDeployer deployer = new JMSServerDeployer(jmsServer, deploymentManager); - - String xml = "<configuration xmlns='urn:activemq'> " + "</configuration>"; - - Element rootNode = org.apache.activemq.utils.XMLUtil.stringToElement(xml); - deployer.validate(rootNode); - } - - @Test public void testDeployUnusualQueueNames() throws Exception { doTestDeployQueuesWithUnusualNames("queue.with.dots.in.name", "/myqueue"); @@ -154,8 +137,6 @@ public class JMSServerDeployerTest extends ServiceTestBase ActiveMQServer server = createServer(false, config); - deploymentManager = new FileDeploymentManager(config.getFileDeployerScanPeriod()); - jmsServer = new JMSServerManagerImpl(server); context = new InVMNamingContext(); jmsServer.setRegistry(new JndiBindingRegistry(context)); @@ -169,7 +150,6 @@ public class JMSServerDeployerTest extends ServiceTestBase jmsServer.stop(); jmsServer = null; context = null; - deploymentManager = null; config = null; super.tearDown();
