2.3.13 Transactional ATMI Conversational Client to Host CPI-C, Server Gets Control
Figure 2-33 DMCONFIG File Entry
- ATMI client invokes
toupsrv
service. - The
toupsrv
service issuestpbegin
to start the transaction. - The
toupsrv
service issues atpconnect
service request forSIMPCPIC
, which is advertised in the DM_REMOTE_SERVICES section of the DMCONFIG file. Data is sent in theidata
buffer on thetpconnect
. - The remote service with
tpname
TPNCPIC
invokesTOUPCPIC
program. - The server accepts the conversation with the
cmaccp
call. The conversation ID returned on the request inconvid
is used for all other requests during this conversation. - The
cmrcv
request receives theidata
buffer contents sent on thetpconnect
for processing. - The
TOUPCPIC
program processes the data. - The
cmsend
returns theobuffer
contents into the client’stprecv
odata
buffer. The buffer contents may not be sent immediately. - The
cmsptr
prepares the prepare-to-receive request withCM_PREP_TO_RECEIVE_CONFIRM
. Thecmptr
request withCONFIRM
indicates that the conversation is finished and is communicated to thetprecv
asTPEV_SVCSUCC
. - The
toupsrv
issues thetpcommit
to successfully complete the transaction and commit all updated resources. Thecmrcv
request receives the commit request and responds explicitly to the request with the SAA Resource/Recovery commit callsrrcmit
. The conversation is ended after the successful commit exchange.
Parent topic: CPI-C Programming Examples