[jboss-svn-commits] JBL Code SVN: r34481 - in labs/jbossesb/trunk/product/samples/quickstarts: jms_secured and 1 other directory.

jboss-svn-commits at lists.jboss.org jboss-svn-commits at lists.jboss.org
Tue Aug 3 09:40:03 EDT 2010


Author: tfennelly
Date: 2010-08-03 09:40:02 -0400 (Tue, 03 Aug 2010)
New Revision: 34481

Added:
   labs/jbossesb/trunk/product/samples/quickstarts/jms_secured/no-service.xml
Modified:
   labs/jbossesb/trunk/product/samples/quickstarts/conf/deployment-xml.xsl
   labs/jbossesb/trunk/product/samples/quickstarts/jms_secured/build.xml
   labs/jbossesb/trunk/product/samples/quickstarts/jms_secured/deployment.xml
   labs/jbossesb/trunk/product/samples/quickstarts/jms_secured/readme.txt
Log:
https://jira.jboss.org/browse/JBESB-3421
Update the jms_secured quickstart to work with hornetq

Modified: labs/jbossesb/trunk/product/samples/quickstarts/conf/deployment-xml.xsl
===================================================================
--- labs/jbossesb/trunk/product/samples/quickstarts/conf/deployment-xml.xsl	2010-08-03 12:40:28 UTC (rev 34480)
+++ labs/jbossesb/trunk/product/samples/quickstarts/conf/deployment-xml.xsl	2010-08-03 13:40:02 UTC (rev 34481)
@@ -25,6 +25,14 @@
 		</xsl:choose>
 	</xsl:template>
 
+	<xsl:template match="jmsSecurityManager">
+		<xsl:choose>
+			<xsl:when test="$jmsProvider = 'jbm' or $jmsProvider = 'jbmq' ">
+				<depends><xsl:value-of select='.'/></depends>
+			</xsl:when>
+		</xsl:choose>
+	</xsl:template>
+
 	<!-- Copy everything else... -->
 	<xsl:template match="@*|node()">	
 		<xsl:copy>

Modified: labs/jbossesb/trunk/product/samples/quickstarts/jms_secured/build.xml
===================================================================
--- labs/jbossesb/trunk/product/samples/quickstarts/jms_secured/build.xml	2010-08-03 12:40:28 UTC (rev 34480)
+++ labs/jbossesb/trunk/product/samples/quickstarts/jms_secured/build.xml	2010-08-03 13:40:02 UTC (rev 34481)
@@ -5,8 +5,7 @@
 		${line.separator}
 	</description>
 
-	<property name="additional.deploys" value="messaging-db-users-service.xml" />
-    <target name="quickstart-specific-assemblies" depends="filter"/>
+    <target name="quickstart-specific-assemblies" depends="filter" />
 
 	<target name="filter">
 		<property name="password.file" value="${basedir}/jmssecured.password"/>
@@ -18,9 +17,34 @@
         </copy>
 	</target>
 
+    <target name="package-deployment" depends="jbm-msg-users,jbmq-msg-users,hornetq-msg-users">
+    	<!-- Overridden the base task as part of https://jira.jboss.org/browse/JBESB-3421 -->
+    	<!-- Could probably have generalised this a little better, but didn't want to risk breaking other quickstarts. -->
+    	
+	    <mkdir dir="lib"/>
+        <jar destfile="${build.dir}/${ant.project.name}.esb">
+                   <fileset dir="${build.dir}/classes" excludes="${quickstart.classes.excludes}" includes="${quickstart.classes.includes}"/>
+                   <fileset dir="${build.dir}" includes="*.jar,*.war"/>
+                   <fileset dir="${build.dir}" includes="deployment.xml"/>
+                   <fileset dir="${build.dir}" includes="META-INF/**" />
+                   <fileset dir="${basedir}/src" excludes="**/*.java" /> <!-- Please leave the src dir in here! -->
+                   <fileset dir="${basedir}" includes="${jms.service.file} ${no.service.file} ${msg-users}" excludes="build/**" />
+                   <fileset dir="${basedir}/lib" includes="*.jar"/>
+        </jar>
+    </target>	
+	<target name="jbm-msg-users" if="messaging.present">
+		<property name="msg-users" value="messaging-db-users-service.xml" />
+	</target>
+	<target name="jbmq-msg-users" if="jbossmq.present">
+		<property name="msg-users" value="messaging-db-users-service.xml" />
+	</target>
+	<target name="hornetq-msg-users" if="hornetq.present">
+		<property name="msg-users" value="" />
+	</target>
+	
 	<!-- Import the base Ant build script... -->
 	<import file="../conf/base-build.xml"/>
-
+	
     <target name="quickstart-specific-deploys" depends="messaging-config">
 		<antcall target="jbm-deploys"/>
 		<antcall target="jbmq-deploys"/>

Modified: labs/jbossesb/trunk/product/samples/quickstarts/jms_secured/deployment.xml
===================================================================
--- labs/jbossesb/trunk/product/samples/quickstarts/jms_secured/deployment.xml	2010-08-03 12:40:28 UTC (rev 34480)
+++ labs/jbossesb/trunk/product/samples/quickstarts/jms_secured/deployment.xml	2010-08-03 13:40:02 UTC (rev 34481)
@@ -2,6 +2,6 @@
 <jbossesb-deployment>
   <jmsQueue>quickstart_jms_secured_Request_esb</jmsQueue>
   <jmsQueue>quickstart_jms_secured_Request_gw</jmsQueue>
-  <depends>jboss.messaging:service=JMSSecuredQuickstartUserManager</depends>
+  <jmsSecurityManager>jboss.messaging:service=JMSSecuredQuickstartUserManager</jmsSecurityManager>
   <depends>jboss.esb:deployment=jbossesb.esb</depends>
 </jbossesb-deployment>

Added: labs/jbossesb/trunk/product/samples/quickstarts/jms_secured/no-service.xml
===================================================================
--- labs/jbossesb/trunk/product/samples/quickstarts/jms_secured/no-service.xml	                        (rev 0)
+++ labs/jbossesb/trunk/product/samples/quickstarts/jms_secured/no-service.xml	2010-08-03 13:40:02 UTC (rev 34481)
@@ -0,0 +1,2 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<server></server>


Property changes on: labs/jbossesb/trunk/product/samples/quickstarts/jms_secured/no-service.xml
___________________________________________________________________
Name: svn:keywords
   + Id Revision
Name: svn:eol-style
   + LF

Modified: labs/jbossesb/trunk/product/samples/quickstarts/jms_secured/readme.txt
===================================================================
--- labs/jbossesb/trunk/product/samples/quickstarts/jms_secured/readme.txt	2010-08-03 12:40:28 UTC (rev 34480)
+++ labs/jbossesb/trunk/product/samples/quickstarts/jms_secured/readme.txt	2010-08-03 13:40:02 UTC (rev 34481)
@@ -16,6 +16,29 @@
   Please refer to 'ant help-quickstarts' for prerequisites about the quickstarts
   and a more detailed descripton of the different ways to run the quickstarts.
 
+NOTE to HornetQ Users:
+========================
+  You need to perform some additional manual configurations if running this 
+  quickstart against an AS5 installation that has HornetQ installed:
+  
+  1. Add the following roles to the server/<name>/conf/props/hornetq-roles.properties:
+     gatewayuser=gatewayrole
+     esbuser=esbrole  
+  
+  2. Add the following to the server/<name>/conf/props/hornetq-users.properties:
+     gatewayuser=gwpassword
+     esbuser=esbpassword
+  
+  3. Add the following to the <security-settings> element in the server/<name>/deploy/hornetq/hornetq-configuration.xml:     
+     <security-setting match="jms.queue.quickstart_jms_secured_Request_gw">
+         <permission type="send" roles="esbrole,gatewayrole"/>
+         <permission type="consume" roles="esbrole"/>
+     </security-setting>      
+     <security-setting match="jms.queue.quickstart_jms_secured_Request_esb">
+         <permission type="send" roles="esbrole"/>
+         <permission type="consume" roles="esbrole"/>
+     </security-setting>
+
 To Run:
 ===========================
   1. In a command terminal window in this folder ("Window1"), type 'ant deploy'.



More information about the jboss-svn-commits mailing list