Creating a web service client for the IBM WebSphere JAX-WS runtime environment using Ant tasks
If you have a WSDL file, you can use Ant in the Eclipse workspace to generate a web service client with the IBM® WebSphere® JAX-WS runtime environment.
Before you begin
- Create a server for your web service client.
- Optional: You can create a web project, an EJB project, a Java™ project, or a Java EE application client project into which the client code will be generated.
- Import the Ant task and properties files into your workspace.
- Optional: If you want to run the Ant task from a command line rather than in the workspace, edit the Ant batch file to point to various resources on your system: Customizing the Ant script to run JAX-WS web service Ant tasks in a command line.
- Customize the Ant properties files for your web service client: Ant properties files for web service clients for the IBM WebSphere JAX-WS runtime environment.
- Locate or create a WSDL file, or import one into the project that you created.
About this task
Procedure
Results
When your web service client is generated, the following
files are created depending on the options you selected:
- Web service client class and proxy bean.
- Request/Response/Exception wrapper classes.
Tip: The wsant.bat file
is installed in the product's bin directory.
On some systems, this directory might be read-only. In these cases,
the Ant task cannot create the output and the web service creation fails.
There are two ways to correct this problem:
- Set your PATH to point to the bin folder, change to a directory where you have write permission, and run the script from there.
- Copy the wsant.bat file to a writeable directory.