Develop Web services applications from enterprise beans

 

+

Search Tips   |   Advanced Search

 

Overview

This task is one of four ways that you can develop a Web service. You can also...

In this task, we need develop a new WSDL file.

Enabling the enterprise bean for Web services includes developing the service endpoint interface, locating or developing a WSDL file that is the engine of the Web service, generating and configuring the deployment descriptors, completing the enterprise beans implementation, assembling all the artifacts required for the Web service, enabling the modules and deploying the application into the WebSphere Application Server environment.

To use an enterprise bean as the basis for a Web service implementation, follow these requirements:

These requirements are documented in the JAX-RPC specification available through Web services: Resources for learning.

Create the artifacts that enable the enterprise bean to be a Web service and assemble the artifacts into the enterprise application.

 

Procedure

  1. Set up a development environment for Web services. You do not have to set up a development environment if you are using Rational Application Developer.

  2. Access an existing Java archive (JAR) file to use as a Web service. Verify the enterprise bean meets the requirements.

  3. Develop an Enterprise JavaBeans service endpoint interface. The service endpoint interface defines which enterprise bean methods should be made available as a Web service.

  4. Develop a Web Services Description Language (WSDL) file. The WSDL file is the engine of a J2EE Web service; without it there is no Web service.

  5. Develop Web services deployment descriptor templates from an Enterprise JavaBeans implementation. We need to complete this step to create the deployment descriptor templates that are configured to map the service implementation to the enterprise beans implementation.

  6. Complete the enterprise beans implementation.

  7. Configure the webservices.xml deployment descriptor. Configure the webservices.xml deployment descriptor so that WAS can process the incoming Web services requests.

  8. Configure the ibm-webservices-bnd.xmi deployment descriptor. Configure the ibm-webservices-bnd.xml deployment descriptor so that WAS can process the incoming Web services requests.

  9. Assemble a JAR file that is enabled for Web services from an enterprise bean. You can assemble the artifacts that are required to enable the enterprise beans module for Web services into a JAR file.

  10. Assemble a Web services-enabled enterprise bean JAR file into an enterprise archive (EAR) file. You can assemble the artifacts that are required to enable the Web services-enabled JAR file into an EAR file.

  11. Enable the EAR file. When the EAR file contains enterprise bean modules, it must have the Web services endpoint WAR file added with the endptEnabler tool before it is deployed.

  12. Deploy the EAR file into WAS.

    This topic presents the steps necessary to deploy the EAR file that has been configured, assembled and enabled for Web services.

 

Results

You have a Web service developed from a stateless session enterprise bean.

 

What to do next

Publish the WSDL file.



Developing a service endpoint interface from an EJB

Developing Web services deployment descriptor templates for an EJB implementation

Completing the EJB implementation

Use the JMS API to transport JAX-RPC Web services requests

Use WSDL EJB bindings to invoke an EJB from a Web services client

 

Related tasks


Developing a WSDL file for JAX-RPC applications
Assembling a JAR file that is enabled for Web services from an enterprise bean
Assembling an enterprise bean JAR file into an EAR file
Enabling an EAR file for Web services
Deploying Web services applications onto appservers
Developing Web services applications from existing WSDL files with enterprise beans

 

Related Reference


Artifacts used to develop Web services
Web services specifications and APIs
Web services: Resources for learning