LibraryToggle FramesPrintFeedback

The jbi component is implemented by the ServiceMix Camel module and provides integration with a JBI Normalized Message Router, such as the one provided by Apache ServiceMix.


See below for information about how to use StreamSource types from ServiceMix in Apache Camel.

The following code:


Automatically exposes a new endpoint to the bus, where the service QName is {}MyService and the endpoint name is MyEndpoint (see URI format).

When a JBI endpoint appears at the end of a route, for example:


The messages sent by this producer endpoint are sent to the already deployed JBI endpoint.


The separator that should be used in the endpoint URL is:

For more details of valid JBI URIs see the ServiceMix URI Guide.

Using the jbi:service: or jbi:endpoint: URI formats sets the service QName on the JBI endpoint to the one specified. Otherwise, the default Apache Camel JBI Service QName is used, which is:


You can append query options to the URI in the following format, ?option=value&option=value&...

Name Default value Description
mep MEP of the Camel Exchange Allows users to override the MEP set on the Exchange object. Valid values for this option are in-only, in-out, robust-in-out and in-optional-out.
operation Value of the jbi.operation header property Specifies the JBI operation for the MessageExchange. If no value is supplied, the JBI binding will use the value of the jbi.operation header property.
serialization basic Default value (basic) will check if headers are serializable by looking at the type, setting this option to strict will detect objects that can not be serialized although they implement the Serializable interface. Set to nocheck to disable this check altogether, note that this should only be used for in-memory transports like SEDAFlow, otherwise you can expect to get NotSerializableException thrown at runtime.
convertException false false: send any exceptions thrown from the Camel route back unmodified true: convert all exceptions to a JBI FaultException (can be used to avoid non-serializable exceptions or to implement generic error handling

If you have some Apache Camel routes that you want to deploy inside JBI as a Service Unit, you can use the JBI Service Unit Archetype to create a new Maven project for the Service Unit.

If you have an existing Maven project that you need to convert into a JBI Service Unit, you may want to consult ServiceMix Maven JBI Plugins for further help. The key steps are as follows:

  • Create a Spring XML file at src/main/resources/camel-context.xml to bootstrap your routes inside the JBI Service Unit.

  • Change the POM file's packaging to jbi-service-unit.

Your pom.xml should look something like this to enable the jbi-service-unit packaging:

<project xmlns="" xmlns:xsi=""



  <name>A Apache Camel based JBI Service Unit</name>







      <!-- creates the JBI deployment unit -->

For more information, see the following references:

Comments powered by Disqus