IBM Integration Bus, Version 9.0.0.8 Operating Systems: AIX, HP-Itanium, Linux, Solaris, Windows, z/OS

See information about the latest product version

cciInputMessageCallback

The cciInputMessageCallback function can be registered as a callback and is called every time a message is read by an input node, and before that message is propagated down the message flow.

The cciInputMessageCallback function is called for every input message that is read in the integration server where the callback is registered, if the user exit state is active. The callback is registered by providing a pointer to the function as the iFpInputMessageCallback field of the CCI_UE_VFT struct that is passed to cciRegisterUserExit.

Syntax

typedef void (*cciInputMessageCallback)     ( 
                                 CciDataContext*  userContext,
                                 CciMessage*      message,
                                 CciMessage*      localEnvironment,
                                 CciMessage*      exceptionList,
                                 CciMessage*      environment,
                                 CciMessageOrigin messageOrigin,
                                 CciNode*         inputNode);

Parameters

userContext (input)
The value that is passed to the cciRegisterUserExit function.
message
A handle to the message object. The user exit code must not update transport headers or Properties elements in this tree. Updating the message can affect performance, particularly if the input message would not otherwise be changed in the message flow.
localEnvironment
A handle to the local environment object.
exceptionList
A handle to the exception list object.
environment
A handle to the environment object for the current message flow.
messageOrigin
Depending on the type of input node, the message might have originated from a bit stream (CCI_MESSAGE_ORIGIN_BITSTREAM) or from a tree (CCI_MESSAGE_ORIGIN_TREE). The user exit can access one of these sources without causing processing by the parser. For example, in the case of the MQInput node, you can access the bitstream safely whereas, in the case of the JMSInput node, you can access the tree safely. You can access the bit stream by calling cniBufferPointer, cniBufferSize, or cniBufferByte. You can access the tree by calling cniRootElement and using the usual syntax element navigation functions (for example, cniFirstChild ). Although this parameter tells the user exit what it can access safely without causing processing by the parser, the user exit code might ignore this advice and effectively alter the parse timing.
inputNode
A handle to the input node that reads this input message. The handle can be used to make calls to functions such as cciGetNodeName, cciGetNodeType, and cniGetBrokerInfo.

Return values

None.

Example

void myInputMessageCallback(
                      CciDataContext*  userContext,
                      CciMessage*      message,
                      CciMessage*      localEnvironment,
                      CciMessage*      exceptionList,
                      CciMessage*      environment,
                      CciMessageOrigin messageOrigin,
                      CciNode*         inputNode){
…
…
}

as35950_.htm | Last updated Friday, 21 July 2017