Re: [netmod] Should the origin="system" be required for system configurations copied/pasted into ?

2021-11-24 Thread Martin Björklund
Jürgen Schönwälder  wrote:
> On Wed, Nov 24, 2021 at 03:21:14AM +, maqiufang (A) wrote:
> > 
> > But suppose the node is a list entry (e.g., an interface) or a leaf with 
> > the same value.  In this case, it is not clear which origin should be used. 
> >  I think it would be ok to use "system" in this case.
> 
> For me,  is explicit config and hence it has precedence. The
> precedence must be a function of how the datastores related, it should
> not depend on which values a config leaf has.

Here's a simple example.

Suppose  has:

   
 lo
 loopback
 added by system
   

and  has:

   
 lo
 set by a client
   

Now we follow the picture in RFC 8342:

  ++
  |  | // subject to validation
  | (ct, ro)   |
  ++
|// changes applied, subject to
|// local factors, e.g., missing
|// resources, delays
|
   dynamic  |   + learned configuration
   configuration|   + system configuration
   datastores -+|   + default configuration
   ||   |
   vv   v
+---+
|  | <-- system state
| (ct + cf, ro) |
+---+


So now we merge intended and system into operational state.  First we
add system to get:

  
lo
loopback
added by system
  

and then we add intended to arrive at:

  
lo
loopback
set by a client
  


Doesn't this make sense?



/martin

___
netmod mailing list
netmod@ietf.org
https://www.ietf.org/mailman/listinfo/netmod


Re: [netmod] Should the origin="system" be required for system configurations copied/pasted into ?

2021-11-24 Thread Rob Wilton (rwilton)
+1 to Juergen's comment.

// As a contributor.


-Original Message-
From: netmod  On Behalf Of Jürgen Schönwälder
Sent: 24 November 2021 09:25
To: maqiufang (A) 
Cc: netmod@ietf.org
Subject: Re: [netmod] Should the origin="system" be required for system 
configurations copied/pasted into ?

On Wed, Nov 24, 2021 at 03:21:14AM +, maqiufang (A) wrote:
> 
> But suppose the node is a list entry (e.g., an interface) or a leaf with the 
> same value.  In this case, it is not clear which origin should be used.  I 
> think it would be ok to use "system" in this case.

For me,  is explicit config and hence it has precedence. The
precedence must be a function of how the datastores related, it should
not depend on which values a config leaf has.

/js

-- 
Juergen Schoenwaelder   Jacobs University Bremen gGmbH
Phone: +49 421 200 3587 Campus Ring 1 | 28759 Bremen | Germany
Fax:   +49 421 200 3103 

___
netmod mailing list
netmod@ietf.org
https://www.ietf.org/mailman/listinfo/netmod

___
netmod mailing list
netmod@ietf.org
https://www.ietf.org/mailman/listinfo/netmod


Re: [netmod] Should the origin="system" be required for system configurations copied/pasted into ?

2021-11-24 Thread Jürgen Schönwälder
On Wed, Nov 24, 2021 at 03:21:14AM +, maqiufang (A) wrote:
> 
> But suppose the node is a list entry (e.g., an interface) or a leaf with the 
> same value.  In this case, it is not clear which origin should be used.  I 
> think it would be ok to use "system" in this case.

For me,  is explicit config and hence it has precedence. The
precedence must be a function of how the datastores related, it should
not depend on which values a config leaf has.

/js

-- 
Juergen Schoenwaelder   Jacobs University Bremen gGmbH
Phone: +49 421 200 3587 Campus Ring 1 | 28759 Bremen | Germany
Fax:   +49 421 200 3103 

___
netmod mailing list
netmod@ietf.org
https://www.ietf.org/mailman/listinfo/netmod


[netmod] IANA registries

2021-11-24 Thread Ladislav Lhotka
Hi,

I tried to generalize the approach of RFC 9108 and develop XSLT stylesheets for 
generating YANG modules directly from IANA registries. The results are in this 
GitHub project:

https://github.com/llhotka/iana-yang

So far I have processed 22 registries - most of them are related to DNS, but I 
also tried to include a few from other areas. After cloning the project, all 
YANG modules can be generated by running "make" in the top-level directory.

Adding a new registry is usually quite simple, although some hide nasty 
surprises such as duplicate entries. Also, in most cases it is quite clear how 
to do the translation, but sometimes input from domain experts might be needed.

I can see two immediate advantages of this approach:

* There is a single source of truth - the registry itself; IANA needn't
  maintain the YANG module separately.

* The initial revision of a registry-based YANG module needn't be published in
  an RFC that is not intended to be updated. There are concerns that people
  may extract such a module from the RFC long after it becomes obsolete.

Please let me know what you think about this.

Thanks, Lada

-- 
Ladislav Lhotka
Head, CZ.NIC Labs
PGP Key ID: 0xB8F92B08A9F76C67

___
netmod mailing list
netmod@ietf.org
https://www.ietf.org/mailman/listinfo/netmod