Configure the webservices.xml deployment descriptor for Handler classes

This topic explains how to use the Assembly Toolkit to configure the webservices.xml deployment descriptor for user-provided Handler classes. The Assembly Toolkit is a component of the Application Server Toolkit. For more information about completing tasks with the Assembly Toolkit, click Help > Help in the Assembly Toolkit graphical user interface (GUI).

You should have an EAR file for the applications you want to configure. For some handler use, such as logging or tracing, only the server or client application needs to be configured. For other handler use, including sending information in SOAP headers, the client and server applications must be configured with symmetrical handlers.

The modules in the EAR file should contain the handler classes being configured. These classes implement the javax.xml.rpc.handler.Handler interface. For more information on writing handler classes, see Chapter 6 of the Web Services for J2EE 1.0 specification and chapter 12 of the JAX-RPC 1.0 specification available through Web services: Resources for learning. The application modules must contain the webservices.xml(for server) and webservicesclient.xml (for client) deployment descriptors.

To configure a handler in the webservices.xml deployment descriptor...

  1. Start the Assembly Toolkit.

  2. Click File > Import and import the EAR file into the Assembly Toolkit.

  3. Open the J2EE perspective by clicking Windows >Open Perspective > Other >J2EE.

  4. Click the Project Navigator tab to switch to the Project Navigator pane.

  5. Locate the project that contains the webservices.xml deployment descriptor.Expand the directories under the project until the META-INF or WEB-INF directory and its contents, including the webservices.xml file, are visible.

  6. Right-click the webservices.xml file.

  7. Click Open.The Web Services editor opens.

  8. Expand the Web services descriptions section.

    1. Select the service for which you want to configure the handler.

  9. Expand the Port components section.

  10. Select a port_component for which you want the editor to open.The Port Components editor opens.

  11. Expand the Port component handlers section.

  12. Click Add at the bottom of the Port component handlers section. A Class browser opens.

  13. Browse for the name of the Handler class in the module. When it displays in the Matching types field, select the class and click OK. The Class browser window closes after you click OK and the Handlers pane of the Web Services Editor opens.

  14. (Optional) Configure properties in the Handlers pane. See Handler class properties for a list of the properties you can configure in this step.

  15. Type ctrl-s to save the changes.

 

See Also

Configuring the webservicesclient.xml deployment descriptor for Handler classes
Handler class properties
Configure Handler classes for Web services deployment descriptors