
Synchronous messages have the quality of service Best Effort. On the one hand, the application must ensure that there are no duplicate messages or data losses. On the other hand, the application receives error messages. Best Effort also means that no transactional concepts are involved.
Synchronous response message: Open CCIInteraction..java and search for the character string CS_SYNCRESP.
Application error: Open CCIInteraction.java and search for the character string CS_SYNCAPPERR.
If the adapter receives such an XIInteractionSpec, it must return an instantiated and filled XIMessageRecord (in the case of a successful response message or an application error) in the XIInteractionSpec.execute() call or, if an error occurs, XIAdapterException.
Your last module must return a response message to the module processor to be called.
You can read or set the following ErrorInfo attributes:
| Name | Description |
|---|---|
|
ErrorCode |
Application error code |
|
ErrorArea |
Contains the adapter namespace and the adapter type |
|
ErrorCategory |
Must be set to Application |
|
AdditionalErrorText |
Text for the application error |
|
ApplicationFaultInterface |
Specifies in the Enterprise Services Repository the interface that processes the application error messages |
|
ApplicationFaultInterfaceNamespace |
Namespace of the interface |
The following methods are available for reading and setting the attributes:
…
try {
myRespMsg = myAdapter.call(myReqMsg);
if (myRespMsg != null) //synchronous
moduleData.setPrincipalData((Object) myRespMsg.getXIMessage());
else // asynchronous
moduleData.setPrincipalData(null);
…
catch(Exception e) {
{
TRACE.catching(SIGNATURE, e);
ModuleException me = new ModuleException("Temporary error: Adapter call failed. Reason: " + e.getMessage(), e);
TRACE.throwing(SIGNATURE, me);
throw me;
}
…