-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathietf-immutable-annotation.yang
More file actions
102 lines (95 loc) · 3.59 KB
/
ietf-immutable-annotation.yang
File metadata and controls
102 lines (95 loc) · 3.59 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
module ietf-immutable-annotation {
yang-version 1.1;
namespace "urn:ietf:params:xml:ns:yang:ietf-immutable-annotation";
prefix imma;
import ietf-yang-metadata {
prefix md;
reference
"RFC 7952: Defining and Using Metadata with YANG";
}
import ietf-netconf-nmda {
prefix ncds;
reference
"RFC 8526: NETCONF Extensions to Support the Network
Management Datastore Architecture";
}
import ietf-system-datastore {
prefix sysds;
reference
"RFC YYYY: System-defined Configuration";
}
import ietf-datastores {
prefix ds;
reference
"RFC 8342: Network Management Datastore Architecture
(NMDA)";
}
organization
"IETF Network Modeling (NETMOD) Working Group";
contact
"WG Web: <https://datatracker.ietf.org/wg/netmod/>
WG List: <mailto:netmod@ietf.org>
Author: Qiufang Ma
<mailto:maqiufang1@huawei.com>
Author: Qin Wu
<mailto:bill.wu@huawei.com>
Author: Balazs Lengyel
<mailto:balazs.lengyel@ericsson.com>
Author: Hongwei Li
<mailto:flycoolman@gmail.com>";
description
"This module defines a metadata annotation called 'immutable'
to allow the server to formally document existing behavior on
the mutability of some system configuration. Clients may use
'immutable' metadata annotation provided by the server to know
beforehand why certain otherwise valid configuration requests
will cause the server to return an error.
Copyright (c) 2026 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 Revised
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
(https://www.rfc-editor.org/info/rfcXXXX); see the RFC
itself for full legal notices.";
revision 2026-03-31 {
description
"Initial revision.";
// RFC Ed.: replace XXXX and remove this comment
reference
"RFC XXXX: YANG Metadata Annotation for Immutable Flag";
}
md:annotation immutable {
type boolean;
description
"The 'immutable' metadata annotation indicates the
immutability of an instantiated data node. It takes as a
value 'true' or 'false'. An immutable node cannot be changed
via configuring a different value in read-write configuration
datastores (e.g., <running>), though it can be created/deleted
in read-write configuration datastores. If not specified for
a given configuration data node, the immutability is the
same as the value of its parent node in the data tree. The
default value of 'immutable' annotation for a top-level
instance node is false if not specified.";
}
augment "/ncds:get-data/ncds:input" {
description
"Allows the server to include 'immutable' metadata
annotations in its response to get-data operation.";
leaf with-immutability {
when
"derived-from-or-self(../ncds:datastore,'sysds:system') "
+ "or derived-from-or-self(../ncds:datastore,'ds:intended') "
+ "or derived-from-or-self(../ncds:datastore,'ds:operational')";
type empty;
description
"If this parameter is present, the server returns the
'immutable' annotation for configuration that it
internally thinks immutable.";
}
}
}