|
Key
This line was removed.
This word was removed. This word was added.
This line was added.
|
Changes (3)
View Page History dispatcher |
{table-plus}
{table-plus}
\\
The EIP Component acts as an exchange pattern bridge, and allows you, for instance, to transform an InOnly invocation pattern into an InOut one. It is used, for example, when the consumer of a service "MyService" sends its request as InOnly, and the provider is waiting an {{InOut}} message. Define in a {{consumes}} section the service you want to call, and the EIP component will match the incoming and outgoing exchange pattern as better as possible. So :
* If the source exchange needs a response (InOut or InOptionalOut patterns) and no response are received (InOnly,
RobustInOnly or InOptionalOut patterns), a default response is returned:
If the source exchange needs a response (InOut or InOptionalOut patterns) and no response are received (InOnly, RobustInOnly or InOptionalOut patterns), a default response is returned :
{code:lang=xml}<result xmlns="http://petals.ow2.org/petals-se-eip/bridge">Bridge: no content into the final target exchange</result>{code}
* If the source exchange doesn't accept a response (InOnly or RobustInOnly patterns) and a response is received (InOut or InOptionalOut patterns), the response is ignored.
* If the source exchange doesn't accept a fault (InOnly pattern) and a fault is received (RobustInOnly, InOut or InOptionalOut patterns), the fault is ignored.
* If the source exchange needs a response (InOut or InOptionalOut patterns) and no response are received (InOnly,
RobustInOnly or InOptionalOut patterns), a default response is returned:
If the source exchange needs a response (InOut or InOptionalOut patterns) and no response are received (InOnly, RobustInOnly or InOptionalOut patterns), a default response is returned :
{code:lang=xml}<result xmlns="http://petals.ow2.org/petals-se-eip/bridge">Bridge: no content into the final target exchange</result>{code}
* If the source exchange doesn't accept a response (InOnly or RobustInOnly patterns) and a response is received (InOut or InOptionalOut patterns), the response is ignored.
* If the source exchange doesn't accept a fault (InOnly pattern) and a fault is received (RobustInOnly, InOut or InOptionalOut patterns), the fault is ignored.
An example of service unit configuration :
{code:lang=xml}<?xml version="1.0"?>
<!-- JBI descriptor for the PEtALS component "EIP" -->
<jbi:jbi version="1.0"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns:jbi="http://java.sun.com/xml/ns/jbi"
xmlns:petalsCDK="http://petals.ow2.org/components/extensions/version-5"
xmlns:eip="http://petals.ow2.org/components/eip/version-2"
xmlns:test="http://petals.ow2.org/test">
<jbi:services binding-component="false">
<jbi:provides
interface-name="test:splitter"
service-name="test:splitterService1"
endpoint-name="splitterService1Endpoint">
<petalsCDK:wsdl xsi:nil="true" />
<eip:eip>splitter</eip:eip>
<eip:fault-to-exception>false</eip:fault-to-exception>
<eip:test>/*[local-name()='helloworld' and namespace-uri()='http://petals.ow2.org/test']/*[local-name()='split']</eip:test>
<eip:fault-robust>false</eip:fault-robust>
<eip:exception-robust>false</eip:exception-robust>
<eip:attachment-mode>false</eip:attachment-mode>
</jbi:provides>
<jbi:consumes interface-name="test:splitterProvider"
service-name="test:splitterProviderService1"
endpoint-name="splitterProviderService1Endpoint">
<petalsCDK:operation xmlns:petals="http://org.ow2.petals">petals:operation</petalsCDK:operation>
<petalsCDK:mep>InOut</petalsCDK:mep>
</jbi:consumes>
</jbi:services>
</jbi:jbi>{code}
{note:title=Caution}{{{}consumes}} sections cardinality is 1{note}
{code:lang=xml}<?xml version="1.0"?>
<!-- JBI descriptor for the PEtALS component "EIP" -->
<jbi:jbi version="1.0"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns:jbi="http://java.sun.com/xml/ns/jbi"
xmlns:petalsCDK="http://petals.ow2.org/components/extensions/version-5"
xmlns:eip="http://petals.ow2.org/components/eip/version-2"
xmlns:test="http://petals.ow2.org/test">
<jbi:services binding-component="false">
<jbi:provides
interface-name="test:splitter"
service-name="test:splitterService1"
endpoint-name="splitterService1Endpoint">
<petalsCDK:wsdl xsi:nil="true" />
<eip:eip>splitter</eip:eip>
<eip:fault-to-exception>false</eip:fault-to-exception>
<eip:test>/*[local-name()='helloworld' and namespace-uri()='http://petals.ow2.org/test']/*[local-name()='split']</eip:test>
<eip:fault-robust>false</eip:fault-robust>
<eip:exception-robust>false</eip:exception-robust>
<eip:attachment-mode>false</eip:attachment-mode>
</jbi:provides>
<jbi:consumes interface-name="test:splitterProvider"
service-name="test:splitterProviderService1"
endpoint-name="splitterProviderService1Endpoint">
<petalsCDK:operation xmlns:petals="http://org.ow2.petals">petals:operation</petalsCDK:operation>
<petalsCDK:mep>InOut</petalsCDK:mep>
</jbi:consumes>
</jbi:services>
</jbi:jbi>{code}
{note:title=Caution}{{{}consumes}} sections cardinality is 1{note}
h3. Router Pattern