After you have created a Web service you can generate sample JSPs
which can be run on the server to test the Web service.
To generate a sample JSP to test a Web service:
- Select your Java bean in the Project Explorer, right-click and
select Web services > Generate sample JSPs.
- On the Web Service Client Test page you have the following options:
- Test the generated proxy: If selected, the sample client will be launched
in a Web browser enabling you to test the functionality.
- Select your test facility. Select whether you want to generate JAX-RPC
sample JSPs.
- Folder: You can select the preexisting folder where the JSP will be located.
- Methods: Select the methods to expose. If you selected to enable asynchronous
invocation, the asynchronous methods should be listed as well.
- Run test on server: this will start the server for you automatically.
- The proxy is launched in a Web browser at the following URL: http://localhost:port/WebProjectClient/sampleBeanName/WebServiceName/TestClient.jsp You
can use this sample application to test the Web service by selecting a method,
entering a value for the method, and clicking Invoke. The result of
the method will display in the results pane.