Resolving problems when you use callable flows

Diagnose problems with callable flows by using the Callable Flows view or by running commands.

Before you begin

Read the concept information in Callable message flows.

About this task

If problems occur when you develop callable flows, complete the following checks.

Validate messages before they reach the CallableFlowInvoke or CallableFlowAsyncInvoke node

About this task

The CallableFlowInvoke and CallableFlowAsyncInvoke nodes parse the incoming message in full so that it is in a suitable format to send to the CallableInput node. Therefore, you should validate the message before it reaches the CallableFlowInvoke or CallableFlowAsyncInvoke node. If the call fails due to a parsing failure, the message is rolled back with an exception.

Binary Large Object (BLOB) messages do not need to be parsed. Therefore, if you do not want to parse the message data before the CallableFlowInvoke or CallableFlowAsyncInvoke node, you can send data to the callable flow by using the BLOB parser.

Ensure that the unique identifier on the CallableFlowAsyncInvoke node is the same as on the CallableFlowAsyncResponse node

About this task

The unique identifier that is specified on the CallableFlowAsyncInvoke node must match exactly the unique identifier that is specified on the CallableFlowAsyncResponse node.

Ensure that application and endpoint name pairs are unique in a single integration and on a single integration server

About this task

Application and endpoint name pairs must be unique in a single integration. You can have multiple callable flows that have the same application and endpoint names, but they must be in different integrations. In this case, the Switch server acts as a load balancer. You can run multiple integrations in the same space if you have an on-demand subscription. If you are splitting flows between IBM Integration Bus on Cloud and IBM Integration Bus, application and endpoint name pairs must be unique on a single integration server. If you have multiple callable flows with the same application and endpoint names, they must be on different integration servers.

Check that your callable flows are registered with the Switch server

About this task

The Switch server routes data between your callable message flows, so these flows must be registered with the Switch server. When you upload BAR files to IBM Integration Bus on Cloud, message flows that contain CallableFlowInvoke, CallableFlowAsyncInvoke, CallableFlowAsyncResponse, or CallableInput nodes are registered with the Switch server automatically. If you have split your flows between IBM Integration Bus on Cloud and IBM Integration Bus, you configure a connectivity agent on premises to allow your on-premises flows to communicate with the Switch server.

Using the Callable Flows view

If one or more of your callable flows are in IBM Integration Bus on Cloud, you can check that they are registered with the Switch server in the Callable Flows view. This view lists all callable flows that are registered with the Switch server. You can show just the callers (the calling flows that contain CallableFlowInvoke or CallableFlowAsyncInvoke nodes) or the providers (the callable flows that contain CallableInput and CallableReply nodes).
The image shows a list of two providers and a caller in the Callable Flows view

For each calling flow (caller), the Callable Flows view shows the application and endpoint names of the CallableInput nodes that are called. You can also see when the CallableFlowInvoke or CallableFlowAsyncInvoke node was registered with the Switch server, and where the calling flow is running (either the cloud or the name of the on-premises integration node and integration server).

For each callable flow (provider), the Callable Flows view shows the application and endpoint names of the CallableInput node in that flow. You can also see when the CallableInput was registered with the Switch server, and where the callable flow is running.

If your on-premises flows are not listed in the Callable Flows view, restart the IBM Integration Bus integration server, then refresh the IBM Integration Bus on Cloud web page in your browser.

Using the mqsireportproperties command

You can also use the mqsireportproperties command to list the calling and callable flows that are registered on premises for a specified integration server. Run the following mqsireportproperties command for each integration server:
mqsireportproperties integrationNodeName -e integrationServerName -o CallableFlowManager -r
The following example shows a typical response.
CallableFlowManager
  uuid='CallableFlowManager'
  userTraceLevel='none'
  traceLevel='none'
  userTraceFilter='none'
  traceFilter='none'
  remoteRetryTimeout='60'
  retryLocalDuringDeploy='true'
  retryRemoteUntilTimeout='true'
  vrmfIntroducedAt='10.0.0.4'
Registrations
  CallableFlow
    applicationName='app2'
    endpointName='callableEndpoint1'
    inputNodeRegistered='0x0000000006AF8480'
    invokeNodeCount='1'
    queueDepth='0'
  CallableFlow
    applicationName='app4'
    endpointName='callableEndpoint2'
    inputNodeRegistered='0x0000000000000000'
    invokeNodeCount='1'
    queueDepth='0'

A message flow that calls a callable flow contains either a CallableFlowInvoke node or a CallableFlowAsyncInvoke node. Therefore, if a calling flow is deployed to the server, the invoke node count is 1. The mqsireportproperties command also specifies the application name and endpoint name that the calling flow is using to call the callable node.

A callable flow contains a CallableInput node. If a callable flow is deployed to the server, the inputNodeRegistered value is greater than zero. The mqsireportproperties command also specifies the name of the application that contains the callable flow, and the endpoint name that is set on the CallableInput node of the callable flow.

If both the calling and the callable flow are deployed to the same integration server, the invokeNodeCount value is 1, and the inputNodeRegistered has a value that is greater than zero. In the example, the inputNodeRegistered value indicates that a callable flow with an endpoint name of callableEndpoint1 is deployed to this server in an application called app2. The invokeNodeCount value of 1 indicates that the flow that calls this callable flow is also deployed to this server. However, the inputNodeRegistered value is zero for the callable flow in application app4 with an endpoint name of callableEndpoint2, but the invoke node count is 1. Therefore, the calling flow is deployed to this server, but the callable flow is not.