IBM BPM, V8.0.1, All platforms > Authoring services in Integration Designer > Services and service-related functions > Building mediation flows > Implementing custom mediation logic

Tips for creating Custom mediation primitives

A custom mediation primitive allows you to implement your custom Java™ logic in a mediation flow.

Consider these tips when creating your custom mediation primitive.


Ready-made visual snippets

A custom mediation primitive must include code to access message information. Use the ready-made visual snippets to easily write this code. You can find the custom snippets in the SMO services folder in the Visual Snippet view, as shown below:


Specify the message type in the Properties view

For most mediation primitives, the mediation flow editor detects the message types and only allows you to wire primitives that have compatible message types. However for custom mediation primitives, the message type is unknown to the editor. Before you wire your custom mediation primitive, specify its message type in the Terminals tab of the Properties view to ensure that the primitive can be wired only to primitives of a compatible type:

To specify the message type in the Terminals tab view, select the terminal, and click Change, as shown below:

.

Implementing custom mediation logic