Support of WG4 OpenFronthaul Management-Plane VES
[scp/oam/modeling.git] / data-model / yang / working / o-ran-sc / near-rt-ric / o-ran-sc-ric-xapp-desc-v1.yang
1 module o-ran-sc-ric-xapp-desc-v1 {
2   yang-version 1.1;
3   namespace "urn:o-ran-sc:yang:o-ran-sc-ric-xapp-desc-v1";
4   prefix rxad;
5
6   import o-ran-sc-root-v1 {
7     prefix root;
8   }
9   import o-ran-sc-types-v1 {
10     prefix ot;
11   }
12
13   organization
14     "O-RAN Software Community";
15   contact
16     "www.o-ran.org";
17   description
18     "This module defines a generic xApp descriptor used for
19      xApp lifecycle management
20
21      Copyright 2021 the O-RAN Software Community.
22
23      Licensed under the Apache License, Version 2.0 (the 'License');
24      you may not use this file except in compliance with the License.
25      You may obtain a copy of the License at
26
27      http://www.apache.org/licenses/LICENSE-2.0
28
29      Unless required by applicable law or agreed to in writing, software
30      distributed under the License is distributed on an 'AS IS' BASIS,
31      WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
32      See the License for the specific language governing permissions and
33      limitations under the License.";
34
35   revision 2021-03-09 {
36     description
37       "The namespace was updated according to O-RAN-SC yang guidelines.
38        The namespace must end with the full module name.";
39     reference
40       "https://jira.o-ran-sc.org/browse/OAM-168";
41   }
42   revision 2020-02-25 {
43     description
44       "Dependency to a common and abstract root module added.";
45     reference
46       "O-RAN-OAM-architecture-Specification (O1)";
47   }
48   revision 2020-01-29 {
49     description
50       "initial revision";
51     reference
52       "O-RAN-OAM-Interface-Specification (O1)";
53   }
54
55   // identity
56
57   identity near-realtime-ran-intelligent-controller {
58     base ot:control-function-type;
59     description
60       "Defines the identitiy near-rt-ric as contoll-function type.";
61   }
62
63   // grouping
64   // LCM: Generic xApp descriptor passed to xApp Manager (or OCO) during xApp deployment/undeployment
65
66   grouping xapp-descriptor {
67     uses root:control-base-grp;
68     leaf release-name {
69       type string;
70       description
71         "Name of the xapp to be visible in Kubernetes";
72     }
73     leaf version {
74       type string;
75       description
76         "The exact xapp helm chart version to install";
77     }
78     leaf namespace {
79       type string;
80       description
81         "Name of the namespace to which xApp is deployed in Kubernetes";
82     }
83     leaf override-file {
84       type string;
85       description
86         "JSON string of override file for 'helm install' command";
87     }
88     description
89       "xApp descriptor";
90   }
91
92   grouping ric-specific-grp {
93     container xapps {
94       list xapp {
95         key "name";
96         uses xapp-descriptor;
97         description
98           "xApp descriptor";
99       }
100       description
101         "List of xApps to be managed.";
102     }
103     description
104       "Groups xApps realted artifacts. ";
105   }
106
107   // Inherit from controlled-function
108
109   augment "/root:controlled-element/root:controlled-function" {
110     when "derived-from-or-self(./root:function-type, 'rxad:near-realtime-ran-intelligent-controller')";
111     uses ric-specific-grp;
112     description
113       "Inheritance from root object class.";
114   }
115 }