diff options
author | Christian Hopps <chopps@labn.net> | 2023-02-28 16:00:19 +0100 |
---|---|---|
committer | Christian Hopps <chopps@labn.net> | 2023-03-22 03:08:32 +0100 |
commit | 7d65b7b7f441ddb2e730d4274023c0d3d2907c6b (patch) | |
tree | a1a7106459429fb936a493cba746aff105d3ce06 /mgmtd/mgmt_main.c | |
parent | mgmtd: Add MGMT Frontend Interface Framework (diff) | |
download | frr-7d65b7b7f441ddb2e730d4274023c0d3d2907c6b.tar.xz frr-7d65b7b7f441ddb2e730d4274023c0d3d2907c6b.zip |
mgmtd: Add MGMT Backend Interface Framework
This commit introduces the MGMT Backend Interface which can be used
by back-end management client daemons like BGPd, Staticd, Zebra to
connect with new FRR Management daemon (MGMTd) and utilize the new
FRR Management Framework to let any Frontend clients to retrieve any
operational data or manipulate any configuration data owned by the
individual Backend daemon component.
This commit includes the following functionalities in the changeset:
1. Add new Backend server for Backend daemons connect to.
2. Add a C-based Backend client library which can be used by daemons
to communicate with MGMTd via the Backend interface.
3. Maintain a backend adapter for each connection from an appropriate
Backend client to facilitate client requests and track one or more
transactions initiated from Frontend client sessions that involves
the backend client component.
4. Add the following commands to inspect various Backend client
related information
a. show mgmt backend-adapter all
b. show mgmt backend-yang-xpath-registry
c. show mgmt yang-xpath-subscription
Co-authored-by: Pushpasis Sarkar <pushpasis@gmail.com>
Co-authored-by: Abhinay Ramesh <rabhinay@vmware.com>
Co-authored-by: Ujwal P <ujwalp@vmware.com>
Signed-off-by: Yash Ranjan <ranjany@vmware.com>
Diffstat (limited to 'mgmtd/mgmt_main.c')
-rw-r--r-- | mgmtd/mgmt_main.c | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/mgmtd/mgmt_main.c b/mgmtd/mgmt_main.c index f47b91df6..017263ca8 100644 --- a/mgmtd/mgmt_main.c +++ b/mgmtd/mgmt_main.c @@ -16,6 +16,7 @@ #include "mgmtd/mgmt_ds.h" #include "routing_nb.h" + /* mgmt options, we use GNU getopt library. */ static const struct option longopts[] = { {"skip_runas", no_argument, NULL, 'S'}, @@ -195,6 +196,17 @@ static void mgmt_vrf_terminate(void) static const struct frr_yang_module_info *const mgmt_yang_modules[] = { &frr_filter_info, &frr_interface_info, &frr_route_map_info, &frr_routing_info, &frr_vrf_info, +/* + * YANG module info supported by backend clients get added here. + * NOTE: Always set .ignore_cbs true for to avoid validating + * backend northbound callbacks during loading. + */ +#if 0 +#ifdef HAVE_STATICD + &(struct frr_yang_module_info){.name = "frr-staticd", + .ignore_cbs = true}, +#endif +#endif }; FRR_DAEMON_INFO(mgmtd, MGMTD, .vty_port = MGMTD_VTY_PORT, |