WebSphere Application Server - Express, Version 6.0.x     Operating Systems: AIX, HP-UX, Linux, Solaris, Windows

Assembling a Web services-enabled enterprise bean JAR file from a WSDL file

This task explains how to assemble a Web services-enabled enterprise bean Java archive (JAR) file from a Web Services Description Language (WSDL) file with an assembly tool.

Before you begin

You can assemble Web Services for J2EE modules with assembly tools provided with WebSphere Application Server.

You must configure the assembly tool before you can use it.

You need the following artifacts to complete this task:

Why and when to perform this task

Assemble a Web services-enabled enterprise bean JAR file from a WSDL file by following the actions in the steps for this task section.

Steps for this task

  1. Start the assembly tool. The assembly tools, Application Server Toolkit (AST) and Rational Web Developer, provide a graphical interface for developing code artifacts, assembling the code artifacts into various archives (modules) and configuring related Java 2 Platform, Enterprise Edition (J2EE) Version 1.2, 1.3 or 1.4 compliant deployment descriptors.
  2. Click File > Import to import the enterprise bean JAR file into the assembly tool.
  3. Open the J2EE perspective by clicking Windows >Open Perspective > Other > J2EE.
  4. Switch to the Project Navigator pane by clicking the Project Navigator tab.
  5. Locate the project for the JAR file you just imported in the Project Navigator pane.
  6. Expand the ejbModule entry so that the META-INF directory is displayed. Expand the META-INF directory.
  7. Right-click the META-INF directory and select New > Folder. Create a subfolder named wsdl in the META-INF directory.
  8. Copy the WSDL file to the META-INF\wsdl directory by right-clicking the wsdl directory and click File > Import > File system. Browse the WSDL file for this Web service and click Finish.
  9. Copy the JAX-RPC mapping file as specified by the deployment descriptor <jaxrpc-mapping-file> element of the webservices.xml file.
  10. Copy the webservices.xml, ibm-webservices-bnd.xmi and ibm-webservices-ext.xmi deployment descriptors into the META-INF subdirectory in the same manner.

Result

You have the artifacts required to Web service-enable an Enterprise JavaBeans (EJB) module for Web services. The artifacts are added to the JAR file. Now you need to configure the deployment descriptors so that you can deploy the Web service into the WebSphere Application Server run time environment.

Example

After assembling the AddressBook.jar JAR filecontains the following files after assembly. The files added in this task are in bold. These files include the WSDL file, the deployment descriptors, and the JAX-RPC mapping file.
META-INF/MANIFEST.MF 
META-INF/ejb-jar.xml 
addr/Address.class 
addr/AddressBook_RI.class 
addr/AddressBookSoapBindingImpl.class 
addr/AddressBookHome.class 
addr/Phone.class
addr/StateType.class 
addr/AddressBook.class 
META-INF/wsdl/AddressBook.wsdl
META-INF/ibm-webservices-bnd.xmi 
META-INF/ibm-webservices-ext.xmi
META-INF/webservices.xml
META-INF/AddressBook_mapping.xml 

What to do next

Configure the webservices.xml deployment descriptor . You need to configure the deployment descriptors for the Web service so that WebSphere Application Server can process the incoming Web services requests.



Related tasks
Assembling a JAR file that is enabled for Web services from an enterprise bean
Assembling Web services applications
Assembling an enterprise bean JAR file into an EAR file
Developing new Web services from an existing WSDL file using an EJB implementation

Task topic    

Terms of Use | Feedback

Last updated: Jun 8, 2005 12:45:23 PM EDT
http://publib.boulder.ibm.com/infocenter/wasinfo/v6r0/index.jsp?topic=/com.ibm.websphere.express.doc/info/exp/ae/twbs_assembjarwsdl.html

© Copyright IBM Corporation 2004, 2005. All Rights Reserved.
This information center is powered by Eclipse technology. (http://www.eclipse.org)