summaryrefslogtreecommitdiff
path: root/lib/mgmt_be_client.c
diff options
context:
space:
mode:
authorIgor Ryzhov <iryzhov@nfware.com>2023-10-09 03:21:16 +0300
committerIgor Ryzhov <iryzhov@nfware.com>2024-01-11 15:06:53 +0200
commitd726114790464831b1d377eb3acc05c2933e3cd8 (patch)
treef23c3e1eaf654359d0bf28722eae92fcf5544f97 /lib/mgmt_be_client.c
parentfe0d4dc2cb8fdf63524d92ab364157904327eb29 (diff)
mgmt, lib: implement REPLACE operation
Replace operation removes the current data node configuration and sets the provided value. As current northbound code works only with one xpath at a time, the operation only makes sense to clear the config of a container without deleting it itself. However, the next step is to allow passing JSON-encoded complex values to northbound operations which will make replace operation much more useful. Signed-off-by: Igor Ryzhov <iryzhov@nfware.com>
Diffstat (limited to 'lib/mgmt_be_client.c')
-rw-r--r--lib/mgmt_be_client.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/lib/mgmt_be_client.c b/lib/mgmt_be_client.c
index 53df191b2c..16aea249a4 100644
--- a/lib/mgmt_be_client.c
+++ b/lib/mgmt_be_client.c
@@ -577,6 +577,7 @@ static int mgmt_be_update_setcfg_in_batch(struct mgmt_be_client *client_ctx,
break;
case MGMTD__CFG_DATA_REQ_TYPE__SET_DATA:
case MGMTD__CFG_DATA_REQ_TYPE__CREATE_DATA:
+ case MGMTD__CFG_DATA_REQ_TYPE__REPLACE_DATA:
cfg_chg->operation = NB_OP_MODIFY;
break;
case MGMTD__CFG_DATA_REQ_TYPE__REQ_TYPE_NONE: