Re: [CCAMP] YANG issue in draft-ietf-ccamp-alarm-module
Martin Bjorklund <mbj@tail-f.com> Tue, 26 March 2019 13:50 UTC
Return-Path: <mbj@tail-f.com>
X-Original-To: ccamp@ietfa.amsl.com
Delivered-To: ccamp@ietfa.amsl.com
Received: from localhost (localhost [127.0.0.1]) by ietfa.amsl.com (Postfix) with ESMTP id 9A1671202DD for <ccamp@ietfa.amsl.com>; Tue, 26 Mar 2019 06:50:25 -0700 (PDT)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -1.9
X-Spam-Level:
X-Spam-Status: No, score=-1.9 tagged_above=-999 required=5 tests=[BAYES_00=-1.9, SPF_PASS=-0.001, URIBL_BLOCKED=0.001] autolearn=ham autolearn_force=no
Received: from mail.ietf.org ([4.31.198.44]) by localhost (ietfa.amsl.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id 4FTM6UwPSqf5 for <ccamp@ietfa.amsl.com>; Tue, 26 Mar 2019 06:50:23 -0700 (PDT)
Received: from mail.tail-f.com (mail.tail-f.com [46.21.102.45]) by ietfa.amsl.com (Postfix) with ESMTP id D63F11202DC for <ccamp@ietf.org>; Tue, 26 Mar 2019 06:50:22 -0700 (PDT)
Received: from localhost (dhcp-97ad.meeting.ietf.org [31.133.151.173]) by mail.tail-f.com (Postfix) with ESMTPSA id EAE881AE08F1; Tue, 26 Mar 2019 14:50:21 +0100 (CET)
Date: Tue, 26 Mar 2019 14:50:21 +0100
Message-Id: <20190326.145021.382345440775844174.mbj@tail-f.com>
To: daniele.ceccarelli@ericsson.com
Cc: ccamp@ietf.org
From: Martin Bjorklund <mbj@tail-f.com>
In-Reply-To: <VI1PR07MB5040A36792A27C74E9BD53ECF0430@VI1PR07MB5040.eurprd07.prod.outlook.com>
References: <20190322.134249.387057810261874257.mbj@tail-f.com> <VI1PR07MB5040A36792A27C74E9BD53ECF0430@VI1PR07MB5040.eurprd07.prod.outlook.com>
X-Mailer: Mew version 6.7 on Emacs 24.5 / Mule 6.0 (HANACHIRUSATO)
Mime-Version: 1.0
Content-Type: Text/Plain; charset="us-ascii"
Content-Transfer-Encoding: 7bit
Archived-At: <https://mailarchive.ietf.org/arch/msg/ccamp/-MOiu0UP0qySqPCMa7myQ9F3wsI>
Subject: Re: [CCAMP] YANG issue in draft-ietf-ccamp-alarm-module
X-BeenThere: ccamp@ietf.org
X-Mailman-Version: 2.1.29
Precedence: list
List-Id: Discussion list for the CCAMP working group <ccamp.ietf.org>
List-Unsubscribe: <https://www.ietf.org/mailman/options/ccamp>, <mailto:ccamp-request@ietf.org?subject=unsubscribe>
List-Archive: <https://mailarchive.ietf.org/arch/browse/ccamp/>
List-Post: <mailto:ccamp@ietf.org>
List-Help: <mailto:ccamp-request@ietf.org?subject=help>
List-Subscribe: <https://www.ietf.org/mailman/listinfo/ccamp>, <mailto:ccamp-request@ietf.org?subject=subscribe>
X-List-Received-Date: Tue, 26 Mar 2019 13:50:26 -0000
Daniele Ceccarelli <daniele.ceccarelli@ericsson.com> wrote: > Thanks a lot Martin for finding the issue and letting the WG know about it. > > > I.e., change it to an enumeration leaf with a default value, and add an > additional leaf to set the severity level when the enum "severity-level" is > set. > > I don't see this as a major change. Please update the draft, we won't need > another round of review. The draft (-08) is now posted with these fixes. /martin > > Thanks > > Daniele > > -----Original Message----- > From: CCAMP <ccamp-bounces@ietf.org> On Behalf Of Martin Bjorklund > Sent: den 22 mars 2019 13:43 > To: ccamp@ietf.org > Subject: [CCAMP] YANG issue in draft-ietf-ccamp-alarm-module > > Hi, > > When we fixed the review comments for this draft, I found an issue with the > current YANG model. Currently we have: > > > choice notify-status-changes { > description > "This leaf controls the notifications sent for alarm status > updates. There are three options: > > [...]"; > > leaf notify-all-state-changes { > type empty; > description > "Send notifications for all status changes."; > } > leaf notify-raise-and-clear { > type empty; > description > "Send notifications only for raise, clear, and re-raise. > Notifications for severity level changes or alarm text > changes are not sent."; > } > leaf notify-severity-level { > type severity; > description > "Only send notifications for alarm state changes crossing > the specified level. Always send clear notifications."; > } > } > > > First of all, the description refers to the choice as a leaf; the main text > has the same issue. > > But worse is that it isn't described what happens if no leafs in this choice > are configured. What is the default? > > Since the leafs are of type empty we can't just add a default statement to > the choice. > > So we suggest the following updated model to fix this issue: > > leaf notify-status-changes { > type enumeration { > enum all-state-changes { > description > "Send notifications for all status changes."; > } > enum raise-and-clear { > description > "Send notifications only for raise, clear, and > re-raise. Notifications for severity level changes or > alarm text changes are not sent."; > } > enum severity-level { > description > "Only send notifications for alarm state changes > crossing the level specified in > 'notify-severity-level'. Always send clear > notifications."; > } > } > must '. != "severity-level" or ../notify-severity-level' { > description > "When notify-status-changes is 'severity-level', a value > must be given for notify-severity-level."; > } > default "all-state-changes"; > description > "This leaf controls the notifications sent for alarm status > updates. There are three options: > > [...]"; > } > leaf notify-severity-level { > when '../notify-status-changes = "severity-level"'; > type severity; > description > "Only send notifications for alarm state changes crossing > the specified level. Always send clear notifications."; > } > > > I.e., change it to an enumeration leaf with a default value, and add an > additional leaf to set the severity level when the enum "severity-level" is > set. > > Note that it doesn't change any major concepts; it is a model change to > better describe the semantics. > > Unless we hear any objections, we'll make this change in the updated draft > that will be sent to the IESG. > > > > /martin > > _______________________________________________ > CCAMP mailing list > CCAMP@ietf.org > https://www.ietf.org/mailman/listinfo/ccamp
- [CCAMP] YANG issue in draft-ietf-ccamp-alarm-modu… Martin Bjorklund
- Re: [CCAMP] YANG issue in draft-ietf-ccamp-alarm-… Daniele Ceccarelli
- Re: [CCAMP] YANG issue in draft-ietf-ccamp-alarm-… Martin Bjorklund