module ietf-service-assurance {
yang-version 1.1;
namespace "urn:ietf:params:xml:ns:yang:ietf-service-assurance";
prefix service-assurance;
import ietf-yang-types {
prefix yang;
}
organization
"IETF NETCONF (Network Configuration) Working Group";
contact
"WG Web:
WG List:
Author: Benoit Claise
Author: Jean Quilbeuf ";
description
"This module defines objects for assuring network services based on
their decomposition into so-called subservices, according to the SAIN
(Service Assurance for Intent-based Networking) architecture.
The subservices hierarchically organised by dependencies constitute an
assurance tree. This module should be supported by an assurance agent,
able to interact with the devices in order to produce a health status
and symptoms for each subservice in the assurance tree.
This module is intended for the following use cases:
* Assurance tree configuration:
* subservices: configure a set of subservices to assure, by specifying
their types and parameters.
* dependencies: configure the dependencies between the subservices,
along with their type.
* Assurance telemetry: export the health status of the subservices, along
with the observed symptoms.
The key words 'MUST', 'MUST NOT', 'REQUIRED', 'SHALL',
'SHALL NOT', 'SHOULD', 'SHOULD NOT', 'RECOMMENDED',
'NOT RECOMMENDED', 'MAY', and 'OPTIONAL' in this document
are to be interpreted as described in BCP 14 (RFC 2119)
(RFC 8174) when, and only when, they appear in all
capitals, as shown here.
Copyright (c) 2019 IETF Trust and the persons identified as
authors of the code. All rights reserved.
Redistribution and use in source and binary forms, with or
without modification, is permitted pursuant to, and subject
to the license terms contained in, the Simplified BSD License
set forth in Section 4.c of the IETF Trust's Legal Provisions
Relating to IETF Documents
(https://trustee.ietf.org/license-info).
This version of this YANG module is part of RFC XXXX; see the
RFC itself for full legal notices.";
revision 2019-10-02 {
description
"Initial revision.";
reference
"RFC xxxx: Title to be completed";
}
identity subservice-idty {
description
"Root identity for all subservice types.";
}
identity service-instance-idty {
base subservice-idty;
description
"Identity representing a service instance.";
}
identity dependency-type {
description
"Base identity for representing dependency types.";
}
identity informational-dependency {
base dependency-type;
description
"Indicates that symptoms of the dependency might be of interest for the
dependent, but the status of the dependency should not have any
impact on the dependent.";
}
identity impacting-dependency {
base dependency-type;
description
"Indicates that the status of the dependency directly impacts the status
of the dependent.";
}
grouping symptom {
description
"Contains the list of symptoms for a specific subservice.";
leaf id {
type string;
description
"A unique identifier for the symptom.";
}
leaf health-status {
type uint8 {
range "0 .. 100";
}
description
"The impact to the health score incurred by this symptom. The lower the
value, the more of an impact this symptom has. If a subservice health
score is not 100, there must be at least one symptom such that the
health-status of that symptom is equal to the health score of the
subservice. In other words, there must always be a symptom explaining
why the subservice health score is lower than 100.";
}
leaf label {
type string;
description
"Label of the symptom, i.e. text describing what the symptom is, to
be computer-consumable and be displayed on a human interface.";
}
leaf start-date {
type yang:date-and-time;
description
"Date and time at which the symptom was detected.";
}
leaf stop-date {
type yang:date-and-time;
description
"Date and time at which the symptom stopped being detected.";
}
}
grouping subservice-dependency {
description
"Represent a dependency to another subservice.";
leaf type {
type leafref {
path "/subservices/subservice/type";
}
description
"The type of the subservice to refer to (e.g. DeviceHealthy).";
}
leaf id {
type leafref {
path "/subservices/subservice[type=current()/../type]/id";
}
description
"The identifier of the subservice to refer to.";
}
leaf dependency-type {
type identityref {
base dependency-type;
}
description
"Represents the type of dependency (i.e. informational, impacting).";
}
// augment here if more info are needed (i.e. a percentage) depending on the dependency type.
}
leaf assurance-tree-version {
type yang:counter32;
config false;
description
"The assurance tree version, which increases by 1 for each new version.";
}
leaf assurance-tree-last-change {
type yang:date-and-time;
config false;
description
"Date and time at which the assurance tree last changed.";
}
container subservices {
description
"Root container for the subservices.";
list subservice {
key "type id";
description
"List of subservice configured.";
leaf type {
type identityref {
base subservice-idty;
}
description
"Name of the subservice, e.g. DeviceHealthy.";
}
leaf id {
type string;
description
"Unique identifier of the subservice instance, for each type.";
}
leaf last-change {
type yang:date-and-time;
config false;
description
"Date and time at which the assurance tree for this subservice
instance last changed.";
}
leaf label {
type string;
config false;
description
"Label for displaying the subservice name in human readable form.";
}
choice parameter {
description
"Specify the required parameters per subservice type.";
container service-instance-parameter {
when "derived-from-or-self(../type, 'service-instance-idty')";
description
"Specify the parameters of a service instance.";
leaf service {
type string;
description "Name of the service.";
}
leaf instance-name{
type string;
description "Name of the instance for that service.";
}
}
// Other modules can augment their own cases into here
}
leaf health-status {
type uint8 {
range "0 .. 100";
}
config false;
description
"Score value of the subservice health, also known as the subservice
status. A value of 100 means that subservice is healthy. A value of 0 means
that the subservice is broken. A value between 0 and 100 means that the
subservice is degraded.";
}
list symptoms {
//key id;
key "start-date id";
config false;
description
"List of symptoms the subservice. While the start-date key is not
necessary per se, this would get the entries sorted by start-date
for easy consumption.";
uses symptom;
}
list dependency {
key "type id";
description
"List of soft dependencies of the subservice.";
uses subservice-dependency;
}
}
}
}