Saturday, August 29, 2009

Creation of a simple Web Service

It is important to understand what a webservice is, WSDL and how to create one so that you understand the orchestration of services.
Here you will learn how to create a simple web service that calculates the APR based on the FICO score.

What you will learn
  1. Creation of Application and Project in JDeveloper
  2. Creation of a simple WebService
  3. Understand the WSDL
  4. Test the webservice
  5. Deploy the webservice
Steps to follow
  • In JDeveloper, select "New Application" in "Application Navigator"
  • To create the Application, enter the "Application Name", "Directory" as shown below
  • To create the project, enter the "Project Name" and "Technologies" as shown below
  • Finish the creation of the project
  • Create a new Java Class as follows
  • Enter the name of class as "CreditService" and accept the other defaults
  • Declare the class to be a WebService
  • Configure web.xml for this service. Select "Jave EE 1.5, with support for JAXWS Annotations" as the deployment platform.
  • Create a getCreditRating() method and declare it as WebMethod

  • Test as WebService
  • The JDeveloper starts the Weblogic server, runs the webservice and launches the test analyzer. Enter the input and the service returns the output.

  • TODO The WSDL is to be explained

No comments:

Post a Comment