Feature
The SOAP component is a Binding Component (BC) which enables to interact with external Web Services and to expose JBI services as Web Services.
In provider role, when a JBI MessageExchange is sent to a ServiceEndpoint (mapped to a Web Service), it is transformed into a SOAP message and sent to the linked external Web Service. In consumer role, when a SOAP message is received on an exposed Web Service, transformed into a JBI MessageExchange and sent to the corresponding JBI ServiceEndpoint.
The SOAP component is based on Apache Axis2 v1.4.1 (http://ws.apache.org/axis2/) and Mortbay Jetty v6.1.9 (http://jetty.codehaus.org/jetty/). It provides the following features :
- Expose JBI Services as Web Services
- Expose Web Services as JBI Services
- Handle SOAP attachments. The attachments of the incoming SOAP message are placed into the JBI message as attachments; the JBI attachments are placed in the outgoing SOAP message as attachments.
Exposing an external Web Service as a JBI service endpoint
In provide mode, the component exposes an external Web Service in the JBI environment to send SOAP requests to the external Web Service.
Usage
Configuration
Configuration of a Service Unit to provide a service (JBI)
| Parameter |
Description |
Default |
Required |
| provides |
Describe the JBI service that will be exposed into the JBI bus. Interface (QName), Service (QName) and Endpoint (String) attributes are required. |
- |
Yes |
Configuration of a Service Unit to provide a service (CDK)
| Parameter |
Description |
Default |
Required |
| timeout |
Timeout in milliseconds of a synchronous send. This parameter is used by the method sendSync (Exchange exchange) proposes by the CDK Listeners classes.
Set it to 0 for an infinite timeout. |
30000 |
No |
| exchange-properties |
This sections defines the list of properties to set to the JBI exchange when processing a service. |
- |
No |
| message-properties |
This sections defines the list of properties to set to the JBI message when processing a service. |
- |
No |
| validate-wsdl |
Activate the validation of the WSDL when deploying a service unit. |
true |
No |
wsdl |
Path to the WSDL document describing services and operations exposed by the provided JBI endpoints defined in the SU.
The value of this parameter is :
- an URL
- a file relative to the root of the SU package
If not specified, a basic WSDL description is automaticaly provided by the CDK.
|
- |
No |
forward-attachments |
Defines if attachment will be forwarded from IN message to OUT message. |
false |
No |
forward-message-properties |
Defines if the message properties will be forwarded from IN message to OUT message. |
false |
No |
forward-security-subject |
Defines if the security subject will be forwarded from IN message to OUT message. |
false |
No |
Service Unit attributes to provide services
| Attribute |
Description |
Default value |
Required |
| soap-version |
The SOAP version used to create SOAP messages.
Possible values are 1.1 and 1.2. |
1.1
|
Yes
|
| address |
Address of the external Web Service to send JBI messages to. |
|
Yes
|
| chunked-mode |
Activate the HTTP chunked mode on Web Service calls.
Possible values are: true, false. |
false
|
Yes
|
| synchronous-timeout |
The timeout value when invoking a external service.
 | Note This value override the CDK value. |
The value is expressed in milliseconds. |
|
No
|
| cleanup-transport |
Cleanup the transport after the call of the external Web Service.
Not cleaning up the transport can cause timeouts on large number of calls.
Possible values are: true, false. |
true
|
Yes
|
| mode |
The mode to be used to send SOAP message to the specified address.
Possible values are: SOAP for basic Web Service calls, JSON for JSON service calls and REST for REST service calls. |
SOAP
|
Yes
|
| enable-compatibility-for |
Enables the compatibility with a specified Web Service stack.
Possible values are: AXIS1 for Axis 1 Web Service stack. |
|
No
|
| proxy-host |
The proxy host name.
If it is not set, the proxy mode will be disabled and all others proxy parameters are ignored. |
|
No
|
| proxy-port |
The proxy host port. |
|
No
|
| proxy-user |
The proxy user. |
|
No
|
| proxy-password |
The proxy password. |
|
No
|
| proxy-domain |
The proxy domain. |
|
No
|
| rest-http-method |
The HTTP method to be used in REST mode.
Possible values are: GET for the HTTP method GET, POST for the HTTP method POST, PUT for the HTTP method PUT and DELETE for the HTTP method DELETE. |
|
No
|
Service Unit descriptor
The service unit is configurable via its extensions in the jbi.xml file:
<?xml version="1.0" encoding="UTF-8"?>
<jbi:jbi version="1.0"
xmlns:generatedNs="http://petals.ow2.org/"
xmlns:jbi="http://java.sun.com/xml/ns/jbi"
xmlns:petalsCDK="http://petals.ow2.org/components/extensions/version-5"
xmlns:soap="http://petals.ow2.org/components/soap/version-4"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
<jbi:services binding-component="true">
<jbi:provides
interface-name="generatedNs:IntegrationService"
service-name="generatedNs:IntegrationService"
endpoint-name="IntegrationServiceSOAP">
<petalsCDK:timeout>1000</petalsCDK:timeout>
<petalsCDK:validate-wsdl>true</petalsCDK:validate-wsdl>
<petalsCDK:forward-security-subject>false</petalsCDK:forward-security-subject>
<petalsCDK:forward-message-properties>false</petalsCDK:forward-message-properties>
<petalsCDK:forward-attachments>false</petalsCDK:forward-attachments>
<petalsCDK:wsdl>IntegrationService.wsdl</petalsCDK:wsdl>
<soap:address>http://localhost:8088/mockIntegrationServiceSOAP</soap:address>
<soap:soap-version>1.1</soap:soap-version>
<soap:chunked-mode>false</soap:chunked-mode>
<soap:cleanup-transport>true</soap:cleanup-transport>
<soap:mode>SOAP</soap:mode>
</jbi:provides>
</jbi:services>
</jbi:jbi>
Service Unit content
The Service Unit has to contain the following elements, packaged in an archive:
- The META-INF/jbi.xml descriptor file, has described above,
- An optional imported WSDL file describing the partner service
Exposing an internal JBI service endpoint as a Web Service
In consumer mode, the component exposes an internal JBI service outside the bus to transfer incoming SOAP requests to the internal service.
Usage
Configuration
Configuration of a Service Unit to consume a service (JBI)
| Parameter |
Description |
Default |
Required |
| consumes |
Refer JBI service to invoke into the JBI bus.
You can define an explicit endpoint: interface (QName) / Service (QName) / Endpoint (String) attributes.
Or define implicit endpoint, to let the container routing according to QOS configurations (HA...):
-by Interface attribute (QName)
-by Service attribute (QName) |
- |
Yes |
Configuration of a Service Unit to consume a service (CDK)
| Parameter |
Description |
Default |
Required |
| mep |
Message exchange pattern abbreviation. This parameter can be used in conjunction with the method of the CDK Listeners: createMessageExchange(Extensions extensions).
This method returns a CDK Exchange corresponding to the type of the specified pattern. |
- |
Yes |
| operation |
Operation to call on a service. This parameter can be used in conjunction with the sending methods of the Listeners. If no operation is specified in the Message Exchange to send, this parameter will be used. |
- |
No |
| timeout |
Timeout in milliseconds of a synchronous send. This parameter can be used in conjunction with the sendSync(Exchange exchange) method of the Listeners. Set 0 for an infinite timeout. |
30000 |
No |
Service Unit attributes to consume services
| Attribute |
Description |
Default value |
Required |
| service-name |
Web Service name to expose. |
|
No
|
| soap-action |
The SOAP action QName to be used for the Web Service, will override the JBI message operation. |
|
No
|
| synchronous-timeout |
The timeout value when inoking a service in the JBI bus.
 | Note This value override the CDK value. |
The value is expressed in milliseconds. |
|
No
|
| mode |
The mode to be used to receive messages.
Possible values are: SOAP for basic Web Service messages, JSON for JSON service messages and REST for REST service messages. |
SOAP
|
Yes
|
| enable-compatibility-for |
Enables the compatibility with a specified Web Service stack.
Possible values are: AXIS1 for Axis 1 Web Service stack. |
|
No
|
| enable-http-transport |
Enable the HTTP transport layer to send or receive SOAP messages.
Possible values are: true, false. |
true
|
No
|
| enable-jms-transport |
Enable the JMS transport layer to receive SOAP messages.
Possible values are: true, false. |
false
|
No
|
| http-services-redirection |
HTTP redirection alias(es) for exposed Web Service. |
|
No
|
| service-parameters |
Additional XML configuration for created Axis2 service as CDATA, same as the Axis 2 services.xml file one. |
|
No
|
| modules |
A list of Axis2 modules names to engage (separated by comas). |
|
No
|
| address |
Same as service-name.
 | Warning This parameter must not be used any more. service-name must be used.
|
|
|
No
|
| rest-add-namespace-uri |
The namespace URI to be used in the the generated JBI message payload. |
|
No
|
| rest-add-namespace-prefix |
The namespace prefix to be used in the the generated JBI message payload (used when NS URI is defined). |
soapbc
|
No
|
| rest-remove-prefix-on-response |
A list of NS prefixes to remove from the JBI message response (Coma Separated Values) |
|
No
|
Service Unit descriptor
The service unit is configurable via its extensions in the jbi.xml file:
<?xml version="1.0" encoding="UTF-8"?>
<jbi:jbi version="1.0"
xmlns:generatedNs="http://petals.ow2.org/"
xmlns:jbi="http://java.sun.com/xml/ns/jbi"
xmlns:petalsCDK="http://petals.ow2.org/components/extensions/version-5"
xmlns:soap="http://petals.ow2.org/components/soap/version-4"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
<jbi:services binding-component="true">
<jbi:consumes
interface-name="generatedNs:IntegrationService"
service-name="generatedNs:IntegrationService"
endpoint-name="IntegrationServiceSOAP">
<petalsCDK:timeout>500</petalsCDK:timeout>
<petalsCDK:mep xsi:nil="true" />
<soap:address>IntegrationServiceSOAPByPetals</soap:address>
<soap:mode>SOAP</soap:mode>
<soap:rest-add-namespace-prefix>soapbc</soap:rest-add-namespace-prefix>
<soap:enable-http-transport>true</soap:enable-http-transport>
<soap:enable-jms-transport>false</soap:enable-jms-transport>
</jbi:consumes>
</jbi:services>
</jbi:jbi>
Service Unit content
The Service Unit has to contain the following elements, packaged in an archive:
- The META-INF/jbi.xml descriptor file, has described above
Component Configuration
The following attributes can be set during the installation phase to configure the component, using the params element of the jbi-install-component ANT task:
Unable to render {include} Couldn't find a page to include called: 0 CDK Component Configuration Table
Specific configuration of the SOAP component
| Attribute |
Description |
Default value |
Required |
| http-port |
Port of the embedded Jetty HTTP server. |
8084
|
No
|
| http-host |
Local Hostname to be used, can be hostname or host IP address.
If this parameter is not set, all interfaces are listen. |
localhost
|
No
|
| http-service-list |
Enables to display the available Web Service list.
Possible values are: true, false. |
true
|
No
|
| http-service-context |
The URL context. |
petals
|
No
|
| http-service-mapping |
The URL service mapping. |
services
|
No
|
| http-thread-pool-size-min |
The minimum size of the HTTP thread pool. |
2
|
No
|
| http-thread-pool-size-max |
The maximum size of the HTTP thread pool. |
255
|
No
|
| http-acceptors |
Number of HTTP acceptors. |
4
|
No
|
| java-naming-factory-initial |
The initial context factory class needed to access the JNDI server where the JMS connection factory can be found. |
|
No
|
| java-naming-provider-url |
The JNDI provider URL where the JMS connection factory can be found. |
|
No
|
| jms-connection-factory-jndiname |
Name of the default JMS connection factory in the JNDI. |
|
No
|
Definition of CDK parameter scope :
- Installation: The parameter can be set during the installation of the component, by using the installation MBean (see JBI specifications for details about the installation sequence). If the parameter is optional and has not been defined during the development of the component, it is not available at installation time.
- Runtime: The paramater can be set during the installation of the component and during runtime. The runtime configuration can be changed using the CDK custom MBean named RuntimeConfiguration. If the parameter is optional and has not been defined during the development of the component, it is not available at installation and runtime times.
|
No contributors found for: authors on selected page(s)
|