Subject: Re: [netmod] Y45 - imports

From: Randy Presuhn <[email-masked]>
Date: Mon, 23 Mar 2015 16:06:08 -0700 (GMT-07:00)

Hi -

>From: Ladislav Lhotka <[email-masked]>
>Sent: Mar 23, 2015 3:37 PM
>To: Andy Bierman <[email-masked]>
>Cc: NETMOD Working Group <[email-masked]>
>Subject: Re: [netmod] Y45 - imports
...
>> The best match revision may be different from server to server.
>> Even within 1 server, the best match can change from 1 day
>> to the next.
>
>No, the revision is fixed by the importing module, ideally form
>the revision-date. It doesn’t differ from server to server, and
>server implementors should use that revision.

I think the presumes an unrealistic level of omniscience on the
part of the designers / implementors of the importing code.

Consider this case:
  - a series of dates, D1..D5
  - ImporterA[D2], ImporterB[D5]
  - Imported[D1], Imported[D3], Imported[D4]

One would expext ImporterA[D2] to get Imported[D1].

One could *hope* that ImporterB[5] would get Imported[D4],
but I think one should not be surprised to get Imported[D3],
particularly if the organization responsible for the implementation
and maintenance of Imported[] is not tightly integrated with the
organization responsible for the maintenance of Importer[].

Randy

---

From: Ladislav Lhotka <[email-masked]>
Date: Mon, 23 Mar 2015 18:31:59 -0500

> On 23 Mar 2015, at 18:06, Randy Presuhn <[email-masked]> wrote:
> 
> Hi -
> 

I don’t think so. The developer of the importing module must have used a particular revision of the imported module, and this revision should be clear from the importing module. All users of the importing module have to use that revision.

BTW, this would also solve the issue of upgrading library modules to YANG 1.1. Modules importing, e.g., ietf-inet-types that are written before ietf-inet-types gets upgraded to 1.1 will stick to the 1.0 revision even if they don’t specify revision-date.   

>  - Imported[D1], Imported[D3], Imported[D4]

I assume that if module A imports revision D2, then D2 has to be used whenever (that particular revision) of module A is used. Using Di for i!=2 means that typedefs or groupings may be different from those that the author of A used - and this is IMO unacceptable and can lead to interoperability problems.

I think that making sure all existing revisions of a module are available is not that difficult (although it is not the case for the existing GitHub repository).

Lada

--
Ladislav Lhotka, CZ.NIC Labs
PGP Key ID: E74E8C0C