Web Service Clients

The web wervice clients configuration contains the definition of all web services, which can be consumed from a BPM process.

Web Service Clients Editor

Web Service Clients Editor

Web Service Clients Tree

Shows the web service clients.

  • Add Client Adds a new web service client configuration.

  • Remove Remove the current selection.

Client Details Editor

Details of currently selected web service configuration node are displayed on the right hand side. In this editor details of an tree element can be changed.

Web Service Client Section

The following attributes are available in the Web Service Section:

  • Name The name attribute specifies the displayed name of a web service configuration. The name is not used as identifier, so it can be changed at any time.

  • Icon Choose an icon that represents the system that this web service communicates with. The icon will also be used as decorator icon on Web Service process elements that references this web service.

  • Description Description of the web service. This field is for documentation purposes only.

  • WSDL URL Service details and classes will be generated using the WSDL specified here. Please use protocol prefix like: http://myserver.ch/hello.wsdl or file://c:tempmyWis.wsdl

  • Library The library that is used to generate the web service client classes. Note that you have to regenerate the web service client classes if you change this setting.

  • Generate WS classes After specifying the mandatory fields WSDL URL and Library you can click the Generate WS classes button to read the WSDL and generate client side classes. The generated files will be compiled and packaged into a jar file. The generated jar file will be located in the lib_ws/client folder of ivy project and automatically added to the project libraries.

Note

When you change the WSDL URL, the WSDL itself or the Library setting you always have to re-generate the service classes.

Authentication Section

Authentication Section

Authentication Section

Configures the authentication that is sent to the remote web service. The following attributes are available in the Authentication section:

  • Type The authentication type to be used. The available authentication types depends on the selected library.

  • Username Name of the user used to authenticate the client. Will be stored as a property.

  • Password Password of the user used to authenticate the client. Will be stored as a property.

Tip

Authentication properties like (username and password) can be overridden in the Web Service Call Activity that performs the call to the remote service. On these activities authentication properties can contain scripted/dynamic values.

Features Section

Features Section

Features Section

Features add optional functionality to a web service client call execution.

  • Add Adds a new feature class to the list. All specified feature classes must implement the JAX-WS standard class javax.xml.ws.WebServiceFeature or ch.ivyteam.ivy.webservice.exec.feature.WebServiceClientFeature.

  • Remove Removes the selected feature class from the list.

Properties Section

Properties Section

Properties Section

Properties configure the web service client and its features. Some well known properties are documented here: javax.xml.ws.BindingProvider

  • Add Adds a new property.

  • Add Password Adds a new password property. The value of a password property is not visible in the table and is stored encrypted in the configuration file.

  • Remove Removes the selected property.

Tip

In order to configure SSL client authentication for a web service, you need to specify the property SSL.keyAlias. The value of this alias needs to correspond with a key alias available in the client keystore configured under SSL Client Settings.

Endpoint URI Section

Endpoint URIs Section

Endpoint URIs Section

The following attributes are available in the Ports section:

  • Ports The list of ports is available after web service client classes generation. (see: Generate WS classes). The content of this list originates from the specified WSDL and is filled with information from the client framework.

  • Default URI The URI where the current web service is located. The initial URI is derived from the WSDL. But one can override this setting if the address has changed. It can also be overridden per environment. For instance to route calls during development to test instance of the service.

  • Fallback URIs An optional list of URIs. They are used as fallback URI if any error happens during the web service request. The default endpoint will be called first, then the fallback URI in the appearing order. Servers on the list are queried one by one until a successful web service access can be made. You find error messages in the runtime log when endpoint invocations fail. If a service invocation is successful then the process continues as normal.

    This list is optional. If this list is empty and no default URI is specified then an exception is raised during the call and the process continues with error handling.

Dynamic endpoint URIs

You may need to adapt the endpoint URI to call according to your runtime environment. E.g. if you have different endpoints for staging and production. Therefore we support Dynamic Configuration expressions in URIs. As as en example, an endpoint URI defined as http://${ivy.var.erpHost}/soap/service will consume the host to call from the variable named erpHost.

The same mechanisms also work in properties alike, so you can also re-use a variable to inject the credentials used to authenticate the service call.