jaliya 2005/03/01 19:47:04
Added: sandesha/interop build.xml client-config.wsdd
server-config.wsdd
Log:
Build files for interop tests
Revision Changes Path
1.1 ws-fx/sandesha/interop/build.xml
Index: build.xml
===================================================================
<?xml version="1.0"?>
<project name="Apache Sandesha" default="usage" basedir=".">
<!-- ===================================================================
-->
<description>
Build file for Apache Sandesha
This file is intended for ANT, a Java based build tool.
ANT is available from http://jakarta.apache.org/ant/index.html
Prerequisites:
J2SDK 1.4 from http://java.sun.com/
jakarta-ant from http://jakarta.apache.org/ant/
commons-logging from http://jakarta.apache.org/commons/logging.html
log4j from http://jakarta.apache.org/log4j
Optional components:
junit from http://www.junit.org/
Build Instructions:
To build, run
ant "target"
on the directory where this file is located with the target you want.
</description>
<target name="init">
<property name="product.Name" value="Apache-Sandesha-J"/>
<property name="product.name" value="sandesha"/>
<property name="product.shortname" value="sandesha"/>
<property name="product.version.major" value="1"/>
<property name="product.version.minor" value="0"/>
<property name="product.version.level" value="Beta2"/>
<property name="product.Version"
value="${product.version.major}.${product.version.minor}.${product.version.level}"/>
<property name="product.version"
value="${product.version.major}.${product.version.minor}.${product.version.level}"/>
<property name="product_version"
value="${product.version.major}_${product.version.minor}_${product.version.level}"/>
<property name="year" value="2004"/>
<property name="copyright" value="Copyright © ${year} Apache
Sandesha Project. All Rights Reserved."/>
<!-- Give user a chance to override without editing this file
(and without typing -D each time it compiles it) -->
<property file="./build.properties"/>
<property file="${user.home}/build.properties"/>
<!-- Place Holder for proxy settings -->
<property name="http.proxyHost" value=""/>
<property name="http.proxyPort" value=""/>
<property name="http.nonProxyHosts" value="localhost"/>
<property name="http.proxyUser" value=""/>
<property name="http.proxyPassword" value=""/>
<property name="dir.doc" value="..\doc"/>
<property name="dir.dist" value="..\dist"/>
<property name="dir.libs" value="..\lib"/>
<property name="dir.src" value="..\src"/>
<property name="dir.samples" value="..\samples"/>
<property name="dir.test" value="..\test"/>
<property name="dir.keys" value="..\keys"/>
<property name="dir.specs" value="..\specs"/>
<property name="dir.interop" value="..\interop"/>
<property name="dir.webapp" location="..\webapps/axis"/>
<property name="build.dir" value="..\target"/>
<!-- Following two were added on 01-03-2005-->
<property name="dir.config" value="..\config"/>
<property name="test.report" value="${build.dir}\test-reports"/>
<property name="build.interop" value="${build.dir}\interop-classes"/>
<property name="build.classes" value="${build.dir}/classes"/>
<property name="build.work" value="${build.dir}/work"/>
<property name="build.webapp" location="${build.dir}/webapps/axis"/>
<property name="jar.library" value="${product.shortname}.jar"/>
<property name="build.doc" value="${build.dir}/doc"/>
<property name="build.doc.xml" value="${build.doc}/xml"/>
<property name="build.doc.html" value="${build.doc}/html"/>
<property name="build.javadoc" value="${build.doc.html}/api"/>
<property name="build.junit.xml" value="${build.doc.xml}/junit"/>
<property name="build.junit.html" value="${build.doc.html}/junit"/>
<!--
for the time being following path id uses the libs in the sandesha
lib directory only This is done to test if we really don't need
any axis libs. After this is done we can include the
java.class.path and leave the sandesha/lib empty. This requires that
the CLASSPATH includes all required packages (see above
ALEK: thos does nto seems to be true as
start-functional-test-http-server depends on AXIS.jar (what version?)
-->
<path id="classpath.libraries" description="3rd party libs">
<fileset dir="${dir.libs}">
<include name="**/*.jar"/>
<!-- <pathelement path="${java.class.path}"/> -->
</fileset>
</path>
<path id="classpath.sandesha" description="sandesha classes; first
try pure class files, then jars">
<pathelement path="${build.classes}"/>
<pathelement path="${build.dir}/${jar.library}"/>
</path>
<path id="classpath.library">
<path refid="classpath.sandesha"/>
<path refid="classpath.libraries"/>
</path>
<path id="classpath.interop">
<path refid="classpath.sandesha"/>
<path refid="classpath.libraries"/>
<pathelement path="${build.interop}"/>
</path>
<taskdef resource="axis-tasks.properties"
classpathref="classpath.library"/>
<taskdef name="runaxisfunctionaltests"
classname="org.apache.axis.tools.ant.axis.RunAxisFunctionalTestsTask"
loaderref="axis">
<classpath refid="classpath.library"/>
</taskdef>
<!-- this shall include Axis jars because the tests use the
Axis implementation of javax.xml.soap, etc. Therefore the
CLASSPATH is included.
-->
<path id="classpath.test">
<!-- classpath for test is librarypath plus junit -->
<path refid="classpath.library"/>
<pathelement path="${java.class.path}"/>
</path>
<path id="classpath.test.jar">
<!-- classpath for test is librarypath plus junit -->
<path refid="classpath.library"/>
<pathelement path="${build.dir}/${jar.library}"/>
<pathelement path="${build.dir}/${jar.tests}"/>
</path>
<patternset id="distFiles">
<include name="build.xml"/>
<include name="LICENSE.txt"/>
</patternset>
<patternset id="srcFiles">
<!-- for some strange reasons, I can't use ${src} but must use
src -->
<include name="src/**/*"/>
</patternset>
<echo
message="-------------------------------------------------------------------"/>
<echo message="-------------- ${product.Name} v${product.Version}
[${year}] ----------------"/>
<echo
message="-------------------------------------------------------------------"/>
<echo message="Building with ${ant.version}"/>
<echo message="using build file ${ant.file}"/>
<echo message="Java ${java.version} located at ${java.home} "/>
<echo
message="-------------------------------------------------------------------"/>
<echo message="--- Property values ---"/>
<echo message="sun.boot.class.path=${sun.boot.class.path}"/>
<pathconvert targetos="windows" property="classpath.test.as.string"
refid="classpath.test"/>
<echo message="classpath.test: ${classpath.test.as.string}"/>
<echo message=""/>
</target>
<target name="usage" depends="init">
<echo message="
"/>
<echo message="
"/>
<echo message=" Build instructions
"/>
<echo
message="-------------------------------------------------------------------"/>
<echo message="
"/>
<echo message=" available targets are:
"/>
<echo message=" run_async_ping -->runs interop test for AsyncPing
"/>
<echo message=" run_sync_ping -->runs interop test for SyncPing
"/>
<echo message=" run_echo_string -->runs interop test for EchoStirng
"/>
<echo message=" compile.interop --> compiles the interop source
code "/>
<echo message=" clean --> cleans up all generated files
and "/>
<echo message=" jar --> creates the JAR file
"/>
<echo message=" usage --> provides help on using the
build tool "/>
<echo message=" (default)
"/>
<echo message=" See comments inside the build.xml file for more
details. "/>
<echo
message="-------------------------------------------------------------------"/>
<echo message="
"/>
</target>
<target name="clean" depends="init"
description="Clean up all temporary build files">
<delete dir="${build.dir}"/>
<delete>
<fileset dir="." includes="before*.xml"/>
<fileset dir="." includes="after*.xml"/>
<fileset dir="." includes="signed*.xml"/>
<fileset dir="." includes="server*.wsdd"/>
<fileset dir="." includes="client*.wsdd"/>
</delete>
</target>
<target name="prepare" depends="init"
description="This target generates a first build directory and checks
for some libraries">
<tstamp/>
<mkdir dir="${build.dir}"/>
<mkdir dir="${build.dir}/test-reports"/>
<available property="junit.present"
classname="junit.framework.TestCase">
<!-- check whether JUnit is available -->
<classpath refid="classpath.test"/>
</available>
<available property="jdk14.present"
classname="java.security.cert.CertPath">
<!-- check whether JDK14 is available -->
<classpath refid="classpath.test"/>
</available>
<available property="jdk15.present"
classname="java.lang.instrument.Instrumentation">
<!-- check whether JDK15 is available -->
<classpath refid="classpath.test"/>
</available>
<available property="bc.present"
classname="org.bouncycastle.jce.provider.BouncyCastleProvider">
<!-- check whether BouncyCastle is available -->
<classpath refid="classpath.test"/>
</available>
<echo message="--- Flags (Note: If the {property name} is displayed,
"/>
<echo message=" then the component is not present)"/>
<echo message="jdk14.present=${jdk14.present}"/>
<echo message="jdk15.present=${jdk15.present}"/>
<echo message="bc.present=${bc.present}"/>
</target>
<target name="prepare-src" depends="prepare" description="This target
copies the Java sources and brands the version information">
<!-- create directories -->
<mkdir dir="${build.classes}"/>
</target>
<target name="compile"
depends="compile.library"
description="compile everything"/>
<target name="compile.library" depends="prepare-src">
<!-- Compile the java code from ${dir.src} into ${build.classes} -->
<javac srcdir="${dir.src}" destdir="${build.classes}" debug="on">
<classpath refid="classpath.library"/>
<exclude name="**/Merlin.java" unless="jdk14.present"/>
<!-- <exclude name="**/MerlinPFX.java" unless="jdk14.present"/>
-->
<exclude name="**/BouncyCastle.java" unless="bc.present"/>
</javac>
<!-- Copy Property files -->
<copy todir="${build.classes}">
<fileset dir="${dir.src}">
<include name="**/*.properties"/>
<exclude name="**/axis/**/*.properties"/>
</fileset>
</copy>
</target>
<target name="compile.interop"
depends="compile.library">
<javac srcdir="${dir.interop}" destdir="${build.interop}" debug="on">
<classpath refid="classpath.library"/>
</javac>
<!--ant dir="${dir.interop}"
antfile="build.xml"
target="compile"
inheritAll="false">
</ant-->
<copy todir="${build.interop}">
<fileset dir="${dir.interop}" includes="client-config.wsdd"/>
<fileset dir="${dir.config}"
includes="client-listener-config.wsdd"/>
<fileset dir="${dir.config}" includes="sandesha.properties"/>
</copy>
</target>
<!-- Following targets were added to run the test -->
<!-- Added on 01-03-2005-->
<target name="interop_prepare" depends="init"
description="This target creats the interop-classses directory">
<tstamp/>
<mkdir dir="${build.dir}/interop-classes"/>
</target>
<target name="run_tcp1" depends="init">
<java classname="org.apache.axis.utils.tcpmon" fork="true"
spawn="true">
<arg value="8070"/>
<arg value="localhost"/>
<arg value="8080"/>
<classpath refid="classpath.library"/>
</java>
</target>
<target name="run_tcp2" depends="init">
<java classname="org.apache.axis.utils.tcpmon" fork="true"
spawn="true">
<arg value="9070"/>
<arg value="localhost"/>
<arg value="9090"/>
<classpath refid="classpath.library"/>
</java>
</target>
<target name="run_server">
<java classname="org.apache.axis.transport.http.SimpleAxisServer"
spawn="true" fork="true">
<arg value="-p"/>
<arg value="8080"/>
<classpath refid="classpath.library"/>
<classpath refid="classpath.interop"/>
</java>
<java classname="org.apache.axis.client.AdminClient" fork="true"
spawn="true">
<arg value="${dir.interop}\RMInteropServiceDeploy.wsdd"/>
<classpath refid="classpath.library"/>
<classpath refid="classpath.interop"/>
</java>
</target>
<target name="run_interop_async_ping"
depends="compile.interop,run_tcp1,run_tcp2,run_server">
<java classname="org.apache.sandesha.samples.interop.AsyncPingClient">
<classpath refid="classpath.interop"/>
</java>
</target>
<target name="run_interop_sync_ping"
depends="compile.interop,run_tcp1,run_server">
<java classname="org.apache.sandesha.samples.interop.SyncPingClient">
<classpath refid="classpath.interop"/>
</java>
</target>
<target name="run_interop_echo_string"
depends="compile.interop,run_tcp1,run_tcp2,run_server">
<java classname="org.apache.sandesha.samples.interop.EchoClient">
<classpath refid="classpath.interop"/>
</java>
</target>
<target name="shutdown_server" depends="run_server">
<java classname="org.apache.axis.client.AdminClient" fork="yes">
<classpath refid="classpath.library"/>
<arg line="quit -p 8080"/>
</java>
</target>
<target name="run_async_ping"
depends="run_interop_sync_ping,shutdown_server"> </target>
<target name="run_sync_ping"
depends="run_interop_async_ping,shutdown_server"> </target>
<target name="run_echo_string"
depends="run_interop_echo_string,shutdown_server"> </target>
</project>
1.1 ws-fx/sandesha/interop/client-config.wsdd
Index: client-config.wsdd
===================================================================
<?xml version="1.0" encoding="UTF-8"?>
<deployment xmlns="http://xml.apache.org/axis/wsdd/"
xmlns:java="http://xml.apache.org/axis/wsdd/providers/java">
<globalConfiguration>
<parameter name="adminPassword" value="admin"/>
<parameter name="disablePrettyXML" value="true"/>
<parameter name="attachments.implementation"
value="org.apache.axis.attachments.AttachmentsImpl"/>
<parameter name="sendXsiTypes" value="true"/>
<parameter name="sendMultiRefs" value="true"/>
<parameter name="sendXMLDeclaration" value="true"/>
</globalConfiguration>
<handler name="RMSender" type="java:org.apache.sandesha.client.RMSender"/>
<transport name="java"
pivot="java:org.apache.axis.transport.java.JavaSender"/>
<transport name="http"
pivot="java:org.apache.axis.transport.http.HTTPSender"/>
<transport name="local"
pivot="java:org.apache.axis.transport.local.LocalSender"/>
<transport name="RMTransport" pivot="RMSender"/>
</deployment>
1.1 ws-fx/sandesha/interop/server-config.wsdd
Index: server-config.wsdd
===================================================================
<?xml version="1.0" encoding="UTF-8"?>
<deployment xmlns="http://xml.apache.org/axis/wsdd/"
xmlns:java="http://xml.apache.org/axis/wsdd/providers/java">
<globalConfiguration>
<parameter name="adminPassword" value="admin"/>
<parameter name="disablePrettyXML" value="true"/>
<parameter name="sendMultiRefs" value="true"/>
<parameter name="sendXsiTypes" value="true"/>
<parameter name="attachments.implementation"
value="org.apache.axis.attachments.AttachmentsImpl"/>
<parameter name="sendXMLDeclaration" value="true"/>
<requestFlow>
<handler type="java:org.apache.axis.handlers.JWSHandler">
<parameter name="scope" value="session"/>
</handler>
<handler type="java:org.apache.axis.handlers.JWSHandler">
<parameter name="scope" value="request"/>
<parameter name="extension" value=".jwr"/>
</handler>
</requestFlow>
</globalConfiguration>
<handler name="LocalResponder"
type="java:org.apache.axis.transport.local.LocalResponder"/>
<handler name="URLMapper"
type="java:org.apache.axis.handlers.http.URLMapper"/>
<handler name="Authenticate"
type="java:org.apache.axis.handlers.SimpleAuthenticationHandler"/>
<service name="AdminService" provider="java:MSG">
<parameter name="allowedMethods" value="AdminService"/>
<parameter name="enableRemoteAdmin" value="false"/>
<parameter name="className" value="org.apache.axis.utils.Admin"/>
<namespace>http://xml.apache.org/axis/wsdd/</namespace>
</service>
<service name="Version" provider="java:RPC">
<parameter name="allowedMethods" value="getVersion"/>
<parameter name="className" value="org.apache.axis.Version"/>
</service>
<service name="RMInteropService" provider="Handler">
<requestFlow>
<handler
type="java:org.apache.sandesha.ws.rm.handlers.RMServerRequestHandler"/>
<handler
type="java:org.apache.axis.message.addressing.handler.AddressingHandler"/>
</requestFlow>
<parameter name="allowedMethods" value="*"/>
<parameter name="scope" value="request"/>
<parameter name="className"
value="org.apache.sandesha.samples.interop.RMInteropService"/>
<parameter name="handlerClass"
value="org.apache.sandesha.ws.rm.providers.RMProvider"/>
</service>
<transport name="http">
<requestFlow>
<handler type="URLMapper"/>
<handler type="java:org.apache.axis.handlers.http.HTTPAuthHandler"/>
</requestFlow>
<parameter name="qs:list"
value="org.apache.axis.transport.http.QSListHandler"/>
<parameter name="qs:wsdl"
value="org.apache.axis.transport.http.QSWSDLHandler"/>
<parameter name="qs:method"
value="org.apache.axis.transport.http.QSMethodHandler"/>
</transport>
<transport name="local">
<responseFlow>
<handler type="LocalResponder"/>
</responseFlow>
</transport>
</deployment>