Red Hat Training

A Red Hat training course is available for Red Hat Fuse

Chapter 31. Working with the JBI Wrapper

Abstract

By default, all Apache CXF binding component endpoints expect SOAP messages to be inside of the JBI wrapper. You can turn off the extra processing if it is not required.
Important
The Java Business Integration components of Red Hat JBoss Fuse are considered deprecated. You should consider migrating any JBI applications to OSGi.

Overview

There are instances when a JBI component cannot consume a native SOAP message. For instance, SOAP headers pose difficulty for JBI components. The JBI specification defines a JBI wrapper that can be used to make SOAP messages, or any message defined in WSDL 1.1, conform to the expectations of a JBI component.
For the sake of compatibility, all endpoints exposed by the Apache CXF binding component will check for the JBI wrapper. If it is present the endpoint will unwrap the messages. If you are positive that your endpoints will never receive messages that use the JBI wrapper, you can turn off the extra processing.

Turning of JBI wrapper processing

If you are sure your endpoint will not receive messages using the JBI wrapper you can set its useJbiWrapper attribute to false. This instructs the endpoint to disable the processing of the JBI wrapper. If the endpoint does receive a message that uses the JBI wrapper, it will fail to process the message and generate an error.

Example

Example 31.1, “Configuring a Consumer to Not Use the JBI Wrapper” shows a configuration fragment for configuring a consumer that does not process the JBI wrapper.

Example 31.1. Configuring a Consumer to Not Use the JBI Wrapper

<beans xmlns:cxfbc="http://servicemix.apache.org/cxfbc/1.0"
       ... >
  ...
  <cxfbc:consumer wsdl="/wsdl/widget.wsdl"
                  useJbiWrapper="false" />
  ...
</beans>