hivemind-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From hls...@apache.org
Subject cvs commit: jakarta-hivemind/framework build.xml
Date Fri, 28 May 2004 16:44:39 GMT
hlship      2004/05/28 09:44:39

  Modified:    src/documentation/content/xdocs index.xml configurations.xml
                        services.xml multithreading.xml
               common   jar-module.xml
               library  build.xml
               framework build.xml
  Added:       common   clover.properties clover-report.xml
  Removed:     common   clover.xml
  Log:
  Add clover reports.
  
  Revision  Changes    Path
  1.4       +5 -4      jakarta-hivemind/src/documentation/content/xdocs/index.xml
  
  Index: index.xml
  ===================================================================
  RCS file: /home/cvs/jakarta-hivemind/src/documentation/content/xdocs/index.xml,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -r1.3 -r1.4
  --- index.xml	26 May 2004 19:34:15 -0000	1.3
  +++ index.xml	28 May 2004 16:44:39 -0000	1.4
  @@ -104,8 +104,9 @@
   				possible. Since services are, ultimately, simple objects (POJOs -- plain
   				old java objects) within the same JVM, all the complexity of J2EE falls
   				away ... no more JNDI lookups, no more RemoteExceptions, no more home
  -				and remote interfaces. Of course, you can still use HiveMind to <!-- TODO: fix this
link! -->
  -				<link href="#">front your EJBs</link>, in which case the service is
  +				and remote interfaces. Of course, you can still use HiveMind to 
  +				<link href="site:hivemind.lib.EJBProxyFactory">front your 
  +				EJBs</link>, in which case the service is
   				responsible for performing the JNDI lookup and so forth (which in itself
   				has a lot of value), before forwarding the request to the EJB.</p>
   			<p>In any case, the code should be short. To external objects (objects
  @@ -193,7 +194,7 @@
   							points within the code ... basically, a lot of clutter. Finally,
   							it doesn't report on exceptions thrown from within the method.</p>
   					</td>
  -					<td>Let HiveMind add a <link href="hivemind/LoggingInterceptor.html">
  +					<td>Let HiveMind add a <link href="site:hivemind.LoggingInterceptor">
   						logging interceptor</link> to your service. It will consistently log
   						method entry and exit, and log any exceptions thrown by the method. 
   						<p>The following descriptor snippet defines a service, provides a
  
  
  
  1.4       +5 -7      jakarta-hivemind/src/documentation/content/xdocs/configurations.xml
  
  Index: configurations.xml
  ===================================================================
  RCS file: /home/cvs/jakarta-hivemind/src/documentation/content/xdocs/configurations.xml,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -r1.3 -r1.4
  --- configurations.xml	26 May 2004 21:28:49 -0000	1.3
  +++ configurations.xml	28 May 2004 16:44:39 -0000	1.4
  @@ -224,9 +224,8 @@
   				<title>Symbol Sources</title>
   				<p>This begs the question: where do symbol values come from? The answser
   					is application dependent. HiveMind itself defines a configuration
  -					configuration point for this purpose: <link
  -					href="&hivedoc;/config/hivemind.SymbolSources.html">
  -					hivemind.SymbolSources</link>. Contributions to this configuration
  +					configuration point for this purpose: &hivemind.SymbolSources;. 
  +					Contributions to this configuration
   					point define new objects that can provide values for symbols, and
   					identify the order in which these objects should be consulted.</p>
   				<p>If at runtime none of the configured SymbolSources provides a value
  @@ -241,10 +240,9 @@
   				<li>
   					<strong>Are the any default implementations of SymbolSource?</strong>
   					<p>There is now an configuration point for setting factory defaults: 
  -						<link href="site:hivemind.FactoryDefaults">hivemind.FactoryDefaults</link>
  +						&hivemind.FactoryDefaults;
   						. A second configuration point, for application defaults, overrides
  -						the factory defaults: <link href="site:hivemind.ApplicationDefaults"
  -						>hivemind.ApplicationDefaults</link>.</p>
  +						the factory defaults: &hivemind.ApplicationDefaults;.</p>
   					<p> <link href="&apiroot;/impl/SystemPropertiesSymbolSource.html">
   						SystemPropertiesSymbolSource</link> is a one-line implementation
   						that allows access to system properties as substitution symbols.
  
  
  
  1.4       +3 -4      jakarta-hivemind/src/documentation/content/xdocs/services.xml
  
  Index: services.xml
  ===================================================================
  RCS file: /home/cvs/jakarta-hivemind/src/documentation/content/xdocs/services.xml,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -r1.3 -r1.4
  --- services.xml	26 May 2004 21:28:49 -0000	1.3
  +++ services.xml	28 May 2004 16:44:39 -0000	1.4
  @@ -119,9 +119,8 @@
   				<p>An implementation factory is used to create a core implementation for
   					a service at runtime.</p>
   				<p>Often, the factory will need some additional configuration
  -					information. For example, the <link
  -					href="&hivedoc;/service/hivemind.lib.EJBProxyFactory.html">
  -					hivemind.lib.EJBProxyFactory</link> service uses its parameters to
  +					information. For example, the &hivemind.lib.EJBProxyFactory;
  +				  service uses its parameters to
   					identify the JNDI name of the EJB's home interface, as well as the
   					home interface class itself.</p>
   				<p>Parameters to factory services are the XML elements enclosed by the &_invoke-factory;
  
  
  
  1.3       +2 -2      jakarta-hivemind/src/documentation/content/xdocs/multithreading.xml
  
  Index: multithreading.xml
  ===================================================================
  RCS file: /home/cvs/jakarta-hivemind/src/documentation/content/xdocs/multithreading.xml,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -r1.2 -r1.3
  --- multithreading.xml	26 May 2004 21:28:49 -0000	1.2
  +++ multithreading.xml	28 May 2004 16:44:39 -0000	1.3
  @@ -26,7 +26,7 @@
   	</header>
   	<body>
   		<p>HiveMind is specifically targetted for J2EE: deployment in a WAR or EAR,
  -			particularly as part of a <link href="http://jakarta.apache.org/tapestry">
  +			particularly as part of a <link href="site:tapestry">
   			Tapestry</link> application. Of course, J2EE is not a requirement, and
   			HiveMind is quite useful even in a simple, standalone environment.</p>
   		<p>In the world of J2EE, multi-threading is always an issue. HiveMind
  
  
  
  1.5       +14 -10    jakarta-hivemind/common/jar-module.xml
  
  Index: jar-module.xml
  ===================================================================
  RCS file: /home/cvs/jakarta-hivemind/common/jar-module.xml,v
  retrieving revision 1.4
  retrieving revision 1.5
  diff -u -r1.4 -r1.5
  --- jar-module.xml	27 May 2004 15:28:22 -0000	1.4
  +++ jar-module.xml	28 May 2004 16:44:39 -0000	1.5
  @@ -67,12 +67,13 @@
   	</path>
   	
   	<macrodef name="copy-source-resources">
  -	
  +		<attribute name="classes-dir" default="${java.classes.dir}" description="Directory
to copy resources to."/>
  +		
   		<sequential>
   		
  -			<announce message="Copying resources to ${java.classes.dir} ..."/>
  +			<announce message="Copying resources to @{classes-dir} ..."/>
   			
  -			<copy todir="${java.classes.dir}" includeEmptyDirs="false">
  +			<copy todir="@{classes-dir}" includeEmptyDirs="false">
   				<fileset dir="${java.src.dir}">
   					<exclude name="**/*.java"/>	
   					<exclude name="**/package.html"/>
  @@ -90,26 +91,30 @@
   		<attribute name="sourcepath-id"
   			default="default.source.path"
   			description="Referencce to a path of source directories to compile."/>
  +		<attribute name="classes-dir"
  +				default="${java.classes.dir}"
  +				description="Directory to compile classes into."/>
   		
   		<sequential>
   			
   			<antcall target="-compile-init"/>
  +			<mkdir dir="@{classes-dir}"/>
   			
   			<!-- Make the directory, before it is referenced via default.compile.classpath.
   				   The javacc.xml module actually puts files into generated Java.  Perhaps
   				   in the future, an XDoclet extension will make use of this as well. -->
   			
  -			<announce message="Compiling Java sources to ${java.classes.dir} ..."/>
  +			<announce message="Compiling Java sources to @{classes-dir} ..."/>
   			
   			<javac
  -				destdir="${java.classes.dir}"
  +				destdir="@{classes-dir}"
   				classpathref="@{compile-classpath-id}">
   				<src>
   					<path refid="@{sourcepath-id}"/>
   				</src>	
   			</javac>
   				
  -			<copy-source-resources/>				
  +			<copy-source-resources classes-dir="@{classes-dir}"/>				
   		</sequential>	
   	</macrodef>
   	
  @@ -134,7 +139,7 @@
   		<attribute name="classpath-id" default="default.test.classpath"
   			description="Reference to path used for tests."/>
   		<attribute name="fork" default="off" description="Run the tests in a seperate JVM
if on."/>
  -		<element name="junit-elements" optional="true" description="Additional elements places
within the junit task."/>
  +		<element name="junit-elements" optional="true" description="Additional elements placed
within the junit task."/>
   		
   		<sequential>
   			<mkdir dir="${junit.temp.dir}"/>
  @@ -180,8 +185,7 @@
   		<mkdir dir="${module.lib.dir}/test"/>
   		<mkdir dir="${module.lib.dir}/run"/>	
   		
  -		<mkdir dir="${generated-java.src.dir}"/>			
  -		<mkdir dir="${java.classes.dir}"/>		
  +		<mkdir dir="${generated-java.src.dir}"/>				
   	</target>
   	
   	<!-- Usually overriden so that the options used when compiling, especially compile-classpath-id,
can be overriden. -->
  
  
  
  1.1                  jakarta-hivemind/common/clover.properties
  
  Index: clover.properties
  ===================================================================
  # 
  
  clover.classes.dir=${target.dir}/clover-classes
  clover.db.dir=${target.dir}/clover-db
  clover.report.dir=${root.forrest.composite.dir}/content/${module.name}/clover
  clover.jar=clover-1.2.3.jar
  
  
  
  
  
  1.1                  jakarta-hivemind/common/clover-report.xml
  
  Index: clover-report.xml
  ===================================================================
  <?xml version="1.0"?>
  <project name="clover-report">
  	<fail unless="ant.file.common" message="Must import common.xml first."/>
  	<fail unless="ant.file.dependency" message="Must import dependency.xml first."
  		/>
  	<property file="${common.dir}/clover.properties"/>
  	<path id="default.clover.classpath">
  		<pathelement location="${clover.classes.dir}"/>
  		<pathelement location="${ant.home}/lib/${clover.jar}"/>
  		<path refid="default.test.classpath"/>
  	</path>
  	<available property="clover.available"
  		classname="org.apache.tools.ant.taskdefs.CloverCompilerAdapter"/>
  	<target name="-check-for-clover" unless="clover.available">
  		<antcall target="-display-download-warning"/>
  		<grabber dest="${ant.home}/lib/${clover.jar}"
  			src="${maven.ibiblio.url}/clover/jars/${clover.jar}"
  			md5="${maven.ibiblio.url}/clover/jars/${clover.jar}.md5" />
  		<echo><![CDATA[
  		
  *** Clover has been installed into ${ant.home}/lib. 
  *** 
  *** You must restart the build.
  	
  ]]></echo>
  		<fail message="Clover has been installed. Restart the build."/>
  	</target>
  	<macrodef name="default-clover">
  		<attribute name="sourcepath-id" default="default.source.path"
  			description="Path reference to source files to compile."/>
  		<attribute name="compile-classpath-id" default="default.compile.classpath"
  			description="Compile-time classpath."/>
  		<attribute name="test-classpath-id" default="default.clover.classpath"
  			description="Runtime classpath for unit tests running under clover."/>
  		<element name="clover-junit-elements" optional="true"
  			description="Additional elements passed to the JUnit task."/>
  		<sequential>
  			<antcall target="-check-for-clover"/>
  			<antcall target="-compile-init"/>
  			<antcall target="compile-dependencies"/>
  			<mkdir dir="${clover.classes.dir}"/>
  			<taskdef resource="clovertasks"/>
  			<typedef resource="clovertypes"/>
  			<announce message="Recompiling Java sources for Clover ..."/>
  			<clover-setup initString="${clover.db.dir}" preserve="true"
  				tmpdir="${target.dir}"/>
  			<default-compile classes-dir="${clover.classes.dir}"/>
  			<default-run-tests fork="on" classpath-id="default.clover.classpath">
  				<junit-elements>
  					<clover-junit-elements/>
  				</junit-elements>
  			</default-run-tests>
  		</sequential>
  	</macrodef>
  	<macrodef name="generate-clover-html">
  		<sequential>
  			<announce message="Generating HTML code coverage report ..."/>
  			<clover-report>
  				<current
  					title="Code Coverage for ${module.name} release ${project.version}"
  					outfile="${root.forrest.composite.dir}/content/${module.name}/clover">
  					<format type="html">
  					</format>
  				</current>
  			</clover-report>
  			<add-report-to-menu element="clover-${module.name}"
  				label="Clover Code Coverage" file="clover/index.html"/>
  		</sequential>
  	</macrodef>
  	<macrodef name="clover-report">
  		<sequential>
  			<default-clover/>
  			<generate-clover-html/>
  		</sequential>
  	</macrodef>
  </project>
  
  
  
  1.4       +3 -1      jakarta-hivemind/library/build.xml
  
  Index: build.xml
  ===================================================================
  RCS file: /home/cvs/jakarta-hivemind/library/build.xml,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -r1.3 -r1.4
  --- build.xml	27 May 2004 15:28:22 -0000	1.3
  +++ build.xml	28 May 2004 16:44:39 -0000	1.4
  @@ -23,6 +23,7 @@
   	<property name="root.dir" value=".."/>
   	<import file="${root.dir}/common/jar-module.xml"/>
   	<import file="${common.dir}/javadoc-report.xml"/>	
  +	<import file="${common.dir}/clover-report.xml"/>
   		
   	<target name="compile">
   		<ibiblio-dependency jar="jboss-j2ee-3.2.1.jar" group-id="jboss"/>
  @@ -42,6 +43,7 @@
   	
   	<target name="run-reports">
   	  <javadoc-report/>
  +	  <clover-report/>
   	</target>
   
   </project>
  
  
  
  1.5       +29 -16    jakarta-hivemind/framework/build.xml
  
  Index: build.xml
  ===================================================================
  RCS file: /home/cvs/jakarta-hivemind/framework/build.xml,v
  retrieving revision 1.4
  retrieving revision 1.5
  diff -u -r1.4 -r1.5
  --- build.xml	27 May 2004 15:28:23 -0000	1.4
  +++ build.xml	28 May 2004 16:44:39 -0000	1.5
  @@ -16,40 +16,53 @@
      limitations under the License.
   -->
   <project name="HiveMind Framework" default="jar" basedir=".">
  -
   	<property name="module.name" value="hivemind"/>
   	<property name="javadoc.package" value="org.apache.hivemind.*"/>
  -
   	<property name="root.dir" value=".."/>
   	<import file="${root.dir}/common/jar-module.xml"/>
   	<import file="${common.dir}/javacc.xml"/>
  -	<import file="${common.dir}/javadoc-report.xml"/>								
  -					
  +	<import file="${common.dir}/javadoc-report.xml"/>
  +	<import file="${common.dir}/clover-report.xml"/>
   	<target name="compile">
  -		<ibiblio-dependency jar="commons-logging-1.0.3.jar" group-id="commons-logging"/>
  +		<ibiblio-dependency jar="commons-logging-1.0.3.jar"
  +			group-id="commons-logging"/>
   		<ibiblio-dependency jar="javassist-2.6.jar" group-id="jboss"/>
   		<ibiblio-dependency jar="werkz-1.0-beta-10.jar" group-id="werkz"/>
  -		<ibiblio-dependency jar="servletapi-2.3.jar" group-id="servletapi"/>				
  +		<ibiblio-dependency jar="servletapi-2.3.jar" group-id="servletapi"/>
   		<ibiblio-dependency jar="oro-2.0.6.jar" group-id="oro"/>
   		<ibiblio-dependency jar="log4j-1.2.7.jar" group-id="log4j"/>
  -				
  +		
   		<ibiblio-dependency jar="easymock-1.1.jar" group-id="easymock" use="test"/>
  -			
  -		<run-javacc input="${javacc.src.dir}/SimpleDataLanguageParser.jj" package-path="org/apache/hivemind/sdl/parser"/>
   		
  +		<run-javacc input="${javacc.src.dir}/SimpleDataLanguageParser.jj"
  +			package-path="org/apache/hivemind/sdl/parser"/>
   		<default-compile/>
   	</target>
  -
  -	<target name="run-tests" description="Runs JUnit tests." depends="compile-tests">
  -		<default-run-tests>	
  +	<target name="run-tests" description="Runs JUnit tests."
  +		depends="compile-tests">
  +		<default-run-tests>
   			<junit-elements>
   				<!-- Adjust for wrong current directory when framework/build.xml invoked from the
project. -->
   				<sysproperty key="FRAMEWORK_ROOT" value="${basedir}/"/>
   			</junit-elements>
   		</default-run-tests>
   	</target>
  -	
   	<target name="run-reports">
  -	  <javadoc-report/>
  +		<javadoc-report/>
  +		<!-- Have to do it the hard way, because of the extra junit stuff needed by the framework
tests. -->
  +		<default-clover>
  +			<clover-junit-elements>
  +				<sysproperty key="FRAMEWORK_ROOT" value="${basedir}/"/>
  +				
  +				<classpath>
  +					<fileset dir="${ant.home}/lib">
  +						<include name="junit-3.8.1.jar"/>
  +						<include name="xml-apis.jar"/>
  +						<include name="xercesImpl.jar"/>
  +					</fileset>	
  +				</classpath>
  +			</clover-junit-elements>
  +		</default-clover>
  +		<generate-clover-html/>
   	</target>
  -</project>
  \ No newline at end of file
  +</project>
  
  
  

---------------------------------------------------------------------
To unsubscribe, e-mail: hivemind-cvs-unsubscribe@jakarta.apache.org
For additional commands, e-mail: hivemind-cvs-help@jakarta.apache.org


Mime
View raw message