Author: ataylor
Date: 2009-10-29 06:19:25 -0400 (Thu, 29 Oct 2009)
New Revision: 8165
Added:
trunk/examples/javaee/ejb-jms-transaction/config/META-INF/
trunk/examples/javaee/ejb-jms-transaction/config/META-INF/application.xml
trunk/examples/javaee/hajndi/config/META-INF/
trunk/examples/javaee/hajndi/config/META-INF/application.xml
trunk/examples/javaee/jca-config/config/META-INF/
trunk/examples/javaee/jca-config/config/META-INF/application.xml
trunk/examples/javaee/jms-bridge/config/META-INF/
trunk/examples/javaee/jms-bridge/config/META-INF/application.xml
trunk/examples/javaee/mdb-bmt/config/META-INF/
trunk/examples/javaee/mdb-bmt/config/META-INF/application.xml
trunk/examples/javaee/mdb-cmt-setrollbackonly/config/META-INF/
trunk/examples/javaee/mdb-cmt-setrollbackonly/config/META-INF/application.xml
trunk/examples/javaee/mdb-cmt-tx-local/config/META-INF/
trunk/examples/javaee/mdb-cmt-tx-local/config/META-INF/application.xml
trunk/examples/javaee/mdb-cmt-tx-not-supported/config/META-INF/
trunk/examples/javaee/mdb-cmt-tx-not-supported/config/META-INF/application.xml
trunk/examples/javaee/mdb-cmt-tx-required/config/META-INF/
trunk/examples/javaee/mdb-cmt-tx-required/config/META-INF/application.xml
trunk/examples/javaee/mdb-message-selector/config/META-INF/
trunk/examples/javaee/mdb-message-selector/config/META-INF/application.xml
trunk/examples/javaee/mdb-tx-send/config/META-INF/
trunk/examples/javaee/mdb-tx-send/config/META-INF/application.xml
trunk/src/config/jboss-as/build-as4.xml
trunk/src/config/jboss-as/build-as5.xml
trunk/src/config/jboss-as/clustered/jboss-as-4/
trunk/src/config/jboss-as/clustered/jboss-as-4/jms-ds.xml
trunk/src/config/jboss-as/clustered/jboss-as-4/ra.xml
trunk/src/config/jboss-as/non-clustered/jboss-as-4/
trunk/src/config/jboss-as/non-clustered/jboss-as-4/jms-ds.xml
trunk/src/config/jboss-as/non-clustered/jboss-as-4/ra.xml
trunk/src/config/service/
trunk/src/config/service/jboss-service.xml
trunk/src/main/org/hornetq/integration/jboss/security/AS4SecurityActions.java
trunk/src/main/org/hornetq/service/
trunk/src/main/org/hornetq/service/HornetQFileConfigurationService.java
trunk/src/main/org/hornetq/service/HornetQFileConfigurationServiceMBean.java
trunk/src/main/org/hornetq/service/HornetQJMSStarterService.java
trunk/src/main/org/hornetq/service/HornetQJMSStarterServiceMBean.java
trunk/src/main/org/hornetq/service/HornetQStarterService.java
trunk/src/main/org/hornetq/service/HornetQStarterServiceMBean.java
trunk/src/main/org/hornetq/service/JBossASSecurityManagerService.java
trunk/src/main/org/hornetq/service/JBossASSecurityManagerServiceMBean.java
Modified:
trunk/build-hornetq.xml
trunk/build.xml
trunk/docs/quickstart-guide/en/installation.xml
trunk/docs/quickstart-guide/en/running.xml
trunk/docs/user-manual/en/using-server.xml
trunk/examples/javaee/common/build.xml
trunk/examples/javaee/hornetq-javaee-examples.iml
trunk/hornetq.iml
trunk/src/config/jboss-as/build.xml
trunk/src/main/org/hornetq/integration/jboss/security/JBossASSecurityManager.java
Log:
https://jira.jboss.org/jira/browse/HORNETQ-146 - added mbean support for jboss 4.x
servers
Modified: trunk/build-hornetq.xml
===================================================================
--- trunk/build-hornetq.xml 2009-10-29 03:26:58 UTC (rev 8164)
+++ trunk/build-hornetq.xml 2009-10-29 10:19:25 UTC (rev 8165)
@@ -67,6 +67,7 @@
<property name="ra.rar.name" value="hornetq-ra.rar"/>
<property name="netty.jar.name" value="netty.jar"/>
<property name="mc.jar.name" value="jboss-mc.jar"/>
+ <property name="service.sar.name"
value="hornetq-service.sar"/>
<property name="resources.jar.name"
value="hornetq-resources.jar"/>
<!--source and build dirs-->
@@ -76,6 +77,7 @@
<property name="build.jms.classes.dir"
value="${build.dir}/classes/jms"/>
<property name="build.transports.classes.dir"
value="${build.dir}/classes/transports"/>
<property name="build.jboss.integration.classes.dir"
value="${build.dir}/classes/jboss-integration"/>
+ <property name="build.service.classes.dir"
value="${build.dir}/classes/service"/>
<property name="build.bootstrap.classes.dir"
value="${build.dir}/classes/bootstrap"/>
<property name="build.logging.classes.dir"
value="${build.dir}/classes/logging"/>
<property name="build.ra.classes.dir"
value="${build.dir}/classes/ra"/>
@@ -90,6 +92,7 @@
<property name="src.config.trunk.clustered.dir"
value="${src.dir}/config/trunk/clustered"/>
<property name="src.config.jbossas.non-clustered.dir"
value="${src.dir}/config/jboss-as/non-clustered"/>
<property name="src.config.jbossas.clustered.dir"
value="${src.dir}/config/jboss-as/clustered"/>
+ <property name="src.config.service.dir"
value="${src.dir}/config/service"/>
<property name="src.schema.dir"
value="${src.config.dir}/common/schema"/>
<property name="src.bin.dir" value="${src.dir}/bin"/>
<property name="doc.dir" value="docs"/>
@@ -189,6 +192,12 @@
<path refid="org.jboss.integration.classpath"/>
<path refid="org.jboss.javaee.classpath"/>
</path>
+
+ <path id="jboss.service.compilation.classpath">
+ <path refid="org.jboss.javaee.classpath"/>
+ <path location="${build.core.classes.dir}"/>
+ <path location="${build.jboss.integration.classes.dir}"/>
+ </path>
<path id="bootstrap.compilation.classpath">
<path location="${build.core.classes.dir}"/>
@@ -339,6 +348,7 @@
<mkdir dir="${build.jms.classes.dir}"/>
<mkdir dir="${build.transports.classes.dir}"/>
<mkdir dir="${build.jboss.integration.classes.dir}"/>
+ <mkdir dir="${build.service.classes.dir}"/>
<mkdir dir="${build.bootstrap.classes.dir}"/>
<mkdir dir="${build.logging.classes.dir}"/>
<mkdir dir="${build.ra.classes.dir}"/>
@@ -466,6 +476,31 @@
<classpath refid="jboss.integration.compilation.classpath"/>
</javac>
</target>
+
+ <!-- author: Lucas Amador -->
+ <target name="compile-jboss-service"
depends="compile-core">
+ <javac destdir="${build.service.classes.dir}"
+ target="${javac.target}"
+ source="${javac.source}"
+ optimize="${javac.optimize}"
+ debug="${javac.debug}"
+ depend="${javac.depend}"
+ verbose="${javac.verbose}"
+ deprecation="${javac.deprecation}"
+ includeAntRuntime="${javac.include.ant.runtime}"
+ includeJavaRuntime="${javac.include.java.runtime}"
+ failonerror="${javac.fail.onerror}">
+ <src>
+ <pathelement path="${src.main.dir}"/>
+ </src>
+ <include name="org/hornetq/service/**/*.java"/>
+ <classpath refid="jboss.service.compilation.classpath"/>
+ </javac>
+ <copy file="${src.config.service.dir}/jboss-service.xml"
+ tofile="${build.service.classes.dir}/META-INF/jboss-service.xml"
overwrite="true" />
+ <!--<copy
file="${src.config.service.dir}/hornetq-configuration.xml"
+
tofile="${build.service.classes.dir}/META-INF/hornetq-configuration.xml"
overwrite="true" />-->
+ </target>
<target name="compile-bootstrap" depends="compile-core">
<javac destdir="${build.bootstrap.classes.dir}"
@@ -579,7 +614,7 @@
<!--
========================================================================================
-->
<target name="jar"
- depends="jar-core, jar-core-client, jar-jms, jar-jms-client,
jar-transports, jar-jboss-integration, jar-bootstrap, jar-logging, jar-ra, jar-mc,
jar-jnp-client">
+ depends="jar-core, jar-core-client, jar-jms, jar-jms-client,
jar-transports, jar-jboss-integration, jar-jboss-service, jar-bootstrap, jar-logging,
jar-ra, jar-mc, jar-jnp-client">
</target>
<target name="jar-jnp-client" depends="init">
@@ -662,7 +697,16 @@
</jar>
</target>
+
+ <!-- author: Lucas Amador -->
+ <target name="jar-jboss-service"
depends="compile-jboss-service">
+ <jar jarfile="${build.jars.dir}/${service.sar.name}">
+ <fileset dir="${build.service.classes.dir}"
includes="**"/>
+ </jar>
+
+ </target>
+
<target name="jar-bootstrap" depends="compile-bootstrap">
<jar jarfile="${build.jars.dir}/${bootstrap.jar.name}">
@@ -761,6 +805,7 @@
<include name="${jms.jar.name}"/>
<include name="${transports.jar.name}"/>
<include name="${jboss.integration.jar.name}"/>
+ <include name="${service.sar.name}"/>
<include name="${bootstrap.jar.name}"/>
<include name="${logging.jar.name}"/>
<include name="${mc.jar.name}"/>
Modified: trunk/build.xml
===================================================================
--- trunk/build.xml 2009-10-29 03:26:58 UTC (rev 8164)
+++ trunk/build.xml 2009-10-29 10:19:25 UTC (rev 8165)
@@ -139,6 +139,10 @@
<ant antfile="build-hornetq.xml"
target="jar-transports"/>
</target>
+ <target name="jar-jboss-service"
depends="createthirdparty">
+ <ant antfile="build-hornetq.xml"
target="jar-jboss-service"/>
+ </target>
+
<target name="jar-security" depends="createthirdparty">
<ant antfile="build-hornetq.xml" target="jar-security"/>
</target>
Modified: trunk/docs/quickstart-guide/en/installation.xml
===================================================================
--- trunk/docs/quickstart-guide/en/installation.xml 2009-10-29 03:26:58 UTC (rev 8164)
+++ trunk/docs/quickstart-guide/en/installation.xml 2009-10-29 10:19:25 UTC (rev 8165)
@@ -90,7 +90,7 @@
</listitem>
</itemizedlist>
</section>
- <section id="installation.jboss">
+ <section id="installation.jboss.as5">
<title>HornetQ In JBoss AS 5</title>
<para>HornetQ can be deployed in <ulink
url="http://www.jboss.org/jbossas/">JBoss AS
5</ulink>. It is not shipped by default with the application server and
you need to create
@@ -125,4 +125,41 @@
<para>You can then start JBoss AS 5 using one of these
profiles:</para>
<programlisting>$JBOSS_HOME/bin/run.sh -c
default-with-hornetq</programlisting>
</section>
+ <section id="installation.jboss.as4">
+ <title>HornetQ In JBoss AS 4</title>
+ <note>
+ <para>HornetQ can be deployed on AS 4 but isn't
recommended</para>
+ </note>
+ <para>As in AS 4, it is not shipped by default with the application server
and you need to create
+ new AS 4 profiles to run AS 4 with HornetQ.</para>
+ <para>To create AS 4 profiles:</para>
+ <orderedlist>
+ <listitem>
+ <para>Download JBoss AS 4</para>
+ </listitem>
+ <listitem>
+ <para>Set the environment property
<literal>JBOSS_HOME</literal> to point to the
+ directory where you installed JBoss AS 4</para>
+ </listitem>
+ <listitem>
+ <para>run <literal>ant as4</literal> in HornetQ's
<literal>config/jboss-as</literal>
+ directory</para>
+ </listitem>
+ </orderedlist>
+ <para>This will create 2 new profiles in
<literal>$JBOSS_HOME/server</literal>:</para>
+ <itemizedlist>
+ <listitem>
+ <para><literal>default-with-hornetq</literal> -- it
corresponds to AS 4 <literal
+ >default</literal> profile with HornetQ as its JMS provider.
In this profile,
+ HornetQ is <emphasis>non-clustered</emphasis></para>
+ </listitem>
+ <listitem>
+ <para><literal>all-with-hornetq</literal> -- it corresponds
to AS 4 <literal
+ >all</literal> profile with HornetQ as its JMS provider. In
this profile, HornetQ
+ is <emphasis>clustered</emphasis></para>
+ </listitem>
+ </itemizedlist>
+ <para>You can then start JBoss AS 4 using one of these
profiles:</para>
+ <programlisting>$JBOSS_HOME/bin/run.sh -c
default-with-hornetq</programlisting>
+ </section>
</chapter>
Modified: trunk/docs/quickstart-guide/en/running.xml
===================================================================
--- trunk/docs/quickstart-guide/en/running.xml 2009-10-29 03:26:58 UTC (rev 8164)
+++ trunk/docs/quickstart-guide/en/running.xml 2009-10-29 10:19:25 UTC (rev 8165)
@@ -40,10 +40,10 @@
by running <literal>./run.sh
../config/stand-alone/clustered</literal> or another config of
your choosing. This is the same for the stop script and the windows bat
files.</para>
</section>
- <section id="running.jboss.as">
+ <section id="running.jboss.as5">
<title>HornetQ In JBoss AS 5</title>
<para>To run HornetQ in JBoss AS 5, you need to create the <link
- linkend="installation.jboss">AS 5 profiles for
HornetQ</link> first. Then run
+ linkend="installation.jboss.as5">AS 5 profiles for
HornetQ</link> first. Then run
JBoss AS 5 with one these profiles. For example, to run JBoss AS 5 with a
<emphasis>non-clustered</emphasis> HornetQ server, got to
<literal
$JBOSS_HOME/bin</literal> directory and type:</para>
@@ -61,4 +61,10 @@
SVNTag=JBoss_5_1_0_CR1 date=200904091504)] Started in 1m:8s:121ms
</programlisting>
</section>
+ <section id="running.jboss.as4">
+ <title>HornetQ In JBoss AS 5</title>
+ <para>To run HornetQ in JBoss AS 4 you must follow the same steps
described for AS5 without forgetting to create the <link
+ linkend="installation.jboss.as4">AS 4 profiles for
HornetQ</link> first.
+ </para>
+ </section>
</chapter>
Modified: trunk/docs/user-manual/en/using-server.xml
===================================================================
--- trunk/docs/user-manual/en/using-server.xml 2009-10-29 03:26:58 UTC (rev 8164)
+++ trunk/docs/user-manual/en/using-server.xml 2009-10-29 10:19:25 UTC (rev 8165)
@@ -299,7 +299,7 @@
<para>HornetQServer</para>
<para>This is the core server. It's where 99% of the magic
happens</para>
</listitem>
- <listitem>
+ <listitem id="bean-jmsservermanager">
<para>JMSServerManager</para>
<para>This deploys any JMS Objects such as JMS Queues, Topics and
ConnectionFactory
instances from <literal>hornetq-jms.xml</literal> files
on the disk. It also
@@ -310,6 +310,69 @@
</listitem>
</itemizedlist>
</section>
+ <section id="server.microkernel.configuration">
+ <title>JBoss AS4 MBean Service.</title>
+ <note>
+ <para>The section is only to configure HornetQ on JBoss AS4. The
service funtionality is similar to Microcontainer Beans</para>
+ </note>
+ <para>
+ <programlisting><?xml version="1.0"
encoding="UTF-8"?>
+<server>
+
+ <mbean code="org.hornetq.service.HornetQFileConfigurationService"
+ name="org.hornetq:service=HornetQFileConfigurationService">
+ </mbean>
+
+ <mbean code="org.hornetq.service.JBossASSecurityManagerService"
+ name="org.hornetq:service=JBossASSecurityManagerService">
+ </mbean>
+
+ <mbean code="org.hornetq.service.HornetQStarterService"
+ name="org.hornetq:service=HornetQStarterService">
+ <!--lets let the JMS Server start us-->
+ <attribute name="Start">false</attribute>
+
+ <depends optional-attribute-name="SecurityManagerService"
+
proxy-type="attribute">org.hornetq:service=JBossASSecurityManagerService</depends>
+ <depends optional-attribute-name="ConfigurationService"
+
proxy-type="attribute">org.hornetq:service=HornetQFileConfigurationService</depends>
+ </mbean>
+
+ <mbean code="org.hornetq.service.HornetQJMSStarterService"
+ name="org.hornetq:service=HornetQJMSStarterService">
+ <depends optional-attribute-name="HornetQServer"
+
proxy-type="attribute">org.hornetq:service=HornetQStarterService</depends>
+ </mbean>
+
+</server>
+ </programlisting>
+ </para>
+ <para>This jboss-service.xml configuration file is included inside the
hornetq-service.sar on AS4 with embebbed HornetQ.
+ As you can see, on this configuration file we are starting various
services:</para>
+ <itemizedlist>
+ <listitem>
+ <para>HornetQFileConfigurationService</para>
+ <para>This services instances the configuration object that reads
the Configuration File
+ inside the SAR archive and configure the HornetQ instance.</para>
+ </listitem>
+ <listitem>
+ <para>JBossASSecurityManagerService</para>
+ <para>The service that starts the Security Manager as the
Microcontainer Bean.</para>
+ </listitem>
+ <listitem>
+ <para>HornetQStarterService</para>
+ <para>The HornetQ core server that depends on
JBossASSecurityManagerService and HornetQFileConfigurationService MBeans</para>
+ </listitem>
+ <listitem>
+ <para>HornetQJMSStarterService</para>
+ <para>This is the core server. It's where 99% of the magic
happens</para>
+ </listitem>
+ <listitem>
+ <para>JMSServerManager</para>
+ <para>Has the responsability to start the JMSServerManager and the
same behaviour that JMSServerManager Bean</para>
+ </listitem>
+ </itemizedlist>
+ </section>
<section id="usingserver.mainconfig">
<title>The main configuration file.</title>
<para>The configuration for the HornetQ core server is contained in
<literal
Modified: trunk/examples/javaee/common/build.xml
===================================================================
--- trunk/examples/javaee/common/build.xml 2009-10-29 03:26:58 UTC (rev 8164)
+++ trunk/examples/javaee/common/build.xml 2009-10-29 10:19:25 UTC (rev 8165)
@@ -50,6 +50,9 @@
<fileset dir="${hornetq.jars.dir}">
<include name="**/*.jar"/>
</fileset>
+ <fileset dir="${jars.dir}">
+ <include name="**/*.jar"/>
+ </fileset>
<fileset dir="${jboss.home}/client">
<include name="**/*.jar"/>
</fileset>
Added: trunk/examples/javaee/ejb-jms-transaction/config/META-INF/application.xml
===================================================================
--- trunk/examples/javaee/ejb-jms-transaction/config/META-INF/application.xml
(rev 0)
+++ trunk/examples/javaee/ejb-jms-transaction/config/META-INF/application.xml 2009-10-29
10:19:25 UTC (rev 8165)
@@ -0,0 +1,27 @@
+<!--
+ ~ Copyright 2009 Red Hat, Inc.
+ ~ Red Hat 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.
+ -->
+<application>
+ <display-name>My Application</display-name>
+
+ <module>
+ <web>
+ <web-uri>ejb-jms-transaction-example.war</web-uri>
+ <context-root>/hornetq</context-root>
+ </web>
+ </module>
+ <module>
+ <java>ejb-jms-transaction-example.jar</java>
+ </module>
+
+
+</application>
Added: trunk/examples/javaee/hajndi/config/META-INF/application.xml
===================================================================
--- trunk/examples/javaee/hajndi/config/META-INF/application.xml
(rev 0)
+++ trunk/examples/javaee/hajndi/config/META-INF/application.xml 2009-10-29 10:19:25 UTC
(rev 8165)
@@ -0,0 +1,27 @@
+<!--
+ ~ Copyright 2009 Red Hat, Inc.
+ ~ Red Hat 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.
+ -->
+<application>
+ <display-name>My Application</display-name>
+
+ <module>
+ <web>
+ <web-uri>hajndi-example.war</web-uri>
+ <context-root>/hornetq</context-root>
+ </web>
+ </module>
+ <module>
+ <java>hajndi-example.jar</java>
+ </module>
+
+
+</application>
Modified: trunk/examples/javaee/hornetq-javaee-examples.iml
===================================================================
--- trunk/examples/javaee/hornetq-javaee-examples.iml 2009-10-29 03:26:58 UTC (rev 8164)
+++ trunk/examples/javaee/hornetq-javaee-examples.iml 2009-10-29 10:19:25 UTC (rev 8165)
@@ -17,6 +17,8 @@
<sourceFolder url="file://$MODULE_DIR$/servlet-ssl-example/src"
isTestSource="false" />
<sourceFolder url="file://$MODULE_DIR$/servlet-transport/src"
isTestSource="false" />
<sourceFolder url="file://$MODULE_DIR$/xarecovery/src"
isTestSource="false" />
+ <excludeFolder url="file://$MODULE_DIR$/mdb-bmt/build" />
+ <excludeFolder url="file://$MODULE_DIR$/mdb-bmt/server" />
<excludeFolder url="file://$MODULE_DIR$/mdb-cmt-tx-required/build"
/>
<excludeFolder url="file://$MODULE_DIR$/output" />
<excludeFolder url="file://$MODULE_DIR$/servlet-ssl-example/build"
/>
Added: trunk/examples/javaee/jca-config/config/META-INF/application.xml
===================================================================
--- trunk/examples/javaee/jca-config/config/META-INF/application.xml
(rev 0)
+++ trunk/examples/javaee/jca-config/config/META-INF/application.xml 2009-10-29 10:19:25
UTC (rev 8165)
@@ -0,0 +1,27 @@
+<!--
+ ~ Copyright 2009 Red Hat, Inc.
+ ~ Red Hat 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.
+ -->
+<application>
+ <display-name>My Application</display-name>
+
+ <module>
+ <web>
+ <web-uri>jca-config-example.war</web-uri>
+ <context-root>/hornetq</context-root>
+ </web>
+ </module>
+ <module>
+ <java>jca-config-example.jar</java>
+ </module>
+
+
+</application>
Added: trunk/examples/javaee/jms-bridge/config/META-INF/application.xml
===================================================================
--- trunk/examples/javaee/jms-bridge/config/META-INF/application.xml
(rev 0)
+++ trunk/examples/javaee/jms-bridge/config/META-INF/application.xml 2009-10-29 10:19:25
UTC (rev 8165)
@@ -0,0 +1,27 @@
+<!--
+ ~ Copyright 2009 Red Hat, Inc.
+ ~ Red Hat 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.
+ -->
+<application>
+ <display-name>My Application</display-name>
+
+ <module>
+ <web>
+ <web-uri>jms-bridge-example.war</web-uri>
+ <context-root>/hornetq</context-root>
+ </web>
+ </module>
+ <module>
+ <java>jms-bridge-example.jar</java>
+ </module>
+
+
+</application>
Added: trunk/examples/javaee/mdb-bmt/config/META-INF/application.xml
===================================================================
--- trunk/examples/javaee/mdb-bmt/config/META-INF/application.xml
(rev 0)
+++ trunk/examples/javaee/mdb-bmt/config/META-INF/application.xml 2009-10-29 10:19:25 UTC
(rev 8165)
@@ -0,0 +1,27 @@
+<!--
+ ~ Copyright 2009 Red Hat, Inc.
+ ~ Red Hat 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.
+ -->
+<application>
+ <display-name>My Application</display-name>
+
+ <module>
+ <web>
+ <web-uri>mdb-bmt-example.war</web-uri>
+ <context-root>/hornetq</context-root>
+ </web>
+ </module>
+ <module>
+ <java>mdb-bmt-example.jar</java>
+ </module>
+
+
+</application>
Added: trunk/examples/javaee/mdb-cmt-setrollbackonly/config/META-INF/application.xml
===================================================================
--- trunk/examples/javaee/mdb-cmt-setrollbackonly/config/META-INF/application.xml
(rev 0)
+++
trunk/examples/javaee/mdb-cmt-setrollbackonly/config/META-INF/application.xml 2009-10-29
10:19:25 UTC (rev 8165)
@@ -0,0 +1,27 @@
+<!--
+ ~ Copyright 2009 Red Hat, Inc.
+ ~ Red Hat 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.
+ -->
+<application>
+ <display-name>My Application</display-name>
+
+ <module>
+ <web>
+ <web-uri>mdb-cmt-setrollbackonly-example.war</web-uri>
+ <context-root>/hornetq</context-root>
+ </web>
+ </module>
+ <module>
+ <java>mdb-cmt-setrollbackonly-example.jar</java>
+ </module>
+
+
+</application>
Added: trunk/examples/javaee/mdb-cmt-tx-local/config/META-INF/application.xml
===================================================================
--- trunk/examples/javaee/mdb-cmt-tx-local/config/META-INF/application.xml
(rev 0)
+++ trunk/examples/javaee/mdb-cmt-tx-local/config/META-INF/application.xml 2009-10-29
10:19:25 UTC (rev 8165)
@@ -0,0 +1,27 @@
+<!--
+ ~ Copyright 2009 Red Hat, Inc.
+ ~ Red Hat 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.
+ -->
+<application>
+ <display-name>My Application</display-name>
+
+ <module>
+ <web>
+ <web-uri>mdb-cmt-tx-local-example.war</web-uri>
+ <context-root>/hornetq</context-root>
+ </web>
+ </module>
+ <module>
+ <java>mdb-cmt-tx-local-example.jar</java>
+ </module>
+
+
+</application>
Added: trunk/examples/javaee/mdb-cmt-tx-not-supported/config/META-INF/application.xml
===================================================================
--- trunk/examples/javaee/mdb-cmt-tx-not-supported/config/META-INF/application.xml
(rev 0)
+++
trunk/examples/javaee/mdb-cmt-tx-not-supported/config/META-INF/application.xml 2009-10-29
10:19:25 UTC (rev 8165)
@@ -0,0 +1,27 @@
+<!--
+ ~ Copyright 2009 Red Hat, Inc.
+ ~ Red Hat 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.
+ -->
+<application>
+ <display-name>My Application</display-name>
+
+ <module>
+ <web>
+ <web-uri>mdb-cmt-tx-not-supported-example.war</web-uri>
+ <context-root>/hornetq</context-root>
+ </web>
+ </module>
+ <module>
+ <java>mdb-cmt-tx-not-supported-example.jar</java>
+ </module>
+
+
+</application>
Added: trunk/examples/javaee/mdb-cmt-tx-required/config/META-INF/application.xml
===================================================================
--- trunk/examples/javaee/mdb-cmt-tx-required/config/META-INF/application.xml
(rev 0)
+++ trunk/examples/javaee/mdb-cmt-tx-required/config/META-INF/application.xml 2009-10-29
10:19:25 UTC (rev 8165)
@@ -0,0 +1,27 @@
+<!--
+ ~ Copyright 2009 Red Hat, Inc.
+ ~ Red Hat 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.
+ -->
+<application>
+ <display-name>My Application</display-name>
+
+ <module>
+ <web>
+ <web-uri>mdb-cmt-tx-required-example.war</web-uri>
+ <context-root>/hornetq</context-root>
+ </web>
+ </module>
+ <module>
+ <java>mdb-cmt-tx-required-example.jar</java>
+ </module>
+
+
+</application>
Added: trunk/examples/javaee/mdb-message-selector/config/META-INF/application.xml
===================================================================
--- trunk/examples/javaee/mdb-message-selector/config/META-INF/application.xml
(rev 0)
+++ trunk/examples/javaee/mdb-message-selector/config/META-INF/application.xml 2009-10-29
10:19:25 UTC (rev 8165)
@@ -0,0 +1,27 @@
+<!--
+ ~ Copyright 2009 Red Hat, Inc.
+ ~ Red Hat 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.
+ -->
+<application>
+ <display-name>My Application</display-name>
+
+ <module>
+ <web>
+ <web-uri>mdb-message-selector-example.war</web-uri>
+ <context-root>/hornetq</context-root>
+ </web>
+ </module>
+ <module>
+ <java>mdb-message-selector-example.jar</java>
+ </module>
+
+
+</application>
Added: trunk/examples/javaee/mdb-tx-send/config/META-INF/application.xml
===================================================================
--- trunk/examples/javaee/mdb-tx-send/config/META-INF/application.xml
(rev 0)
+++ trunk/examples/javaee/mdb-tx-send/config/META-INF/application.xml 2009-10-29 10:19:25
UTC (rev 8165)
@@ -0,0 +1,27 @@
+<!--
+ ~ Copyright 2009 Red Hat, Inc.
+ ~ Red Hat 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.
+ -->
+<application>
+ <display-name>My Application</display-name>
+
+ <module>
+ <web>
+ <web-uri>mdb-tx-send-example.war</web-uri>
+ <context-root>/hornetq</context-root>
+ </web>
+ </module>
+ <module>
+ <java>mdb-tx-send-example.jar</java>
+ </module>
+
+
+</application>
Modified: trunk/hornetq.iml
===================================================================
--- trunk/hornetq.iml 2009-10-29 03:26:58 UTC (rev 8164)
+++ trunk/hornetq.iml 2009-10-29 10:19:25 UTC (rev 8165)
@@ -29,7 +29,9 @@
<excludeFolder url="file://$MODULE_DIR$/output/jar" />
<excludeFolder url="file://$MODULE_DIR$/output/lib" />
<excludeFolder url="file://$MODULE_DIR$/output/scoped-sar" />
+ <excludeFolder url="file://$MODULE_DIR$/production" />
<excludeFolder url="file://$MODULE_DIR$/release" />
+ <excludeFolder url="file://$MODULE_DIR$/test" />
<excludeFolder url="file://$MODULE_DIR$/tests/ObjectStore" />
<excludeFolder url="file://$MODULE_DIR$/tests/build" />
<excludeFolder url="file://$MODULE_DIR$/tests/jms-tests/build" />
Added: trunk/src/config/jboss-as/build-as4.xml
===================================================================
--- trunk/src/config/jboss-as/build-as4.xml (rev 0)
+++ trunk/src/config/jboss-as/build-as4.xml 2009-10-29 10:19:25 UTC (rev 8165)
@@ -0,0 +1,112 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+Copyright 2009 Red Hat, Inc.
+ Red Hat 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.
+ -->
+<!-- author: Lucas Amador -->
+<project default="default" name="HornetQ integration with JBoss AS
4">
+ <property environment="ENV"/>
+ <property name="jboss.home" value="${ENV.JBOSS_HOME}"/>
+ <property name="src.bin.dir" value="../../bin"/>
+ <property name="dest.bin.dir" value="${jboss.home}/bin"/>
+ <property name="lib.dir" value="../../lib"/>
+
+ <target name="default" description="Create JBoss AS 4 profiles to
use HornetQ">
+ <antcall target="create-profile">
+ <!-- created from JBoss AS 4 default profile -->
+ <param name="jbossas.profile.source" value="default"/>
+ <!-- based on HornetQ jbossas/non-clustered config -->
+ <param name="hornetq.config.dir"
value="./non-clustered"/>
+ <!-- new profile is named default-with-hornetq -->
+ <param name="hornetq.profile.target"
value="default-with-hornetq"/>
+ </antcall>
+ <antcall target="create-profile">
+ <!-- created from JBoss AS 4 all profile -->
+ <param name="jbossas.profile.source" value="all"/>
+ <!-- based on HornetQ jbossas/clustered config -->
+ <param name="hornetq.config.dir" value="clustered"/>
+ <!-- new profile is named all-with-hornetq -->
+ <param name="hornetq.profile.target"
value="all-with-hornetq"/>
+ </antcall>
+ <mkdir dir="${dest.bin.dir}/META-INF/lib/linux2/x86"/>
+ <mkdir dir="${dest.bin.dir}/META-INF/lib/linux2/x64"/>
+ <mkdir dir="${dest.bin.dir}/META-INF/lib/linux2/i64"/>
+ <copy todir="${dest.bin.dir}/META-INF/lib/linux2/x86"
file="${src.bin.dir}/libHornetQAIO32.so"/>
+ <copy todir="${dest.bin.dir}/META-INF/lib/linux2/x64"
file="${src.bin.dir}/libHornetQAIO64.so"/>
+ <copy todir="${dest.bin.dir}/META-INF/lib/linux2/i64"
file="${src.bin.dir}/libHornetQAIO_ia64.so"/>
+ </target>
+
+ <target name="create-profile">
+ <antcall target="validate-jboss"/>
+ <property name="src.dir"
value="${jboss.home}/server/${jbossas.profile.source}"/>
+ <property name="dest.dir"
value="${jboss.home}/server/${hornetq.profile.target}"/>
+
+ <mkdir dir="${dest.dir}"/>
+ <copy todir="${dest.dir}">
+ <fileset dir="${src.dir}">
+ <exclude name="**/messaging/**"/>
+ <exclude name="conf/login-config.xml"/>
+ <exclude name="**/jms-ra.rar"/>
+ <exclude name="**/jms/" />
+ </fileset>
+ </copy>
+ <copy todir="${dest.dir}/conf">
+ <fileset dir="${hornetq.config.dir}">
+ <include name="login-config.xml"/>
+ </fileset>
+ </copy>
+ <copy todir="${dest.dir}/conf/props">
+ <fileset dir="${hornetq.config.dir}">
+ <include name="hornetq-users.properties"/>
+ <include name="hornetq-roles.properties"/>
+ </fileset>
+ </copy>
+ <copy todir="${dest.dir}/lib">
+ <fileset dir="${lib.dir}">
+ <include name="hornetq-*.jar"/>
+ <include name="netty*.jar"/>
+ </fileset>
+ </copy>
+
+ <property name="hornetq.sar.dir"
value="${dest.dir}/deploy/hornetq.sar"/>
+
+ <unzip src="${lib.dir}/hornetq-service.sar"
dest="${hornetq.sar.dir}"/>
+ <copy todir="${hornetq.sar.dir}">
+ <fileset dir="${hornetq.config.dir}">
+ <include name="hornetq-configuration.xml" />
+ <include name="hornetq-jms.xml" />
+ </fileset>
+ </copy>
+ <copy todir="${hornetq.sar.dir}"
file="${hornetq.config.dir}/jboss-as-4/jms-ds.xml"/>
+
+ <property name="jms-ra.rar.dir"
value="${dest.dir}/deploy/jms-ra.rar"/>
+ <unzip src="${lib.dir}/hornetq-ra.rar"
dest="${jms-ra.rar.dir}"/>
+ <copy todir="${jms-ra.rar.dir}/META-INF/"
file="${hornetq.config.dir}/jboss-as-4/ra.xml"/>
+ <copy todir="${jms-ra.rar.dir}">
+ <fileset dir="${lib.dir}">
+ <include name="hornetq-transports.jar"/>
+ <include name="netty*.jar"/>
+ </fileset>
+ </copy>
+
+ </target>
+
+ <!-- The JBOSS_HOME environment variable and the directory must exist -->
+ <target name="validate-jboss">
+ <fail unless="ENV.JBOSS_HOME" message="JBOSS_HOME environment
variable not set! Set it and try again."/>
+ <available property="source-profile" type="dir"
file="${jboss.home}/server/${jbossas.profile.source}"/>
+ <fail unless="source-profile"
message="${jboss.home}/server/${jbossas.profile.source} profile not
found!"/>
+ <available property="target-profile" type="dir"
file="${jboss.home}/server/${hornetq.profile.target}"/>
+ <fail if="target-profile"
+ message="'${hornetq.profile.target}' profile already exists!
Delete it manually and try again."/>
+ </target>
+
+</project>
Added: trunk/src/config/jboss-as/build-as5.xml
===================================================================
--- trunk/src/config/jboss-as/build-as5.xml (rev 0)
+++ trunk/src/config/jboss-as/build-as5.xml 2009-10-29 10:19:25 UTC (rev 8165)
@@ -0,0 +1,95 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+Copyright 2009 Red Hat, Inc.
+ Red Hat 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.
+ -->
+<project default="default" name="HornetQ integration with JBoss AS
5">
+ <property environment="ENV"/>
+ <property name="jboss.home" value="${ENV.JBOSS_HOME}"/>
+ <property name="src.bin.dir" value="../../bin"/>
+ <property name="dest.bin.dir" value="${jboss.home}/bin"/>
+ <property name="lib.dir" value="../../lib"/>
+
+ <target name="default" description="Create JBoss AS 5 profiles to
use HornetQ">
+ <antcall target="create-profile">
+ <!-- created from JBoss AS 5 default profile -->
+ <param name="jbossas.profile.source" value="default"/>
+ <!-- based on HornetQ jbossas/non-clustered config -->
+ <param name="hornetq.config.dir"
value="./non-clustered"/>
+ <!-- new profile is named default-with-hornetq -->
+ <param name="hornetq.profile.target"
value="default-with-hornetq"/>
+ </antcall>
+ <antcall target="create-profile">
+ <!-- created from JBoss AS 5 all profile -->
+ <param name="jbossas.profile.source" value="all"/>
+ <!-- based on HornetQ jbossas/clustered config -->
+ <param name="hornetq.config.dir" value="clustered"/>
+ <!-- new profile is named all-with-hornetq -->
+ <param name="hornetq.profile.target"
value="all-with-hornetq"/>
+ </antcall>
+ <mkdir dir="${dest.bin.dir}/META-INF/lib/linux2/x86"/>
+ <mkdir dir="${dest.bin.dir}/META-INF/lib/linux2/x64"/>
+ <mkdir dir="${dest.bin.dir}/META-INF/lib/linux2/i64"/>
+ <copy todir="${dest.bin.dir}/META-INF/lib/linux2/x86"
file="${src.bin.dir}/libHornetQAIO32.so"/>
+ <copy todir="${dest.bin.dir}/META-INF/lib/linux2/x64"
file="${src.bin.dir}/libHornetQAIO64.so"/>
+ <copy todir="${dest.bin.dir}/META-INF/lib/linux2/i64"
file="${src.bin.dir}/libHornetQAIO_ia64.so"/>
+ </target>
+
+ <target name="create-profile">
+ <antcall target="validate-jboss"/>
+ <property name="src.dir"
value="${jboss.home}/server/${jbossas.profile.source}"/>
+ <property name="dest.dir"
value="${jboss.home}/server/${hornetq.profile.target}"/>
+
+ <mkdir dir="${dest.dir}"/>
+ <copy todir="${dest.dir}">
+ <fileset dir="${src.dir}">
+ <exclude name="**/messaging/**"/>
+ <exclude name="conf/login-config.xml"/>
+ <!--<exclude name="**/jms-ra.rar"/>-->
+ </fileset>
+ </copy>
+ <copy todir="${dest.dir}/conf">
+ <fileset dir="${hornetq.config.dir}">
+ <include name="login-config.xml"/>
+ </fileset>
+ </copy>
+ <copy todir="${dest.dir}/conf/props">
+ <fileset dir="${hornetq.config.dir}">
+ <include name="hornetq-users.properties"/>
+ <include name="hornetq-roles.properties"/>
+ </fileset>
+ </copy>
+ <copy todir="${dest.dir}/lib">
+ <fileset dir="${lib.dir}">
+ <include name="hornetq-*.jar"/>
+ <include name="netty*.jar"/>
+ </fileset>
+ </copy>
+ <property name="hornetq.sar.dir"
value="${dest.dir}/deploy/hornetq.sar"/>
+ <mkdir dir="${hornetq.sar.dir}"/>
+ <copy todir="${hornetq.sar.dir}">
+ <fileset dir="${hornetq.config.dir}" includes="*"
excludes="**/jboss-as-4/**"/>
+ </copy>
+ <unzip src="${lib.dir}/hornetq-ra.rar"
dest="${dest.dir}/deploy/hornetq-ra.rar"/>
+ </target>
+
+ <!-- The JBOSS_HOME environment variable and the directory must exist, we also
check we are running
+ in JBoss 5.1 or later -->
+ <target name="validate-jboss">
+ <fail unless="ENV.JBOSS_HOME" message="JBOSS_HOME environment
variable not set! Set it and try again."/>
+ <available property="source-profile" type="dir"
file="${jboss.home}/server/${jbossas.profile.source}"/>
+ <fail unless="source-profile"
message="${jboss.home}/server/${jbossas.profile.source} profile not
found!"/>
+ <available property="target-profile" type="dir"
file="${jboss.home}/server/${hornetq.profile.target}"/>
+ <fail if="target-profile"
+ message="'${hornetq.profile.target}' profile already exists!
Delete it manually and try again."/>
+ </target>
+
+</project>
Modified: trunk/src/config/jboss-as/build.xml
===================================================================
--- trunk/src/config/jboss-as/build.xml 2009-10-29 03:26:58 UTC (rev 8164)
+++ trunk/src/config/jboss-as/build.xml 2009-10-29 10:19:25 UTC (rev 8165)
@@ -11,85 +11,14 @@
implied. See the License for the specific language governing
permissions and limitations under the License.
-->
-<project default="default" name="HornetQ integration with JBoss AS
5">
- <property environment="ENV"/>
- <property name="jboss.home" value="${ENV.JBOSS_HOME}"/>
- <property name="src.bin.dir" value="../../bin"/>
- <property name="dest.bin.dir" value="${jboss.home}/bin"/>
- <property name="lib.dir" value="../../lib"/>
+<project default="as5" name="HornetQ integration with JBoss AS
4/5">
- <target name="default" description="Create JBoss AS 5 profiles to
use HornetQ">
- <antcall target="create-profile">
- <!-- created from JBoss AS 5 default profile -->
- <param name="jbossas.profile.source" value="default"/>
- <!-- based on HornetQ jbossas/non-clustered config -->
- <param name="hornetq.config.dir"
value="./non-clustered"/>
- <!-- new profile is named default-with-hornetq -->
- <param name="hornetq.profile.target"
value="default-with-hornetq"/>
- </antcall>
- <antcall target="create-profile">
- <!-- created from JBoss AS 5 all profile -->
- <param name="jbossas.profile.source" value="all"/>
- <!-- based on HornetQ jbossas/clustered config -->
- <param name="hornetq.config.dir" value="clustered"/>
- <!-- new profile is named all-with-hornetq -->
- <param name="hornetq.profile.target"
value="all-with-hornetq"/>
- </antcall>
- <mkdir dir="${dest.bin.dir}/META-INF/lib/linux2/x86"/>
- <mkdir dir="${dest.bin.dir}/META-INF/lib/linux2/x64"/>
- <mkdir dir="${dest.bin.dir}/META-INF/lib/linux2/i64"/>
- <copy todir="${dest.bin.dir}/META-INF/lib/linux2/x86"
file="${src.bin.dir}/libHornetQAIO32.so"/>
- <copy todir="${dest.bin.dir}/META-INF/lib/linux2/x64"
file="${src.bin.dir}/libHornetQAIO64.so"/>
- <copy todir="${dest.bin.dir}/META-INF/lib/linux2/i64"
file="${src.bin.dir}/libHornetQAIO_ia64.so"/>
+ <target name="as4">
+ <ant antfile="build-as4.xml" target="default"/>
</target>
- <target name="create-profile">
- <antcall target="validate-jboss"/>
- <property name="src.dir"
value="${jboss.home}/server/${jbossas.profile.source}"/>
- <property name="dest.dir"
value="${jboss.home}/server/${hornetq.profile.target}"/>
-
- <mkdir dir="${dest.dir}"/>
- <copy todir="${dest.dir}">
- <fileset dir="${src.dir}">
- <exclude name="**/messaging/**"/>
- <exclude name="conf/login-config.xml"/>
- <!--<exclude name="**/jms-ra.rar"/>-->
- </fileset>
- </copy>
- <copy todir="${dest.dir}/conf">
- <fileset dir="${hornetq.config.dir}">
- <include name="login-config.xml"/>
- </fileset>
- </copy>
- <copy todir="${dest.dir}/conf/props">
- <fileset dir="${hornetq.config.dir}">
- <include name="hornetq-users.properties"/>
- <include name="hornetq-roles.properties"/>
- </fileset>
- </copy>
- <copy todir="${dest.dir}/lib">
- <fileset dir="${lib.dir}">
- <include name="hornetq-*.jar"/>
- <include name="netty*.jar"/>
- </fileset>
- </copy>
- <property name="hornetq.sar.dir"
value="${dest.dir}/deploy/hornetq.sar"/>
- <mkdir dir="${hornetq.sar.dir}"/>
- <copy todir="${hornetq.sar.dir}">
- <fileset dir="${hornetq.config.dir}" includes="*"/>
- </copy>
- <unzip src="${lib.dir}/hornetq-ra.rar"
dest="${dest.dir}/deploy/hornetq-ra.rar"/>
+ <target name="as5">
+ <ant antfile="build-as5.xml" target="default"/>
</target>
-
- <!-- The JBOSS_HOME environment variable and the directory must exist, we also
check we are running
- in JBoss 5.1 or later -->
- <target name="validate-jboss">
- <fail unless="ENV.JBOSS_HOME" message="JBOSS_HOME environment
variable not set! Set it and try again."/>
- <available property="source-profile" type="dir"
file="${jboss.home}/server/${jbossas.profile.source}"/>
- <fail unless="source-profile"
message="${jboss.home}/server/${jbossas.profile.source} profile not
found!"/>
- <available property="target-profile" type="dir"
file="${jboss.home}/server/${hornetq.profile.target}"/>
- <fail if="target-profile"
- message="'${hornetq.profile.target}' profile already exists!
Delete it manually and try again."/>
- </target>
-
+
</project>
Added: trunk/src/config/jboss-as/clustered/jboss-as-4/jms-ds.xml
===================================================================
--- trunk/src/config/jboss-as/clustered/jboss-as-4/jms-ds.xml (rev
0)
+++ trunk/src/config/jboss-as/clustered/jboss-as-4/jms-ds.xml 2009-10-29 10:19:25 UTC (rev
8165)
@@ -0,0 +1,32 @@
+<connection-factories>
+ <!--
+ JMS Stuff
+ -->
+
+ <mbean code="org.jboss.jms.jndi.JMSProviderLoader"
name="hornetq:service=JMSProviderLoader,name=JMSProvider">
+ <attribute
name="ProviderName">DefaultJMSProvider</attribute>
+ <attribute
name="ProviderAdapterClass">org.jboss.jms.jndi.JNDIProviderAdapter</attribute>
+ <attribute
name="FactoryRef">java:/XAConnectionFactory</attribute>
+ <attribute
name="QueueFactoryRef">java:/XAConnectionFactory</attribute>
+ <attribute
name="TopicFactoryRef">java:/XAConnectionFactory</attribute>
+ <attribute name="Properties">
+ java.naming.factory.initial=org.jnp.interfaces.NamingContextFactory
+ java.naming.factory.url.pkgs=org.jnp.interfaces
+ java.naming.provider.url=localhost:1199
+ </attribute>
+
+ </mbean>
+ <!--
+ JMS XA Resource adapter, use this to get transacted JMS in beans
+ -->
+ <tx-connection-factory>
+ <jndi-name>JmsXA</jndi-name>
+ <xa-transaction/>
+ <rar-name>jms-ra.rar</rar-name>
+
<connection-definition>org.hornetq.ra.HornetQRAConnectionFactory</connection-definition>
+ <config-property name="SessionDefaultType"
type="java.lang.String">javax.jms.Topic</config-property>
+ <config-property name="JmsProviderAdapterJNDI"
type="java.lang.String">java:/DefaultJMSProvider</config-property>
+ <max-pool-size>20</max-pool-size>
+
<security-domain-and-application>JmsXARealm</security-domain-and-application>
+ </tx-connection-factory>
+</connection-factories>
Added: trunk/src/config/jboss-as/clustered/jboss-as-4/ra.xml
===================================================================
--- trunk/src/config/jboss-as/clustered/jboss-as-4/ra.xml (rev 0)
+++ trunk/src/config/jboss-as/clustered/jboss-as-4/ra.xml 2009-10-29 10:19:25 UTC (rev
8165)
@@ -0,0 +1,286 @@
+<?xml version="1.0" encoding="UTF-8"?>
+
+<!-- $Id: ra.xml 76819 2008-08-08 11:04:20Z jesper.pedersen $ -->
+
+<connector
xmlns="http://java.sun.com/xml/ns/j2ee"
+
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+
xsi:schemaLocation="http://java.sun.com/xml/ns/j2ee
+
http://java.sun.com/xml/ns/j2ee/connector_1_5.xsd"
+ version="1.5">
+
+ <description>HornetQ 2.0 Resource Adapter</description>
+ <display-name>HornetQ 2.0 Resource Adapter</display-name>
+
+ <vendor-name>Red Hat Middleware LLC</vendor-name>
+ <eis-type>JMS 1.1 Server</eis-type>
+ <resourceadapter-version>1.0</resourceadapter-version>
+
+ <license>
+ <description>
+Copyright 2009 Red Hat, Inc.
+ Red Hat 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.
+ </description>
+ <license-required>true</license-required>
+ </license>
+
+ <resourceadapter>
+
<resourceadapter-class>org.hornetq.ra.HornetQResourceAdapter</resourceadapter-class>
+ <config-property>
+ <description>The transport type</description>
+ <config-property-name>ConnectorClassName</config-property-name>
+ <config-property-type>java.lang.String</config-property-type>
+
<config-property-value>org.hornetq.integration.transports.netty.NettyConnectorFactory</config-property-value>
+ </config-property>
+ <config-property>
+ <description>The transport configuration. These values must be in the form
of key=val;key=val;</description>
+ <config-property-name>ConnectionParameters</config-property-name>
+ <config-property-type>java.lang.String</config-property-type>
+
<config-property-value>hornetq.remoting.netty.host=localhost;hornetq.remoting.netty.port=5445</config-property-value>
+ </config-property>
+ <config-property>
+ <description>Use XA?</description>
+ <config-property-name>UseXA</config-property-name>
+ <config-property-type>java.lang.Boolean</config-property-type>
+ <config-property-value>true</config-property-value>
+ </config-property>
+ <!--
+ <config-property>
+ <description>The method to use for locatingthe
transactionmanager</description>
+
<config-property-name>TransactionManagerLocatorMethod</config-property-name>
+ <config-property-type>java.lang.String</config-property-type>
+ <config-property-value>getTm</config-property-value>
+ </config-property>
+ <config-property>
+ <description>Use A local Transaction instead of XA?</description>
+ <config-property-name>UseLocalTx</config-property-name>
+ <config-property-type>java.lang.Boolean</config-property-type>
+ <config-property-value>false</config-property-value>
+ </config-property>
+ <config-property>
+ <description>The user name used to login to the JMS
server</description>
+ <config-property-name>UserName</config-property-name>
+ <config-property-type>java.lang.String</config-property-type>
+ <config-property-value></config-property-value>
+ </config-property>
+ <config-property>
+ <description>The password used to login to the JMS
server</description>
+ <config-property-name>Password</config-property-name>
+ <config-property-type>java.lang.String</config-property-type>
+ <config-property-value></config-property-value>
+ </config-property>
+ <config-property>
+ <description>The Backup transport type</description>
+ <config-property-name>BackUpTransportType</config-property-name>
+ <config-property-type>java.lang.String</config-property-type>
+ <config-property-value></config-property-value>
+ </config-property>
+ <config-property>
+ <description>The Backup transport configuration. These values must be in
the form of key=val;key=val;</description>
+ <config-property-name>TransportConfiguration</config-property-name>
+ <config-property-type>java.lang.String</config-property-type>
+ <config-property-value></config-property-value>
+ </config-property>
+ <config-property>
+ <description>The discovery group address</description>
+ <config-property-name>DiscoveryGroupAddress</config-property-name>
+ <config-property-type>java.lang.String</config-property-type>
+ <config-property-value></config-property-value>
+ </config-property>
+ <config-property>
+ <description>The discovery group port</description>
+ <config-property-name>DiscoveryGroupPort</config-property-name>
+ <config-property-type>java.lang.Integer</config-property-type>
+ <config-property-value></config-property-value>
+ </config-property>
+ <config-property>
+ <description>The discovery refresh timeout</description>
+ <config-property-name>DiscoveryRefreshTimeout</config-property-name>
+ <config-property-type>java.lang.Long</config-property-type>
+ <config-property-value></config-property-value>
+ </config-property>
+ <config-property>
+ <description>The discovery initial wait timeout</description>
+
<config-property-name>DiscoveryInitialWaitTimeout</config-property-name>
+ <config-property-type>java.lang.Long</config-property-type>
+ <config-property-value></config-property-value>
+ </config-property>
+ <config-property>
+ <description>The load balancing policy class name</description>
+
<config-property-name>LoadBalancingPolicyClassName</config-property-name>
+ <config-property-type>java.lang.String</config-property-type>
+ <config-property-value></config-property-value>
+ </config-property>
+ <config-property>
+ <description>The client failure check period</description>
+
<config-property-name>ClientFailureCheckPeriod</config-property-name>
+ <config-property-type>java.lang.Long</config-property-type>
+ <config-property-value></config-property-value>
+ </config-property>
+ <config-property>
+ <description>The connection TTL</description>
+ <config-property-name>ConnectionTTL</config-property-name>
+ <config-property-type>java.lang.Long</config-property-type>
+ <config-property-value></config-property-value>
+ </config-property>
+ <config-property>
+ <description>The call timeout</description>
+ <config-property-name>CallTimeout</config-property-name>
+ <config-property-type>java.lang.Long</config-property-type>
+ <config-property-value></config-property-value>
+ </config-property>
+ <config-property>
+ <description>The dups ok batch size</description>
+ <config-property-name>DupsOKBatchSize</config-property-name>
+ <config-property-type>java.lang.Integer</config-property-type>
+ <config-property-value></config-property-value>
+ </config-property>
+ <config-property>
+ <description>The transaction batch size</description>
+ <config-property-name>TransactionBatchSize</config-property-name>
+ <config-property-type>java.lang.Integer</config-property-type>
+ <config-property-value></config-property-value>
+ </config-property>
+ <config-property>
+ <description>The consumer window size</description>
+ <config-property-name>ConsumerWindowSize</config-property-name>
+ <config-property-type>java.lang.Integer</config-property-type>
+ <config-property-value></config-property-value>
+ </config-property>
+ <config-property>
+ <description>The consumer max rate</description>
+ <config-property-name>ConsumerMaxRate</config-property-name>
+ <config-property-type>java.lang.Integer</config-property-type>
+ <config-property-value></config-property-value>
+ </config-property>
+ <config-property>
+ <description>The producer window size</description>
+ <config-property-name>ProducerWindowSize</config-property-name>
+ <config-property-type>java.lang.Integer</config-property-type>
+ <config-property-value></config-property-value>
+ </config-property>
+ <config-property>
+ <description>The producer max rate</description>
+ <config-property-name>ProducerMaxRate</config-property-name>
+ <config-property-type>java.lang.Integer</config-property-type>
+ <config-property-value></config-property-value>
+ </config-property>
+ <config-property>
+ <description>The min large message size</description>
+ <config-property-name>MinLargeMessageSize</config-property-name>
+ <config-property-type>java.lang.Integer</config-property-type>
+ <config-property-value></config-property-value>
+ </config-property>
+ <config-property>
+ <description>The block on acknowledge</description>
+ <config-property-name>BlockOnAcknowledge</config-property-name>
+ <config-property-type>java.lang.Boolean</config-property-type>
+ <config-property-value></config-property-value>
+ </config-property>
+ <config-property>
+ <description>The block on non persistent send</description>
+
<config-property-name>BlockOnNonPersistentSend</config-property-name>
+ <config-property-type>java.lang.Boolean</config-property-type>
+ <config-property-value></config-property-value>
+ </config-property>
+ <config-property>
+ <description>The block on persistent send</description>
+ <config-property-name>BlockOnPersistentSend</config-property-name>
+ <config-property-type>java.lang.Boolean</config-property-type>
+ <config-property-value></config-property-value>
+ </config-property>
+ <config-property>
+ <description>The auto group</description>
+ <config-property-name>AutoGroup</config-property-name>
+ <config-property-type>java.lang.Boolean</config-property-type>
+ <config-property-value></config-property-value>
+ </config-property>
+ <config-property>
+ <description>The max connections</description>
+ <config-property-type>java.lang.Integer</config-property-type>
+ <config-property-value></config-property-value>
+ </config-property>
+ <config-property>
+ <description>The pre acknowledge</description>
+ <config-property-name>PreAcknowledge</config-property-name>
+ <config-property-type>java.lang.Boolean</config-property-type>
+ <config-property-value></config-property-value>
+ </config-property>
+ <config-property>
+ <description>The retry interval</description>
+ <config-property-name>RetryInterval</config-property-name>
+ <config-property-type>java.lang.Long</config-property-type>
+ <config-property-value></config-property-value>
+ </config-property>
+ <config-property>
+ <description>The retry interval multiplier</description>
+ <config-property-name>RetryIntervalMultiplier</config-property-name>
+ <config-property-type>java.lang.Double</config-property-type>
+ <config-property-value></config-property-value>
+ </config-property>
+ <config-property>
+ <description>Should clean server shutdown trigger
failover?</description>
+
<config-property-name>FailoverOnServerShutdown</config-property-name>
+ <config-property-type>java.lang.Boolean</config-property-type>
+ <config-property-value></config-property-value>
+ </config-property>
+ <config-property>
+ <description>The client id</description>
+ <config-property-name>ClientID</config-property-name>
+ <config-property-type>java.lang.String</config-property-type>
+ <config-property-value></config-property-value>
+ </config-property>-->
+
+ <outbound-resourceadapter>
+ <connection-definition>
+
<managedconnectionfactory-class>org.hornetq.ra.HornetQRAManagedConnectionFactory</managedconnectionfactory-class>
+
+ <config-property>
+ <description>The default session type</description>
+
<config-property-name>SessionDefaultType</config-property-name>
+ <config-property-type>java.lang.String</config-property-type>
+
<config-property-value>javax.jms.Queue</config-property-value>
+ </config-property>
+ <config-property>
+ <description>Try to obtain a lock within specified number of
seconds; less than or equal to 0 disable this functionality</description>
+ <config-property-name>UseTryLock</config-property-name>
+
<config-property-type>java.lang.Integer</config-property-type>
+ <config-property-value>0</config-property-value>
+ </config-property>
+
+
<connectionfactory-interface>org.hornetq.ra.HornetQRAConnectionFactory</connectionfactory-interface>
+
<connectionfactory-impl-class>org.hornetq.ra.HornetQRAConnectionFactoryImpl</connectionfactory-impl-class>
+ <connection-interface>javax.jms.Session</connection-interface>
+
<connection-impl-class>org.hornetq.ra.HornetQRASession</connection-impl-class>
+ </connection-definition>
+ <transaction-support>XATransaction</transaction-support>
+ <authentication-mechanism>
+
<authentication-mechanism-type>BasicPassword</authentication-mechanism-type>
+
<credential-interface>javax.resource.spi.security.PasswordCredential</credential-interface>
+ </authentication-mechanism>
+ <reauthentication-support>false</reauthentication-support>
+ </outbound-resourceadapter>
+
+ <inbound-resourceadapter>
+ <messageadapter>
+ <messagelistener>
+
<messagelistener-type>javax.jms.MessageListener</messagelistener-type>
+ <activationspec>
+
<activationspec-class>org.hornetq.ra.inflow.HornetQActivationSpec</activationspec-class>
+ <required-config-property>
+
<config-property-name>destination</config-property-name>
+ </required-config-property>
+ </activationspec>
+ </messagelistener>
+ </messageadapter>
+ </inbound-resourceadapter>
+
+ </resourceadapter>
+</connector>
Added: trunk/src/config/jboss-as/non-clustered/jboss-as-4/jms-ds.xml
===================================================================
--- trunk/src/config/jboss-as/non-clustered/jboss-as-4/jms-ds.xml
(rev 0)
+++ trunk/src/config/jboss-as/non-clustered/jboss-as-4/jms-ds.xml 2009-10-29 10:19:25 UTC
(rev 8165)
@@ -0,0 +1,26 @@
+<connection-factories>
+ <!--
+ JMS Stuff
+ -->
+
+ <mbean code="org.jboss.jms.jndi.JMSProviderLoader"
name="hornetq:service=JMSProviderLoader,name=JMSProvider">
+ <attribute
name="ProviderName">DefaultJMSProvider</attribute>
+ <attribute
name="ProviderAdapterClass">org.jboss.jms.jndi.JNDIProviderAdapter</attribute>
+ <attribute
name="FactoryRef">java:/XAConnectionFactory</attribute>
+ <attribute
name="QueueFactoryRef">java:/XAConnectionFactory</attribute>
+ <attribute
name="TopicFactoryRef">java:/XAConnectionFactory</attribute>
+ </mbean>
+ <!--
+ JMS XA Resource adapter, use this to get transacted JMS in beans
+ -->
+ <tx-connection-factory>
+ <jndi-name>JmsXA</jndi-name>
+ <xa-transaction/>
+ <rar-name>jms-ra.rar</rar-name>
+
<connection-definition>org.hornetq.ra.HornetQRAConnectionFactory</connection-definition>
+ <config-property name="SessionDefaultType"
type="java.lang.String">javax.jms.Topic</config-property>
+ <config-property name="JmsProviderAdapterJNDI"
type="java.lang.String">java:/DefaultJMSProvider</config-property>
+ <max-pool-size>20</max-pool-size>
+
<security-domain-and-application>JmsXARealm</security-domain-and-application>
+ </tx-connection-factory>
+</connection-factories>
Added: trunk/src/config/jboss-as/non-clustered/jboss-as-4/ra.xml
===================================================================
--- trunk/src/config/jboss-as/non-clustered/jboss-as-4/ra.xml (rev
0)
+++ trunk/src/config/jboss-as/non-clustered/jboss-as-4/ra.xml 2009-10-29 10:19:25 UTC (rev
8165)
@@ -0,0 +1,286 @@
+<?xml version="1.0" encoding="UTF-8"?>
+
+<!-- $Id: ra.xml 76819 2008-08-08 11:04:20Z jesper.pedersen $ -->
+
+<connector
xmlns="http://java.sun.com/xml/ns/j2ee"
+
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+
xsi:schemaLocation="http://java.sun.com/xml/ns/j2ee
+
http://java.sun.com/xml/ns/j2ee/connector_1_5.xsd"
+ version="1.5">
+
+ <description>HornetQ 2.0 Resource Adapter</description>
+ <display-name>HornetQ 2.0 Resource Adapter</display-name>
+
+ <vendor-name>Red Hat Middleware LLC</vendor-name>
+ <eis-type>JMS 1.1 Server</eis-type>
+ <resourceadapter-version>1.0</resourceadapter-version>
+
+ <license>
+ <description>
+Copyright 2009 Red Hat, Inc.
+ Red Hat 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.
+ </description>
+ <license-required>true</license-required>
+ </license>
+
+ <resourceadapter>
+
<resourceadapter-class>org.hornetq.ra.HornetQResourceAdapter</resourceadapter-class>
+ <config-property>
+ <description>The transport type</description>
+ <config-property-name>ConnectorClassName</config-property-name>
+ <config-property-type>java.lang.String</config-property-type>
+
<config-property-value>org.hornetq.integration.transports.netty.NettyConnectorFactory</config-property-value>
+ </config-property>
+ <config-property>
+ <description>The transport configuration. These values must be in the form
of key=val;key=val;</description>
+ <config-property-name>ConnectionParameters</config-property-name>
+ <config-property-type>java.lang.String</config-property-type>
+
<config-property-value>hornetq.remoting.netty.host=localhost;hornetq.remoting.netty.port=5445</config-property-value>
+ </config-property>
+ <config-property>
+ <description>Use XA?</description>
+ <config-property-name>UseXA</config-property-name>
+ <config-property-type>java.lang.Boolean</config-property-type>
+ <config-property-value>true</config-property-value>
+ </config-property>
+ <!--
+ <config-property>
+ <description>The method to use for locatingthe
transactionmanager</description>
+
<config-property-name>TransactionManagerLocatorMethod</config-property-name>
+ <config-property-type>java.lang.String</config-property-type>
+ <config-property-value>getTm</config-property-value>
+ </config-property>
+ <config-property>
+ <description>Use A local Transaction instead of XA?</description>
+ <config-property-name>UseLocalTx</config-property-name>
+ <config-property-type>java.lang.Boolean</config-property-type>
+ <config-property-value>false</config-property-value>
+ </config-property>
+ <config-property>
+ <description>The user name used to login to the JMS
server</description>
+ <config-property-name>UserName</config-property-name>
+ <config-property-type>java.lang.String</config-property-type>
+ <config-property-value></config-property-value>
+ </config-property>
+ <config-property>
+ <description>The password used to login to the JMS
server</description>
+ <config-property-name>Password</config-property-name>
+ <config-property-type>java.lang.String</config-property-type>
+ <config-property-value></config-property-value>
+ </config-property>
+ <config-property>
+ <description>The Backup transport type</description>
+ <config-property-name>BackUpTransportType</config-property-name>
+ <config-property-type>java.lang.String</config-property-type>
+ <config-property-value></config-property-value>
+ </config-property>
+ <config-property>
+ <description>The Backup transport configuration. These values must be in
the form of key=val;key=val;</description>
+ <config-property-name>TransportConfiguration</config-property-name>
+ <config-property-type>java.lang.String</config-property-type>
+ <config-property-value></config-property-value>
+ </config-property>
+ <config-property>
+ <description>The discovery group address</description>
+ <config-property-name>DiscoveryGroupAddress</config-property-name>
+ <config-property-type>java.lang.String</config-property-type>
+ <config-property-value></config-property-value>
+ </config-property>
+ <config-property>
+ <description>The discovery group port</description>
+ <config-property-name>DiscoveryGroupPort</config-property-name>
+ <config-property-type>java.lang.Integer</config-property-type>
+ <config-property-value></config-property-value>
+ </config-property>
+ <config-property>
+ <description>The discovery refresh timeout</description>
+ <config-property-name>DiscoveryRefreshTimeout</config-property-name>
+ <config-property-type>java.lang.Long</config-property-type>
+ <config-property-value></config-property-value>
+ </config-property>
+ <config-property>
+ <description>The discovery initial wait timeout</description>
+
<config-property-name>DiscoveryInitialWaitTimeout</config-property-name>
+ <config-property-type>java.lang.Long</config-property-type>
+ <config-property-value></config-property-value>
+ </config-property>
+ <config-property>
+ <description>The load balancing policy class name</description>
+
<config-property-name>LoadBalancingPolicyClassName</config-property-name>
+ <config-property-type>java.lang.String</config-property-type>
+ <config-property-value></config-property-value>
+ </config-property>
+ <config-property>
+ <description>The client failure check period</description>
+
<config-property-name>ClientFailureCheckPeriod</config-property-name>
+ <config-property-type>java.lang.Long</config-property-type>
+ <config-property-value></config-property-value>
+ </config-property>
+ <config-property>
+ <description>The connection TTL</description>
+ <config-property-name>ConnectionTTL</config-property-name>
+ <config-property-type>java.lang.Long</config-property-type>
+ <config-property-value></config-property-value>
+ </config-property>
+ <config-property>
+ <description>The call timeout</description>
+ <config-property-name>CallTimeout</config-property-name>
+ <config-property-type>java.lang.Long</config-property-type>
+ <config-property-value></config-property-value>
+ </config-property>
+ <config-property>
+ <description>The dups ok batch size</description>
+ <config-property-name>DupsOKBatchSize</config-property-name>
+ <config-property-type>java.lang.Integer</config-property-type>
+ <config-property-value></config-property-value>
+ </config-property>
+ <config-property>
+ <description>The transaction batch size</description>
+ <config-property-name>TransactionBatchSize</config-property-name>
+ <config-property-type>java.lang.Integer</config-property-type>
+ <config-property-value></config-property-value>
+ </config-property>
+ <config-property>
+ <description>The consumer window size</description>
+ <config-property-name>ConsumerWindowSize</config-property-name>
+ <config-property-type>java.lang.Integer</config-property-type>
+ <config-property-value></config-property-value>
+ </config-property>
+ <config-property>
+ <description>The consumer max rate</description>
+ <config-property-name>ConsumerMaxRate</config-property-name>
+ <config-property-type>java.lang.Integer</config-property-type>
+ <config-property-value></config-property-value>
+ </config-property>
+ <config-property>
+ <description>The producer window size</description>
+ <config-property-name>ProducerWindowSize</config-property-name>
+ <config-property-type>java.lang.Integer</config-property-type>
+ <config-property-value></config-property-value>
+ </config-property>
+ <config-property>
+ <description>The producer max rate</description>
+ <config-property-name>ProducerMaxRate</config-property-name>
+ <config-property-type>java.lang.Integer</config-property-type>
+ <config-property-value></config-property-value>
+ </config-property>
+ <config-property>
+ <description>The min large message size</description>
+ <config-property-name>MinLargeMessageSize</config-property-name>
+ <config-property-type>java.lang.Integer</config-property-type>
+ <config-property-value></config-property-value>
+ </config-property>
+ <config-property>
+ <description>The block on acknowledge</description>
+ <config-property-name>BlockOnAcknowledge</config-property-name>
+ <config-property-type>java.lang.Boolean</config-property-type>
+ <config-property-value></config-property-value>
+ </config-property>
+ <config-property>
+ <description>The block on non persistent send</description>
+
<config-property-name>BlockOnNonPersistentSend</config-property-name>
+ <config-property-type>java.lang.Boolean</config-property-type>
+ <config-property-value></config-property-value>
+ </config-property>
+ <config-property>
+ <description>The block on persistent send</description>
+ <config-property-name>BlockOnPersistentSend</config-property-name>
+ <config-property-type>java.lang.Boolean</config-property-type>
+ <config-property-value></config-property-value>
+ </config-property>
+ <config-property>
+ <description>The auto group</description>
+ <config-property-name>AutoGroup</config-property-name>
+ <config-property-type>java.lang.Boolean</config-property-type>
+ <config-property-value></config-property-value>
+ </config-property>
+ <config-property>
+ <description>The max connections</description>
+ <config-property-type>java.lang.Integer</config-property-type>
+ <config-property-value></config-property-value>
+ </config-property>
+ <config-property>
+ <description>The pre acknowledge</description>
+ <config-property-name>PreAcknowledge</config-property-name>
+ <config-property-type>java.lang.Boolean</config-property-type>
+ <config-property-value></config-property-value>
+ </config-property>
+ <config-property>
+ <description>The retry interval</description>
+ <config-property-name>RetryInterval</config-property-name>
+ <config-property-type>java.lang.Long</config-property-type>
+ <config-property-value></config-property-value>
+ </config-property>
+ <config-property>
+ <description>The retry interval multiplier</description>
+ <config-property-name>RetryIntervalMultiplier</config-property-name>
+ <config-property-type>java.lang.Double</config-property-type>
+ <config-property-value></config-property-value>
+ </config-property>
+ <config-property>
+ <description>Should clean server shutdown trigger
failover?</description>
+
<config-property-name>FailoverOnServerShutdown</config-property-name>
+ <config-property-type>java.lang.Boolean</config-property-type>
+ <config-property-value></config-property-value>
+ </config-property>
+ <config-property>
+ <description>The client id</description>
+ <config-property-name>ClientID</config-property-name>
+ <config-property-type>java.lang.String</config-property-type>
+ <config-property-value></config-property-value>
+ </config-property>-->
+
+ <outbound-resourceadapter>
+ <connection-definition>
+
<managedconnectionfactory-class>org.hornetq.ra.HornetQRAManagedConnectionFactory</managedconnectionfactory-class>
+
+ <config-property>
+ <description>The default session type</description>
+
<config-property-name>SessionDefaultType</config-property-name>
+ <config-property-type>java.lang.String</config-property-type>
+
<config-property-value>javax.jms.Queue</config-property-value>
+ </config-property>
+ <config-property>
+ <description>Try to obtain a lock within specified number of
seconds; less than or equal to 0 disable this functionality</description>
+ <config-property-name>UseTryLock</config-property-name>
+
<config-property-type>java.lang.Integer</config-property-type>
+ <config-property-value>0</config-property-value>
+ </config-property>
+
+
<connectionfactory-interface>org.hornetq.ra.HornetQRAConnectionFactory</connectionfactory-interface>
+
<connectionfactory-impl-class>org.hornetq.ra.HornetQRAConnectionFactoryImpl</connectionfactory-impl-class>
+ <connection-interface>javax.jms.Session</connection-interface>
+
<connection-impl-class>org.hornetq.ra.HornetQRASession</connection-impl-class>
+ </connection-definition>
+ <transaction-support>XATransaction</transaction-support>
+ <authentication-mechanism>
+
<authentication-mechanism-type>BasicPassword</authentication-mechanism-type>
+
<credential-interface>javax.resource.spi.security.PasswordCredential</credential-interface>
+ </authentication-mechanism>
+ <reauthentication-support>false</reauthentication-support>
+ </outbound-resourceadapter>
+
+ <inbound-resourceadapter>
+ <messageadapter>
+ <messagelistener>
+
<messagelistener-type>javax.jms.MessageListener</messagelistener-type>
+ <activationspec>
+
<activationspec-class>org.hornetq.ra.inflow.HornetQActivationSpec</activationspec-class>
+ <required-config-property>
+
<config-property-name>destination</config-property-name>
+ </required-config-property>
+ </activationspec>
+ </messagelistener>
+ </messageadapter>
+ </inbound-resourceadapter>
+
+ </resourceadapter>
+</connector>
Added: trunk/src/config/service/jboss-service.xml
===================================================================
--- trunk/src/config/service/jboss-service.xml (rev 0)
+++ trunk/src/config/service/jboss-service.xml 2009-10-29 10:19:25 UTC (rev 8165)
@@ -0,0 +1,42 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ ~ Copyright 2009 Red Hat, Inc.
+ ~ Red Hat 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.
+ -->
+
+<server>
+
+ <mbean code="org.hornetq.service.HornetQFileConfigurationService"
+ name="org.hornetq:service=HornetQFileConfigurationService">
+ </mbean>
+
+ <mbean code="org.hornetq.service.JBossASSecurityManagerService"
+ name="org.hornetq:service=JBossASSecurityManagerService">
+ </mbean>
+
+ <mbean code="org.hornetq.service.HornetQStarterService"
+ name="org.hornetq:service=HornetQStarterService">
+ <!--lets let the JMS Server start us-->
+ <attribute name="Start">false</attribute>
+
+ <depends optional-attribute-name="SecurityManagerService"
+
proxy-type="attribute">org.hornetq:service=JBossASSecurityManagerService</depends>
+ <depends optional-attribute-name="ConfigurationService"
+
proxy-type="attribute">org.hornetq:service=HornetQFileConfigurationService</depends>
+ </mbean>
+
+ <mbean code="org.hornetq.service.HornetQJMSStarterService"
+ name="org.hornetq:service=HornetQJMSStarterService">
+ <depends optional-attribute-name="HornetQServer"
+
proxy-type="attribute">org.hornetq:service=HornetQStarterService</depends>
+ </mbean>
+
+</server>
Added: trunk/src/main/org/hornetq/integration/jboss/security/AS4SecurityActions.java
===================================================================
--- trunk/src/main/org/hornetq/integration/jboss/security/AS4SecurityActions.java
(rev 0)
+++
trunk/src/main/org/hornetq/integration/jboss/security/AS4SecurityActions.java 2009-10-29
10:19:25 UTC (rev 8165)
@@ -0,0 +1,129 @@
+/*
+ * Copyright 2009 Red Hat, Inc.
+ * Red Hat 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.hornetq.integration.jboss.security;
+
+import java.security.AccessController;
+import java.security.Principal;
+import java.security.PrivilegedAction;
+
+import javax.security.auth.Subject;
+
+import org.jboss.security.SecurityAssociation;
+
+
+/** A collection of privileged actions for this package
+ * @author Scott.Stark(a)jboss.org
+ * @author <a href="mailto:alex@jboss.org">Alexey Loubyansky</a>
+ * @author <a href="mailto:tim.fox@jboss.com">Tim Fox</a>
+ * @author <a href="mailto:anil.saldhana@jboss.com">anil
saldhana</a>
+ * @version $Revison: 1.0$
+ */
+
+/**
+ * @author <a href="mailto:andy.taylor@jboss.org">Andy Taylor</a>
+ * Created Oct 21, 2009
+ */
+public class AS4SecurityActions
+{
+ interface PrincipalInfoAction
+ {
+ PrincipalInfoAction PRIVILEGED = new PrincipalInfoAction()
+ {
+ public void push(final Principal principal, final Object credential,
+ final Subject subject)
+ {
+ AccessController.doPrivileged(
+ new PrivilegedAction()
+ {
+ public Object run()
+ {
+ SecurityAssociation.pushSubjectContext(subject, principal,
credential);
+ return null;
+ }
+ }
+ );
+ }
+ public void dup()
+ {
+ AccessController.doPrivileged(
+ new PrivilegedAction()
+ {
+ public Object run()
+ {
+ SecurityAssociation.dupSubjectContext();
+ return null;
+ }
+ }
+ );
+ }
+ public void pop()
+ {
+ AccessController.doPrivileged(
+ new PrivilegedAction()
+ {
+ public Object run()
+ {
+ SecurityAssociation.popSubjectContext();
+ return null;
+ }
+ }
+ );
+ }
+ };
+
+ PrincipalInfoAction NON_PRIVILEGED = new PrincipalInfoAction()
+ {
+ public void push(Principal principal, Object credential, Subject subject)
+ {
+ SecurityAssociation.pushSubjectContext(subject, principal, credential);
+ }
+ public void dup()
+ {
+ SecurityAssociation.dupSubjectContext();
+ }
+ public void pop()
+ {
+ SecurityAssociation.popSubjectContext();
+ }
+ };
+
+ void push(Principal principal, Object credential, Subject subject);
+ void dup();
+ void pop();
+ }
+
+ static void pushSubjectContext(Principal principal, Object credential,
+ Subject subject)
+ {
+ if(System.getSecurityManager() == null)
+ {
+ PrincipalInfoAction.NON_PRIVILEGED.push(principal, credential, subject);
+ }
+ else
+ {
+ PrincipalInfoAction.PRIVILEGED.push(principal, credential, subject);
+ }
+ }
+
+ static void popSubjectContext()
+ {
+ if(System.getSecurityManager() == null)
+ {
+ PrincipalInfoAction.NON_PRIVILEGED.pop();
+ }
+ else
+ {
+ PrincipalInfoAction.PRIVILEGED.pop();
+ }
+ }
+}
Modified:
trunk/src/main/org/hornetq/integration/jboss/security/JBossASSecurityManager.java
===================================================================
---
trunk/src/main/org/hornetq/integration/jboss/security/JBossASSecurityManager.java 2009-10-29
03:26:58 UTC (rev 8164)
+++
trunk/src/main/org/hornetq/integration/jboss/security/JBossASSecurityManager.java 2009-10-29
10:19:25 UTC (rev 8165)
@@ -62,7 +62,8 @@
private String securityDomainName = "java:/jaas/hornetq";
private boolean started;
-
+ private boolean isAs5 = true;
+
public boolean validateUser(final String user, final String password)
{
SimplePrincipal principal = new SimplePrincipal(user);
@@ -99,7 +100,7 @@
// security my be screwed up, on account of thread local security stack being
corrupted.
if (authenticated)
{
- SecurityActions.pushSubjectContext(principal, passwordChars, subject,
securityDomainName);
+ pushSecurityContext(principal, passwordChars, subject);
Set<Principal> rolePrincipals = getRolePrincipals(checkType, roles);
authenticated = realmMapping.doesUserHaveRole(principal, rolePrincipals);
@@ -108,11 +109,35 @@
{
log.trace("user " + user + (authenticated ? " is " :
" is NOT ") + "authorized");
}
- SecurityActions.popSubjectContext();
+ popSecurityContext();
}
return authenticated;
}
-
+
+ private void popSecurityContext()
+ {
+ if(isAs5)
+ {
+ SecurityActions.popSubjectContext();
+ }
+ else
+ {
+ AS4SecurityActions.popSubjectContext();
+ }
+ }
+
+ private void pushSecurityContext(SimplePrincipal principal, char[] passwordChars,
Subject subject)
+ {
+ if(isAs5)
+ {
+ SecurityActions.pushSubjectContext(principal, passwordChars, subject,
securityDomainName);
+ }
+ else
+ {
+ AS4SecurityActions.pushSubjectContext(principal, passwordChars, subject);
+ }
+ }
+
public void addRole(String user, String role)
{
// NO-OP
@@ -198,4 +223,9 @@
{
this.securityDomainName = securityDomainName;
}
+
+ public void setAs5(boolean as5)
+ {
+ isAs5 = as5;
+ }
}
Added: trunk/src/main/org/hornetq/service/HornetQFileConfigurationService.java
===================================================================
--- trunk/src/main/org/hornetq/service/HornetQFileConfigurationService.java
(rev 0)
+++ trunk/src/main/org/hornetq/service/HornetQFileConfigurationService.java 2009-10-29
10:19:25 UTC (rev 8165)
@@ -0,0 +1,50 @@
+/*
+ * Copyright 2009 Red Hat, Inc.
+ * Red Hat 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.hornetq.service;
+
+import org.hornetq.core.config.impl.FileConfiguration;
+import org.hornetq.core.config.Configuration;
+
+/**
+ * @author <a href="mailto:andy.taylor@jboss.org">Andy Taylor</a>
+ * Created Oct 21, 2009
+ */
+public class HornetQFileConfigurationService implements
HornetQFileConfigurationServiceMBean
+{
+ private FileConfiguration configuration;
+
+ public void create() throws Exception
+ {
+ configuration = new FileConfiguration();
+ }
+
+ public void start() throws Exception
+ {
+ configuration.start();
+ }
+
+ public void stop() throws Exception
+ {
+ configuration.stop();
+ }
+
+ public void setConfigurationUrl(final String configurationUrl)
+ {
+ configuration.setConfigurationUrl(configurationUrl);
+ }
+
+ public Configuration getConfiguration()
+ {
+ return configuration;
+ }
+}
Added: trunk/src/main/org/hornetq/service/HornetQFileConfigurationServiceMBean.java
===================================================================
--- trunk/src/main/org/hornetq/service/HornetQFileConfigurationServiceMBean.java
(rev 0)
+++
trunk/src/main/org/hornetq/service/HornetQFileConfigurationServiceMBean.java 2009-10-29
10:19:25 UTC (rev 8165)
@@ -0,0 +1,20 @@
+package org.hornetq.service;
+
+import org.hornetq.core.config.Configuration;
+
+/**
+ * @author <a href="mailto:andy.taylor@jboss.org">Andy Taylor</a>
+ * Created Oct 21, 2009
+ */
+public interface HornetQFileConfigurationServiceMBean
+{
+ void create() throws Exception;
+
+ void start() throws Exception;
+
+ void stop() throws Exception;
+
+ void setConfigurationUrl(String configurationUrl);
+
+ Configuration getConfiguration();
+}
Added: trunk/src/main/org/hornetq/service/HornetQJMSStarterService.java
===================================================================
--- trunk/src/main/org/hornetq/service/HornetQJMSStarterService.java
(rev 0)
+++ trunk/src/main/org/hornetq/service/HornetQJMSStarterService.java 2009-10-29 10:19:25
UTC (rev 8165)
@@ -0,0 +1,45 @@
+/*
+ * Copyright 2009 Red Hat, Inc.
+ * Red Hat 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.hornetq.service;
+
+import org.hornetq.jms.server.impl.JMSServerManagerImpl;
+
+/**
+ * @author <a href="mailto:andy.taylor@jboss.org">Andy Taylor</a>
+ * Created Oct 19, 2009
+ */
+public class HornetQJMSStarterService implements HornetQJMSStarterServiceMBean
+{
+ HornetQStarterServiceMBean service;
+
+ private JMSServerManagerImpl jmsServerManager;
+
+ public void create() throws Exception
+ {
+ jmsServerManager = new JMSServerManagerImpl(service.getServer());
+ }
+ public void start() throws Exception
+ {
+ jmsServerManager.start();
+ }
+
+ public void stop() throws Exception
+ {
+ jmsServerManager.stop();
+ }
+
+ public void setHornetQServer(HornetQStarterServiceMBean service)
+ {
+ this.service = service;
+ }
+}
Added: trunk/src/main/org/hornetq/service/HornetQJMSStarterServiceMBean.java
===================================================================
--- trunk/src/main/org/hornetq/service/HornetQJMSStarterServiceMBean.java
(rev 0)
+++ trunk/src/main/org/hornetq/service/HornetQJMSStarterServiceMBean.java 2009-10-29
10:19:25 UTC (rev 8165)
@@ -0,0 +1,16 @@
+package org.hornetq.service;
+
+
+/**
+ * @author <a href="mailto:andy.taylor@jboss.org">Andy Taylor</a>
+ */
+public interface HornetQJMSStarterServiceMBean
+{
+ void create() throws Exception;
+
+ public void start() throws Exception;
+
+ public void stop() throws Exception;
+
+ void setHornetQServer(HornetQStarterServiceMBean server);
+}
Added: trunk/src/main/org/hornetq/service/HornetQStarterService.java
===================================================================
--- trunk/src/main/org/hornetq/service/HornetQStarterService.java
(rev 0)
+++ trunk/src/main/org/hornetq/service/HornetQStarterService.java 2009-10-29 10:19:25 UTC
(rev 8165)
@@ -0,0 +1,118 @@
+/*
+ * Copyright 2009 Red Hat, Inc.
+ * Red Hat 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.hornetq.service;
+
+import org.hornetq.core.config.impl.ConfigurationImpl;
+import org.hornetq.core.config.Configuration;
+import org.hornetq.core.server.HornetQServer;
+import org.hornetq.core.server.impl.HornetQServerImpl;
+import org.hornetq.core.security.HornetQSecurityManager;
+
+import javax.management.MBeanServer;
+import javax.management.MBeanRegistration;
+import javax.management.ObjectName;
+
+/**
+ * @author <a href="mailto:lucazamador@gmail.com">Lucaz Amador</a>
+ * @author <a href="mailto:andy.taylor@jboss.org">Andy Taylor</a>
+ */
+public class HornetQStarterService implements HornetQStarterServiceMBean,
MBeanRegistration
+{
+ JBossASSecurityManagerServiceMBean securityManagerService;
+
+ HornetQFileConfigurationServiceMBean configurationService;
+
+ private MBeanServer mBeanServer;
+
+ private HornetQServer server;
+
+ private boolean start = true;
+
+ public void create() throws Exception
+ {
+ Configuration config;
+ HornetQSecurityManager hornetQSecurityManager = null;
+ if(securityManagerService != null)
+ {
+ hornetQSecurityManager = securityManagerService.getJBossASSecurityManager();
+ }
+ if(configurationService != null)
+ {
+ config = configurationService.getConfiguration();
+ }
+ else
+ {
+ config = new ConfigurationImpl();
+ }
+ server = new HornetQServerImpl(config, mBeanServer, hornetQSecurityManager);
+ }
+
+ public void start() throws Exception
+ {
+ if(start)
+ {
+ server.start();
+ }
+ }
+
+ public void stop() throws Exception
+ {
+ if(start)
+ {
+ server.stop();
+ }
+ }
+
+ public HornetQServer getServer()
+ {
+ return server;
+ }
+
+ public void setStart(boolean start)
+ {
+ this.start = start;
+ }
+
+ public void setSecurityManagerService(JBossASSecurityManagerServiceMBean
securityManagerService)
+ {
+ this.securityManagerService = securityManagerService;
+ }
+
+ public void setConfigurationService(HornetQFileConfigurationServiceMBean
configurationService)
+ {
+ this.configurationService = configurationService;
+ }
+
+ public ObjectName preRegister(MBeanServer server, ObjectName name) throws Exception
+ {
+ this.mBeanServer = server;
+
+ return name;
+ }
+
+ public void postRegister(Boolean registrationDone)
+ {
+ // NO - OP
+ }
+
+ public void preDeregister() throws Exception
+ {
+ // NO - OP
+ }
+
+ public void postDeregister()
+ {
+ server = null;
+ mBeanServer = null;
+ }
+}
Added: trunk/src/main/org/hornetq/service/HornetQStarterServiceMBean.java
===================================================================
--- trunk/src/main/org/hornetq/service/HornetQStarterServiceMBean.java
(rev 0)
+++ trunk/src/main/org/hornetq/service/HornetQStarterServiceMBean.java 2009-10-29 10:19:25
UTC (rev 8165)
@@ -0,0 +1,36 @@
+/*
+ * Copyright 2009 Red Hat, Inc.
+ * Red Hat 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.hornetq.service;
+
+import org.hornetq.core.server.HornetQServer;
+
+/**
+ * @author <a href="mailto:lucazamador@gmail.com">Lucaz Amador</a>
+ * @author <a href="mailto:andy.taylor@jboss.org">Andy Taylor</a>
+ */
+public interface HornetQStarterServiceMBean
+{
+ void create() throws Exception;
+
+ public void start() throws Exception;
+
+ public void stop() throws Exception;
+
+ HornetQServer getServer();
+
+ void setStart(boolean start);
+
+ void setSecurityManagerService(JBossASSecurityManagerServiceMBean
securityManagerService);
+
+ void setConfigurationService(HornetQFileConfigurationServiceMBean
configurationService);
+}
Added: trunk/src/main/org/hornetq/service/JBossASSecurityManagerService.java
===================================================================
--- trunk/src/main/org/hornetq/service/JBossASSecurityManagerService.java
(rev 0)
+++ trunk/src/main/org/hornetq/service/JBossASSecurityManagerService.java 2009-10-29
10:19:25 UTC (rev 8165)
@@ -0,0 +1,35 @@
+/*
+ * Copyright 2009 Red Hat, Inc.
+ * Red Hat 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.hornetq.service;
+
+import org.hornetq.integration.jboss.security.JBossASSecurityManager;
+
+/**
+ * @author <a href="mailto:andy.taylor@jboss.org">Andy Taylor</a>
+ * Created Oct 20, 2009
+ */
+public class JBossASSecurityManagerService implements JBossASSecurityManagerServiceMBean
+{
+ private JBossASSecurityManager jBossASSecurityManager;
+
+ public void create()
+ {
+ jBossASSecurityManager = new JBossASSecurityManager();
+ jBossASSecurityManager.setAs5(false);
+ }
+
+ public JBossASSecurityManager getJBossASSecurityManager()
+ {
+ return jBossASSecurityManager;
+ }
+}
Added: trunk/src/main/org/hornetq/service/JBossASSecurityManagerServiceMBean.java
===================================================================
--- trunk/src/main/org/hornetq/service/JBossASSecurityManagerServiceMBean.java
(rev 0)
+++ trunk/src/main/org/hornetq/service/JBossASSecurityManagerServiceMBean.java 2009-10-29
10:19:25 UTC (rev 8165)
@@ -0,0 +1,14 @@
+package org.hornetq.service;
+
+import org.hornetq.integration.jboss.security.JBossASSecurityManager;
+
+/**
+ * @author <a href="mailto:andy.taylor@jboss.org">Andy Taylor</a>
+ * Created Oct 20, 2009
+ */
+public interface JBossASSecurityManagerServiceMBean
+{
+ void create();
+
+ JBossASSecurityManager getJBossASSecurityManager();
+}