|
To create a version of the application using the JAX-RPC Reference Implementation (RI) from Sun I started from a WSDL service description that included the actual schema for my chosen wire format. The RI has some extensions that go beyond the JAX-RPC specification, one of which is support for converting ID/IDREF values in the schema to object links in the generated Java classes. This made it very nice for my test application, since it was able to fully represent the graph structure of the data being returned from the server. The JAX-RPC build and deployment process is complex, so I used the Ant build.xml script from one of the examples in the JWS 1.3 Tutorial (/examples/jaxrpc/advanced/stubs) as a basis. I set up a directory structure which mirrored that used in the tutorial, with /build, /conf, and /src directories under the root for this implementation. In the root directory I created a build.xml by merging the /examples/jaxrpc/advanced/stubs/conf/common-targets.xml into the /examples/jaxrpc/advanced/stubs/build.xml (which originally included the former file using an XML external entity reference). I then had to make several changes in the merged build.xml to work with my example. The end result is a war file that can be deployed directly to a standard servlet engine (though I only tested the version built on JWSDP 1.4 using Tomcat 5.0.25). The default Ant target just builds this war file, while the "build-client" target generates and compiles the client code, and the "run" target runs a simple test to verify that everything is working. You must deploy the service war file generated by the default target to the server before you can run the other targets. You may also need to modify the settings in the build.properties file to match your system and JWSDP installation (though only the "jwsdphome" definition should need to change, as long as you're using JWSDP 1.4). The customized code for the JAX-RPC RI version of the application is in the
/src directory tree. This includes a copy of the earthquake data for the
server, along with versions of the server I've included the run.sh Linux shell script I used in the actual timing test runs (calling this one from a separate script that ran each set of command line arguments in sequence). Here again, you'll need to modify this script to match your installation in order to run the tests yourself. The full code download as a zip file is here. |