Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

The ServiceMix Drools component provides JBI integration to the Drools Rules Engine.

This Service Engine can be used to deploy a rules set that will implement a router or an actual service.

A router will mostly act as a transparent proxy between the consumer and the target service provider mad will mostly be implemented by the jbi.route(uri) method below. This method creates a new exchange identical to the one received by the component and will send it to the specified destination. You can also send back a Fault if needed. A router can also be implemented by using directly the JBI Apis (available with the jbi helper) by using the provided client.

This component can also be used to implement a real service, as shown in the Fibonnacci example. The service can act as a consumer and create / send exchanges by using the client provided by the jbi helper.

Note that this component is only available in releases >= 3.1 and deprecate the older lightweight Drools component

...

Methods

Description

jbi.route(uri)

Route the current exchange to the given uri

jbi.fault(content)

Returns a fault using the given string as the xml fault

jbi.answer(content)

Sends an Out message using the given string as the xml content

...