IBM BPM, V8.0.1, All platforms > Programming IBM BPM > Enterprise Service Bus programming > Invocation of Services > Service Invoke and Callout nodes

Comparison of the Service Invoke mediation primitive and the Callout node

You can call a service using either a Service Invoke mediation primitive or a Callout node. You must consider the similarities and differences between using either the Service Invoke mediation primitive and the Callout node.

Similarities between the Service Invoke mediation primitive and the Callout node:

Differences between the Service Invoke mediation primitive and the Callout node:

Although, there is a functional similarity between the Service Invoke mediation primitive and the Callout node, the Service Invoke mediation primitive does not replace the Callout node. Consider the following when deciding whether to use the Service Invoke mediation primitive or the Callout node:

Considerations for using the Service Invoke mediation primitive or the Callout node
Use the Service Invoke if Use the Callout if
You need to call a service and return the response within a mediation flow. You need to mediate a message (without calling an intermediate service) and then call a service provider. The Callout provides the simplest model for this configuration.
You need to interact with multiple services, and produce an output that combines service responses.  
You need to call an intermediate service.

For example, you might use an intermediate service to adjust a message, or validate a message externally. The mediation flow contains a Service Invoke mediation primitive, and a Callout node that is connected to the service provider.

 

Service Invoke and Callout nodes