[jboss-svn-commits] JBL Code SVN: r11762 - in labs/jbossesb/workspace/dbevenius/product/samples/quickstarts: helloworld_ftp_action and 1 other directory.

jboss-svn-commits at lists.jboss.org jboss-svn-commits at lists.jboss.org
Tue May 8 13:53:04 EDT 2007


Author: beve
Date: 2007-05-08 13:53:03 -0400 (Tue, 08 May 2007)
New Revision: 11762

Modified:
   labs/jbossesb/workspace/dbevenius/product/samples/quickstarts/conf/base-build.xml
   labs/jbossesb/workspace/dbevenius/product/samples/quickstarts/helloworld_ftp_action/build.xml
Log:
Modified the build.xml for helloworld_ftp_action so that a new esb config file is created for
every run of 'run-readonly'. Otherwise, when two instances are started an use the same file
they will interfere with each other as the file is filtered and hence recreated.


Modified: labs/jbossesb/workspace/dbevenius/product/samples/quickstarts/conf/base-build.xml
===================================================================
--- labs/jbossesb/workspace/dbevenius/product/samples/quickstarts/conf/base-build.xml	2007-05-08 17:48:35 UTC (rev 11761)
+++ labs/jbossesb/workspace/dbevenius/product/samples/quickstarts/conf/base-build.xml	2007-05-08 17:53:03 UTC (rev 11762)
@@ -99,9 +99,14 @@
 	<target name="run" depends="compile,config">
 		<description>	run				will run the quickstart in standalone mode
 		</description>
+		
+		<condition property="esb.config.file" 
+			value="${esb.config.file}" else="${basedir}/jboss-esb.xml">
+			<isset property="esb.config.file"/>
+		</condition>
 		<echo>Launching Quickstart in standalone mode...</echo>
 		<java fork="yes" classname="org.jboss.soa.esb.listeners.StandAloneBootStrapper" failonerror="true">
-			<arg value="${basedir}/jboss-esb.xml" />
+			<arg value="${esb.config.file}" />
 			<classpath refid="exec-classpath" />
 		</java>
 	</target>

Modified: labs/jbossesb/workspace/dbevenius/product/samples/quickstarts/helloworld_ftp_action/build.xml
===================================================================
--- labs/jbossesb/workspace/dbevenius/product/samples/quickstarts/helloworld_ftp_action/build.xml	2007-05-08 17:48:35 UTC (rev 11761)
+++ labs/jbossesb/workspace/dbevenius/product/samples/quickstarts/helloworld_ftp_action/build.xml	2007-05-08 17:53:03 UTC (rev 11762)
@@ -10,6 +10,7 @@
 	<target name="config" unless="readonly.mode">
 		<antcall target="filter_jboss-esb.xml">
 				<param name="file.name" value="jboss-esb-unfiltered.xml"/>
+				<param name="to.file.name" value="${basedir}/jboss-esb.xml"/>
 		</antcall>
 		<copy file="log4j.xml" tofile="build/log4j.xml"/>
 	</target>
@@ -39,17 +40,26 @@
 		<copy file="ftpfile-cache-config.xml" todir="${basedir}/classes"/>
 		<property name="readonly.mode" value="true"/>
 		
+		<tstamp>
+			<format property="timestamp" pattern="ss" />
+		</tstamp>
+	
+		<property name="readonly.esb.config.file" value="${basedir}/readonly-esb-${timestamp}.xml"/>
+		
 		<antcall target="filter_jboss-esb.xml">
 			<param name="file.name" value="${basedir}/jboss-esb-readonly-unfiltered.xml"/>
+			<param name="to.file.name" value="${readonly.esb.config.file}"/>
 		</antcall>
 	
-		<antcall target="run"/>
+		<antcall target="run">
+			<param name="esb.config.file" value="${readonly.esb.config.file}"/>
+		</antcall>
 	</target>
 	
 	
 	<target name="filter_jboss-esb.xml">
 		<echo message="${file.name}"/>
-		<copy file="${file.name}" tofile="${basedir}/jboss-esb.xml" overwrite="true" filtering="true">
+		<copy file="${file.name}" tofile="${to.file.name}" overwrite="true" filtering="true">
 				<filterset>
 					<filter token="FTP_HOSTNAME" value="${quickstart.jbossesb.ftp.hostname}"/>
 					<filter token="FTP_USERNAME" value="${quickstart.jbossesb.ftp.username}"/>
@@ -59,4 +69,14 @@
 		</copy>
 	</target>
 	
+    <target name="quickstart-specific-clean">
+		<delete >
+			<fileset dir="${basedir}">
+				<include name="readonly-esb*"/>
+				<include name="jbossesb-gateway.xml"/>
+				<include name="jbossesb-listener.xml"/>
+			</fileset>
+		</delete>
+    </target>
+	
 </project>




More information about the jboss-svn-commits mailing list