[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Second Example in section 7.2 of netconf-proto



Martin Bjorklund wrote:
Andy Bierman <ietf@andybierman.com> wrote:
Martin Bjorklund wrote:

IMO:

If the agent data model has sub-trees that are
not included in the 'replace' subtrees, then they
are not touched.  Only the agent data model subtrees
explicitly included in the replace-subtrees are touched.

At least that's what I meant when I wrote the original text.

An example:

  <bowler xmlns="urn:foo">
    <name>Fred</name>
    <status>married</status>
    <cars>
      <car>
        <id>ABC-123</id>
        <make>volvo</make>
      </car>
    </cars>
  </bowler>
  <interfaces>
    <interface>
       <name>eth0</name>
       <ip>10.0.0.1</ip>
    </interface>
  </interfaces>
+ <bowler operation="replace">
   <name>Fred</name>
   <status>divorced</status>
 </bowler>



To come up the the result that follows,
you need to do:

  <bowler operation="replace">
   <name>Fred</name>
   <status>divorced</status>
   <cars operation="delete"/>
  </bowler>


Otherwise the 'cars' element is untouched.
The 'interfaces' data model (and all the other
sibling subtrees not included in the replace-subtrees)
are not affected whatsoever by an operation="replace".
This is the whole point of using an operation attribute
placed in the root of the subtree to be affected.



=
  <bowler xmlns="urn:foo">
    <name>Fred</name>
    <status>divorced</status>
  </bowler>
  <interfaces>
    <interface>
       <name>eth0</name>
       <ip>10.0.0.1</ip>
    </interface>
  </interfaces>

I.e. the subtree "interfaces" is left untouched, but the "bowler"
subtree completely replaced.

Is this what you meant?  (that's what I meant anyway...)



/martin




Andy

--
to unsubscribe send a message to netconf-request@ops.ietf.org with
the word 'unsubscribe' in a single line as the message text body.
archive: <http://ops.ietf.org/lists/netconf/>