Subject: [netmod] Netconf, none operation and non-presence containers

From: "Maros Marsalek -X (mmarsale - PANTHEON TECHNOLOGIES at Cisco)" <[email-masked]>
Date: Tue, 1 Mar 2016 14:59:13 +0000

Hello netmod group,

We've run into following situation with NETCONF and we would like to know your opinion on what's the correct behavior here:

Model (root non-presence container with nested list) :

container mapping-nodes {
    list mapping-node{
        key "id";
        leaf id {
            type string;
        }
    }
}

Netconf edit-config RPC (replacing mapping-node entry with none operation for mapping-nodes container, in an empty data store):

    <edit-config>
        ...
        <default-operation>none</default-operation>
        <config>
            <mapping-nodes xmlns="urn:opendaylight:mdsal:mapping:test">
                <mapping-node xmlns:a="urn:ietf:params:xml:ns:netconf:base:1.0" a:operation="replace">
                    <id>node1-put</id>
                </mapping-node>
            </mapping-nodes>
        </config>
    </edit-config>

And the question here is: Whether the edit should fail or not ?
The problem is that mapping-nodes container does not exist and in edit-config rpc, there's "none" operation associated to it.
Our first assumption was that the resulting data structure should be invalid due to missing root container and rpc should fail.
However, the container is non-presence (exists only for organizing the hierarchy of data nodes), which means that it may be created/deleted as child nodes appear/disappear.
In which case, the operation doesn't have to fail and can create mapping-nodes container even if "none" operation is associated with it.

Regards,
Maros

---

From: Juergen Schoenwaelder <[email-masked]>
Date: Tue, 1 Mar 2016 16:29:47 +0100

Hi,

please send NETCONF specific questions to the NETCONF list and not
to the NETMOD list. Your question does seem to be NETCONF specific.

Thanks,

/js

> _______________________________________________
> netmod mailing list
> [email-masked]
> https://www.ietf.org/mailman/listinfo/netmod

-- 
Juergen Schoenwaelder           Jacobs University Bremen gGmbH
Phone: +49 421 200 3587         Campus Ring 1 | 28759 Bremen | Germany
Fax:   +49 421 200 3103         <http://www.jacobs-university.de/>