diff options
| author | Christian Hopps <chopps@labn.net> | 2024-06-04 10:29:46 -0400 |
|---|---|---|
| committer | Christian Hopps <chopps@labn.net> | 2024-06-06 22:39:53 -0400 |
| commit | 657f1650e697b2020f5f2fb4f5c271a9c6e30c53 (patch) | |
| tree | e9d69fc60c12e383e974e009de205272758699f6 /lib/mgmt_msg_native.h | |
| parent | 33b73f8e3aa13679ba3aad82be2a88d7cb69f426 (diff) | |
mgmtd: add front-end notification selector support
Signed-off-by: Christian Hopps <chopps@labn.net>
Diffstat (limited to 'lib/mgmt_msg_native.h')
| -rw-r--r-- | lib/mgmt_msg_native.h | 22 |
1 files changed, 22 insertions, 0 deletions
diff --git a/lib/mgmt_msg_native.h b/lib/mgmt_msg_native.h index cb1101d24f..e61346e6e5 100644 --- a/lib/mgmt_msg_native.h +++ b/lib/mgmt_msg_native.h @@ -176,6 +176,7 @@ DECLARE_MTYPE(MSG_NATIVE_RPC_REPLY); #define MGMT_MSG_CODE_EDIT_REPLY 6 /* Public API */ #define MGMT_MSG_CODE_RPC 7 /* Public API */ #define MGMT_MSG_CODE_RPC_REPLY 8 /* Public API */ +#define MGMT_MSG_CODE_NOTIFY_SELECT 9 /* Public API */ /* * Datastores @@ -426,6 +427,27 @@ _Static_assert(sizeof(struct mgmt_msg_rpc_reply) == offsetof(struct mgmt_msg_rpc_reply, data), "Size mismatch"); +/** + * struct mgmt_msg_notify_select - Add notification selectors for FE client. + * + * Add xpath prefix notification selectors to limit the notifications sent + * to the front-end client. + * + * @selectors: the xpath prefixes to selectors notifications through. + * @repalce: if true replace existing selectors with `selectors`. + */ +struct mgmt_msg_notify_select { + struct mgmt_msg_header; + uint8_t replace; + uint8_t resv2[7]; + + alignas(8) char selectors[]; +}; + +_Static_assert(sizeof(struct mgmt_msg_notify_select) == + offsetof(struct mgmt_msg_notify_select, selectors), + "Size mismatch"); + /* * Validate that the message ends in a NUL terminating byte */ |
