theLink 10.0
Loading...
Searching...
No Matches
MqContextC_SendApi_Basics_PY_API

MqContextC - finish the send-data-block and call synchronous/asynchronous a remote-serviceMore...

+ Collaboration diagram for MqContextC_SendApi_Basics_PY_API:

Functions

static OT_ProcRet pymqmsgque_MqContextC_SendEND (MqContextC_ARGS)
  Python: ctx.SendEND(token:string[4], ?timeout:MkTimeoutE|int32=DEFAULT?) C-API
MqContextC - finish the send-data-block and call synchronous/asynchronous a remote-service
 
static OT_ProcRet pymqmsgque_MqContextC_SendEND_AND_CALLBACK (MqContextC_ARGS)
  Python: ctx.SendEND_AND_CALLBACK(token:string[4], callback:callable, ?timeout:MkTimeoutE|int32=DEFAULT?) C-API
finish the send-data-block, call the remote service, do not-wait for the result but expect the result on a callback
 
static OT_ProcRet pymqmsgque_MqContextC_SendEND_AND_SUB (MqContextC_ARGS)
  Python: ctx.SendEND_AND_SUB(token:string[4], callback:callable, ?timeout:MkTimeoutE|int32=DEFAULT?) C-API
finish the send-data-block, call the remote service, do wait for the result and expect multiple sub-results on a callback
 
static OT_ProcRet pymqmsgque_MqContextC_SendEND_AND_TRANSACTION (MqContextC_ARGS)
  Python: ctx.SendEND_AND_TRANSACTION(token:string[4], callback:string[4], ?timeout:MkTimeoutE|int32=DEFAULT?) C-API
finish the send-data-block, call the remote service to do a longterm-transaction-call
 
static OT_ProcRet pymqmsgque_MqContextC_SendEND_AND_WAIT (MqContextC_ARGS)
  Python: ctx.SendEND_AND_WAIT(token:string[4], ?timeout:MkTimeoutE|int32=DEFAULT?) C-API
finish the send-data-block, call the remote service and wait for result…
 
static OT_ProcRet pymqmsgque_MqContextC_SendSTART (MqContextC_ARGS)
  Python: ctx.SendSTART() C-API
initialize the send-data-package. …
 
static OT_ProcRet pymqmsgque_MqContextC_SendSYNC (MqContextC_ARGS)
  Python: ctx.SendSYNC() C-API
garantee that all pending asynchronous-service-calls are processed. …
 

Detailed Description

MqContextC - finish the send-data-block and call synchronous/asynchronous a remote-service

calling a remote service and wait timeout seconds for an result. If timeout == 0 it is an asynchronous-service-call and if the timeout > 0 it is a synchronous-service-call.

service-call blocking timeout
synchronous yes timeout > 0
asynchronous no timeout == 0

blocking mean waiting max timeout seconds to finishing the service-call:

If an error was raised on the server during the service-processing… the following error-handling will be available

  1. on a synchronous-service-call the error will be the result of the service-call
  2. on a asynchronous-service-call with callback the error will be the result of the callback
  3. on a asynchronous-service-call without callback the error will be send asynchronous from the server to the client . On the client the error will be raised on the NEXT event-handlng-command or as background-error if the MqSetupS::BgError function was defined.
Parameters
[in]mkrtthe MkRuntimeS instance to work on - the runtime argument, used by MK_RT_CALL (C-only)
[in]ctxthe MqContextS instance to work on
[in]tokenthe MqContextC SERVICE API to identify the service
[in]timeoutin seconds until a timeout-error is raised (possible values like ProcessEvent) (MK_TIMEOUT_DEFAULT=0)
Exceptions
MkExceptionC→ The default-exception from the Programming-Language-Micro-Kernel (PLMK)
See also
MqSendSYNC

Function Documentation

◆ pymqmsgque_MqContextC_SendEND()

static OT_ProcRet pymqmsgque_MqContextC_SendEND ( MqContextC_ARGS )
static

Python: ctx.SendEND(token:string[4], ?timeout:MkTimeoutE|int32=DEFAULT?) C-API
MqContextC - finish the send-data-block and call synchronous/asynchronous a remote-service

Definition at line 2761 of file MqContextC_py.c.

2761 {
2764 MQ_TOK token = 0;
2771 goto end;
2772 error:
2774 end:
2776}
#define OT_SETUP_VARARGS(min, max, d)
#define OT_retObj_SET_Error
#define OT_CHECK_REQUIRED(val)
#define OT_retObj_SET_None
#define OT_retObj_RETURN
#define OT_CHECK_OPTIONAL(val)
#define OT_CHECK_NOARGS
#define MkErrorC_Check(mng, PROC)
#define OT_CHECK_STRN(val)
#define OT_SETUP_hdl
#define SendEND_doc
#define error
Definition high_lng.h:339
MK_TIMEOUT_DEFAULT
time_t MK_TIME_T
#define MqSendEND(...)
MK_STRN MQ_TOK
MqContextC - a char[4+1] or hex[8+1] string used to unique identify a service …
MK_STRB token[9]
Definition high_lng.h:229
MK_TIME_T timeout
Definition high_lng.h:133
#define OT_CHECK_TIME_T(val)

◆ pymqmsgque_MqContextC_SendEND_AND_CALLBACK()

static OT_ProcRet pymqmsgque_MqContextC_SendEND_AND_CALLBACK ( MqContextC_ARGS )
static

Python: ctx.SendEND_AND_CALLBACK(token:string[4], callback:callable, ?timeout:MkTimeoutE|int32=DEFAULT?) C-API
finish the send-data-block, call the remote service, do not-wait for the result but expect the result on a callback

Definition at line 2779 of file MqContextC_py.c.

2779 {
2782 MQ_TOK token = 0;
2784 OT_SETUP_CALLABLE(callback)
2789 MkErrorC_Check(hdl,MqSendEND_AND_CALLBACK (hdl, token, NS(ServiceCall), callback, NS(ServiceFree), timeout));
2791 goto end;
2792 error:
2794 end:
2795 OT_CLEANUP_CALLABLE(callback)
2797}
#define NS(n)
#define SendEND_AND_CALLBACK_doc
#define MqSendEND_AND_CALLBACK(...)
#define OT_CHECK_CALLABLE(val)
#define OT_CLEANUP_CALLABLE(val)
#define OT_SETUP_CALLABLE(val)

◆ pymqmsgque_MqContextC_SendEND_AND_SUB()

static OT_ProcRet pymqmsgque_MqContextC_SendEND_AND_SUB ( MqContextC_ARGS )
static

Python: ctx.SendEND_AND_SUB(token:string[4], callback:callable, ?timeout:MkTimeoutE|int32=DEFAULT?) C-API
finish the send-data-block, call the remote service, do wait for the result and expect multiple sub-results on a callback

Definition at line 2800 of file MqContextC_py.c.

2800 {
2803 MQ_TOK token = 0;
2805 OT_SETUP_CALLABLE(callback)
2810 MkErrorC_Check(hdl,MqSendEND_AND_SUB (hdl, token, NS(ServiceCall), callback, NS(ServiceFree), timeout));
2812 goto end;
2813 error:
2815 end:
2816 OT_CLEANUP_CALLABLE(callback)
2818}
#define SendEND_AND_SUB_doc
#define MqSendEND_AND_SUB(...)

◆ pymqmsgque_MqContextC_SendEND_AND_TRANSACTION()

static OT_ProcRet pymqmsgque_MqContextC_SendEND_AND_TRANSACTION ( MqContextC_ARGS )
static

Python: ctx.SendEND_AND_TRANSACTION(token:string[4], callback:string[4], ?timeout:MkTimeoutE|int32=DEFAULT?) C-API
finish the send-data-block, call the remote service to do a longterm-transaction-call

Definition at line 2821 of file MqContextC_py.c.

2821 {
2824 MQ_TOK token = 0;
2826 MQ_TOK callback = 0;
2833 goto end;
2834 error:
2836 end:
2838}
#define SendEND_AND_TRANSACTION_doc
#define MqSendEND_AND_TRANSACTION(...)

◆ pymqmsgque_MqContextC_SendEND_AND_WAIT()

static OT_ProcRet pymqmsgque_MqContextC_SendEND_AND_WAIT ( MqContextC_ARGS )
static

Python: ctx.SendEND_AND_WAIT(token:string[4], ?timeout:MkTimeoutE|int32=DEFAULT?) C-API
finish the send-data-block, call the remote service and wait for result…

Definition at line 2841 of file MqContextC_py.c.

2841 {
2844 MQ_TOK token = 0;
2851 goto end;
2852 error:
2854 end:
2856}
#define SendEND_AND_WAIT_doc
#define MqSendEND_AND_WAIT(...)

◆ pymqmsgque_MqContextC_SendSTART()

static OT_ProcRet pymqmsgque_MqContextC_SendSTART ( MqContextC_ARGS )
static

Python: ctx.SendSTART() C-API
initialize the send-data-package. …

Definition at line 2859 of file MqContextC_py.c.

2859 {
2863 MkErrorC_Check(hdl,MqSendSTART (hdl));
2865 goto end;
2866 error:
2868 end:
2870}
#define OT_SETUP_NOARG(d)
#define SendSTART_doc
#define MqSendSTART(...)

◆ pymqmsgque_MqContextC_SendSYNC()

static OT_ProcRet pymqmsgque_MqContextC_SendSYNC ( MqContextC_ARGS )
static

Python: ctx.SendSYNC() C-API
garantee that all pending asynchronous-service-calls are processed. …

Definition at line 2873 of file MqContextC_py.c.

2873 {
2877 MkErrorC_Check(hdl,MqSendSYNC (hdl));
2879 goto end;
2880 error:
2882 end:
2884}
#define SendSYNC_doc
#define MqSendSYNC(...)