Changeset 3941 for TI01-discovery


Ignore:
Timestamp:
23/05/08 12:18:48 (11 years ago)
Author:
cbyrom
Message:

Update the readme doc to include new instructions for setting things up.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • TI01-discovery/trunk/ws-Discovery2/readme.txt

    r2995 r3941  
    22------------ 
    33 
    4 Server Side: 
    5 Instructions for building & deploying Axis2 web service archive (DiscoveryService.aar) 
     4NB, completing the build here assumes you have both apache axis2 and ant installed.  The AXIS2_HOME environment variable 
     5should be set to point to the top level directory of the axis2 install. 
    66 
    7 1. Run WSDL2Java to generate skeleton code and XMLBeans for data binding 
    8 (In srcgen directory) 
    9 %AXIS2_HOME%\bin\wsdl2java -ss -sd -d xmlbeans -uri ..\wsdl\Discovery.wsdl -o . -p ndg.services.discovery 
     7The build file, \srcgen\buildDiscovery.xml, now includes targets to run the WSDL2Java code generation.  Running the build 
     8with no parameters, e.g.: 
    109 
    11 2. Build server side code (DiscoveryService.aar) 
    12 (In srcgen directory) 
    13 ant -buildfile buildDiscovery.xml jar.server 
    14 (output in build/lib) 
     10ant -f buildClient.xml 
    1511 
    16 3. Optionally build javadoc documentation 
    17 ant -buildfile buildDiscovery.xml javadoc 
     12will now build both the server and client archives and make the necessary changes to the files outlined below.  NB, to get 
     13the DiscoveryService.wsdl file to be generated properly, you will likely have to temporarily rename the jsr file, as mentioned 
     14below. 
    1815 
    19 4. Deploy the service 
    20  - Copy DiscoveryService.aar to <tomcat>/webapps/axis/WEB-INF/services 
    21  - Reload axis2 context within tomcat manager app, or restart tomcat 
    22  
     16Original, detailed instructions, are as follows (but you shouldn't have to use them!): 
    2317 
    2418Client Side: 
    25 Instructions for building client (DiscoveryService.aar) 
     19--------------- 
     20Instructions for building client (DiscoveryService-test-client.jar) 
    2621 
    2722Do all the following in directory "srcgen" 
     
    4136ant -buildfile buildClient.xml run.client 
    4237 
    43 Code to edit for testing is in ..\src\ndg\services\discovery\MyDiscoveryServiceClient.java 
     38Server Side: 
     39--------------- 
     40Instructions for building & deploying Axis2 web service archive (DiscoveryService.aar) 
     41 
     421. Run WSDL2Java to generate skeleton code and XMLBeans for data binding 
     43(In srcgen directory) 
     44%AXIS2_HOME%\bin\wsdl2java -ss -sd -d xmlbeans -uri ..\wsdl\Discovery.wsdl -o . -p ndg.services.discovery 
     45 
     46NB, when running this command, you may get an error along the lines of: 
     47 
     48Exception in thread "main" java.lang.NoSuchMethodError: javax.xml.stream.XMLOutputFactory.newInstance(Ljava/lang/String;Ljava/lang/ClassLoader;)Ljavax/xml/stream/XMLOutputFactory; 
     49        at org.apache.axiom.om.util.StAXUtils.getXMLOutputFactory(StAXUtils.java:97) 
     50 
     51- this occurs due to a mismatch in libraries between the versions of java and axis being used.  A 
     52quick fix can be to temporarily hide jre/lib/ext/jsr173_1.0_api.jar.  NB, without this change, the 
     53generated DiscoveryService.wsdl file is likely to be empty. 
     54 
     552. Build server side code (DiscoveryService.aar) 
     56(In srcgen directory) 
     57ant -buildfile buildDiscovery.xml jar.server 
     58(output in build/lib) 
     59 
     603. Optionally build javadoc documentation 
     61ant -buildfile buildDiscovery.xml javadoc 
     62 
     634. Deploy the service 
     64 - Copy DiscoveryService.aar to <tomcat>/webapps/axis/WEB-INF/services (NB, for this step you need to have axis2 
     65 installed in your tomcat server - just drop an axis2.war file into the webapps directory when the server is running) 
     66 - Reload axis2 context within tomcat manager app, or restart tomcat 
     67 
     68 
     69 
     70Code to edit for testing is in ..\src\ndg\services\discovery\DiscoveryServiceClient.java 
    4471 
    4572Tested with Sun Java SDK 1.5.08 (problems with 1.6.03) 
Note: See TracChangeset for help on using the changeset viewer.