MqContextC - a wrapper to send a list-block or a transaction-block … More...
Functions | |
MQ_EXTERN enum MkErrorE | MqSendL_START_RT (MK_RT const mkrt, MQ_CTX const ctx) |
start to append an embedded body-list-item to the send-data-package. … | |
MQ_EXTERN enum MkErrorE | MqSendL_END_RT (MK_RT const mkrt, MQ_CTX const ctx) |
finish to append an embedded body-list-item to the send-data-package. … | |
MQ_EXTERN enum MkErrorE | MqSendT_START_RT (MK_RT const mkrt, MQ_CTX const ctx) |
open a longterm-transaction-item … | |
MQ_EXTERN enum MkErrorE | MqSendT_END_RT (MK_RT const mkrt, MQ_CTX const ctx) |
closed a longterm-transaction-item … | |
MqContextC - MqContextC_SendApi_Block_C_API - overload | |
#define | MqSendL_END_NULL(...) |
#define | MqSendL_END(...) |
#define | MqSendL_END_E(...) |
#define | MqSendL_END_C(...) |
#define | MqSendL_START_NULL(...) |
#define | MqSendL_START(...) |
#define | MqSendL_START_E(...) |
#define | MqSendL_START_C(...) |
#define | MqSendT_END_NULL(...) |
#define | MqSendT_END(...) |
#define | MqSendT_END_E(...) |
#define | MqSendT_END_C(...) |
#define | MqSendT_START_NULL(...) |
#define | MqSendT_START(...) |
#define | MqSendT_START_E(...) |
#define | MqSendT_START_C(...) |
MqContextC - a wrapper to send a list-block or a transaction-block …
start to append an embedded body-list-item to the send-data-package. …
[in] | mkrt | the MkRuntimeS instance to work on - the runtime argument, used by MK_RT_CALL (C-only) |
[in] | ctx | the MqContextS instance to work on |
#define MqSendL_END | ( | ... | ) |
Definition at line 674 of file msgque_overload_mq.h.
#define MqSendL_END_C | ( | ... | ) |
Definition at line 676 of file msgque_overload_mq.h.
#define MqSendL_END_E | ( | ... | ) |
Definition at line 675 of file msgque_overload_mq.h.
#define MqSendL_END_NULL | ( | ... | ) |
Definition at line 673 of file msgque_overload_mq.h.
#define MqSendL_START | ( | ... | ) |
Definition at line 678 of file msgque_overload_mq.h.
#define MqSendL_START_C | ( | ... | ) |
Definition at line 680 of file msgque_overload_mq.h.
#define MqSendL_START_E | ( | ... | ) |
Definition at line 679 of file msgque_overload_mq.h.
#define MqSendL_START_NULL | ( | ... | ) |
Definition at line 677 of file msgque_overload_mq.h.
#define MqSendT_END | ( | ... | ) |
Definition at line 682 of file msgque_overload_mq.h.
#define MqSendT_END_C | ( | ... | ) |
Definition at line 684 of file msgque_overload_mq.h.
#define MqSendT_END_E | ( | ... | ) |
Definition at line 683 of file msgque_overload_mq.h.
#define MqSendT_END_NULL | ( | ... | ) |
Definition at line 681 of file msgque_overload_mq.h.
#define MqSendT_START | ( | ... | ) |
Definition at line 686 of file msgque_overload_mq.h.
#define MqSendT_START_C | ( | ... | ) |
Definition at line 688 of file msgque_overload_mq.h.
#define MqSendT_START_E | ( | ... | ) |
Definition at line 687 of file msgque_overload_mq.h.
#define MqSendT_START_NULL | ( | ... | ) |
Definition at line 685 of file msgque_overload_mq.h.
finish to append an embedded body-list-item to the send-data-package. …
[in] | mkrt | the MkRuntimeS instance to work on - the runtime argument, used by MK_RT_CALL (C-only) |
[in] | ctx | the MqContextS instance to work on |
start to append an embedded body-list-item to the send-data-package. …
[in] | mkrt | the MkRuntimeS instance to work on - the runtime argument, used by MK_RT_CALL (C-only) |
[in] | ctx | the MqContextS instance to work on |
closed a longterm-transaction-item …
finish a setup-block started with MqSendT_START. read more at MqSendEND_AND_TRANSACTION.
[in] | mkrt | the MkRuntimeS instance to work on - the runtime argument, used by MK_RT_CALL (C-only) |
[in] | ctx | the MqContextS instance to work on |
open a longterm-transaction-item …
Every longterm-transaction-item have to be closed with MqSendT_END. Between MqSendT_START and MqSendT_END, a non specified number of other items can be added. These items are saved in a local database (in-memory or file-based) and the rowid is send as transaction-id to the link-target. By Default only the in-memory-database is used. To switch to a file-based database use the MqStorageOpen function.
Example from server.c
→ make a service-call with transaction-support
static enum MkErrorE Ot_TRNS ( MQ_SERVICE_CALL_ARGS ) { struct ServerCtxS *srvctx = (struct ServerCtxS*) mqctx; MK_I32 i; MqSendSTART_E (mqctx); MqSendT_START_E (mqctx); MqSendI32_E (mqctx, 9876); MqSendT_END_E (mqctx); MqReadI32_E (mqctx, &i); MqSendI32_E (mqctx, i); MqSendEND_AND_TRANSACTION_E (mqctx, "ECOI", "TRN2", MK_TIMEOUT_USER); MqProcessEvent_E (mqctx, MQ_WAIT_ONCE, 10); MqSendSTART_E (mqctx); MqSendI32_E (mqctx, srvctx->i); MqSendI32_E (mqctx, srvctx->j); error: return MqSendRETURN (mqctx); }
[in] | mkrt | the MkRuntimeS instance to work on - the runtime argument, used by MK_RT_CALL (C-only) |
[in] | ctx | the MqContextS instance to work on |