mirror of
https://github.com/emqx/neuron.git
synced 2026-10-21 00:36:23 +08:00
feat(adapter): update adds group field to support tags under different groups can have the same name
This commit is contained in:
@@ -86,8 +86,8 @@ typedef struct adapter_callbacks {
|
||||
|
||||
union {
|
||||
struct {
|
||||
void (*update)(neu_adapter_t *adapter, const char *name,
|
||||
neu_dvalue_t value);
|
||||
void (*update)(neu_adapter_t *adapter, const char *group,
|
||||
const char *tag, neu_dvalue_t value);
|
||||
void (*write_response)(neu_adapter_t *adapter, void *req,
|
||||
neu_error error);
|
||||
} driver;
|
||||
|
||||
@@ -50,6 +50,9 @@ struct neu_plugin_group {
|
||||
char * group_name;
|
||||
UT_array *tags;
|
||||
|
||||
// the number of all tags under the node
|
||||
uint16_t tag_size;
|
||||
|
||||
void * user_data;
|
||||
neu_plugin_group_free group_free;
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user