Implementing Service-to-Service Calls in a Java Service

A Java service can call any other service through the Java service proxy interface. The Java Service editor provides drag-and-drop support to add service invocations to your Java method implementations.

To add a service invocation to a Java service operation:

  1. Use the Java Service Editor to open the service file that you want to edit, then display the Service Interface page.

  2. Display the Service Explorer and navigate to the service you want to call. Expand the service interfaces to show the operation that you want to call.

  3. Drag the operation from the Service Explorer to the Java Service editor, and drop it on the Java service operation that is to implement the service invocation.

  4. The Java Service editor generates a proxy for the service if a proxy does not already exist, then adds a call to the Java proxy method that corresponds to the service operation to invoke.

  5. Display the Source page to view the proxy method call in the source. Modify the code to change the assignment of parameters and return values, and optionally add code to handle exceptions that may be thrown by the service invocation.

Viewing Services and Service Operations in the Service Explorer

Generating Java Service Proxies

Calling Java Proxy Methods

Handling Exceptions in a Java Service

Send your feedback on this help topic to Sybase Tech Pubs: pubs@sybase.com