mirror of
https://github.com/rsyslog/rsyslog.git
synced 2025-12-20 07:20:41 +01:00
mmfields: support v8 omod interface
This commit is contained in:
parent
d077eff698
commit
1c5a172411
@ -56,6 +56,10 @@ typedef struct _instanceData {
|
||||
uchar *jsonRoot; /**< container where to store fields */
|
||||
} instanceData;
|
||||
|
||||
typedef struct wrkrInstanceData {
|
||||
instanceData *pData;
|
||||
} wrkrInstanceData_t;
|
||||
|
||||
struct modConfData_s {
|
||||
rsconf_t *pConf; /* our overall config object */
|
||||
};
|
||||
@ -103,6 +107,10 @@ BEGINcreateInstance
|
||||
CODESTARTcreateInstance
|
||||
ENDcreateInstance
|
||||
|
||||
BEGINcreateWrkrInstance
|
||||
CODESTARTcreateWrkrInstance
|
||||
ENDcreateWrkrInstance
|
||||
|
||||
|
||||
BEGINisCompatibleWithFeature
|
||||
CODESTARTisCompatibleWithFeature
|
||||
@ -114,6 +122,10 @@ CODESTARTfreeInstance
|
||||
free(pData->jsonRoot);
|
||||
ENDfreeInstance
|
||||
|
||||
BEGINfreeWrkrInstance
|
||||
CODESTARTfreeWrkrInstance
|
||||
ENDfreeWrkrInstance
|
||||
|
||||
|
||||
static inline void
|
||||
setInstParamDefaults(instanceData *pData)
|
||||
@ -232,7 +244,7 @@ CODESTARTdoAction
|
||||
pMsg = (msg_t*) ppString[0];
|
||||
lenMsg = getMSGLen(pMsg);
|
||||
msg = getMSG(pMsg);
|
||||
CHKiRet(parse_fields(pData, pMsg, msg, lenMsg));
|
||||
CHKiRet(parse_fields(pWrkrData->pData, pMsg, msg, lenMsg));
|
||||
finalize_it:
|
||||
ENDdoAction
|
||||
|
||||
@ -259,6 +271,7 @@ ENDmodExit
|
||||
BEGINqueryEtryPt
|
||||
CODESTARTqueryEtryPt
|
||||
CODEqueryEtryPt_STD_OMOD_QUERIES
|
||||
CODEqueryEtryPt_STD_OMOD8_QUERIES
|
||||
CODEqueryEtryPt_STD_CONF2_OMOD_QUERIES
|
||||
CODEqueryEtryPt_STD_CONF2_QUERIES
|
||||
ENDqueryEtryPt
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user