Define app config schema
[oam.git] / code / network-generator / model / jsonSchema / configuration.schema.json
1 {
2   "$schema": "https://json-schema.org/draft/2020-12/schema",
3   "$id": "https://highstreet-technologies.com/network-generator/configuration.schema.json",
4   "title": "Configuration",
5   "description": "This schema validates the initial configuration for the network generator application.",
6   "type": "object",
7   "required": [
8     "network",
9     "output-folder",
10     "generation-tasks"
11   ],
12   "additionalProperties": false,
13   "properties": {
14     "network": {
15       "description": "Defines the network and its topology to be generated.",
16       "$ref": "#/$defs/network"
17     },
18     "output-folder": {
19       "description":"The relative path (folder name only) of the directory, where the generated files are stored.",
20       "type": "string"
21     },
22     "generation-tasks": {
23       "description": "Defines the files to be generated.",
24       "$ref": "#/$defs/generation-tasks"
25     }
26   },
27   "$defs": {
28     "network": {
29       "title": "network",
30       "type": "object",
31       "required": [
32         "name",
33         "pattern"
34       ],
35       "additionalProperties": false,
36       "properties": {
37         "name": {
38           "description": "The name as identification for humans. For the pattern explanation, please see: https://regex101.com/r/3ER25H/1",
39           "type": "string",
40           "pattern": "^[a-zA-Z]{1}[\\S]{0,254}$"
41         },
42         "pattern": {
43           "description": "A description of the relations between O-RAN functions.",
44           "$ref": "#/$defs/pattern"
45         }
46       }
47     },
48     "pattern": {
49       "description": "A description of the relations between O-RAN functions.",
50       "title": "pattern",
51       "type": "object",
52       "required": [
53         "tower",
54         "smo",
55         "near-rt-ric",
56         "o-ran-cu",
57         "o-ran-du",
58         "o-ran-ru",
59         "nr-cell-du"
60       ],
61       "additionalProperties": false,
62       "properties": {
63         "tower": {
64           "description": "A 'tower' offers mounting positions of O-RUs.",
65           "title": "tower",
66           "type": "object",
67           "required": [
68             "representation",
69             "cellAngle"
70           ],
71           "properties": {
72             "representation": {
73               "description": "A fixed value for information only.",
74               "type": "string",
75               "enum": [
76                 "hexagon"
77               ]
78             },
79             "cellAngle": {
80               "description": "The area covered by an NRCellDU around the tower in grad.",
81               "type": "integer",
82               "minimum": 0,
83               "maximum": 360,
84               "exclusiveMinimum": true
85             }
86           }
87         },
88         "smo": {
89           "description": "Definition of the relation to SMO children.",
90           "title": "Service Management and Orchestration",
91           "type": "object",
92           "required": [
93             "five-g-core-count",
94             "near-rt-ric-spiral-radius",
95             "o-could-resource-pool-count"
96           ],
97           "properties": {
98             "five-g-core-count": {
99               "description": "The number of 5G-Cores controlled by SMO.",
100               "type": "integer",
101               "minimum": 0,
102               "maximum": 1
103             },
104             "near-rt-ric-spiral-radius": {
105               "description": "The spiral radius of hexagons within an hexagon grid defines the number of Near-RT-RICs and the geographical coverage of the SMO.",
106               "type": "integer",
107               "minimum": 0,
108               "maximum": 3
109             },
110             "o-could-resource-pool-count": {
111               "description": "Number of O-RAN O-Cloud resource pools managed by O2-controller of the SMO.",
112               "type": "integer",
113               "enum": [
114                 1,
115                 7,
116                 19,
117                 37
118               ]
119             }
120           }
121         },
122         "near-rt-ric": {
123           "description": "Definition of the relation to Near-RT-Ric children.",
124           "title": "near-rt-ric",
125           "type": "object",
126           "required": [
127             "o-ran-cu-spiral-radius"
128           ],
129           "properties": {
130             "o-ran-cu-spiral-radius": {
131               "description": "The spiral radius of hexagons within an hexagon grid defines the number of O-RAN CUs and the geographical coverage of the SMO.",
132               "type": "integer",
133               "minimum": 0,
134               "maximum": 3
135             }
136           }
137         },
138         "o-ran-cu": {
139           "description": "Definition of the relation to O-RAN-RU children.",
140           "title": "o-ran-cu",
141           "type": "object",
142           "required": [
143             "tower-spiral-radius"
144           ],
145           "properties": {
146             "tower-spiral-radius": {
147               "description": "The spiral radius of hexagons within an hexagon grid defines the number of towers and the geographical coverage of the SMO.",
148               "type": "integer",
149               "minimum": 0,
150               "maximum": 3
151             }
152           }
153         },
154         "o-ran-du": {
155           "description": "Definition of the relation to O-RAN-DU children.",
156           "title": "o-ran-du",
157           "type": "object",
158           "required": [
159             "fronthaul-gateway-count",
160             "o-ran-ru-count"
161           ],
162           "properties": {
163             "fronthaul-gateway-count": {
164               "description": "Number of fronthaul gateway connected to an O-RAN-DU.",
165               "type": "integer",
166               "minimum": 0,
167               "maximum": 1
168             },
169             "o-ran-ru-count": {
170               "description": "Number of O-RAN-RUs managed by an O-RAN-DU.",
171               "type": "integer",
172               "enum": [
173                 1,
174                 7,
175                 19,
176                 37
177               ]
178             }
179           }
180         },
181         "o-ran-ru": {
182           "description": "Definition of the relation to O-RAN-RU children.",
183           "title": "o-ran-ru",
184           "type": "object",
185           "required": [
186             "nr-cell-du-count"
187           ],
188           "properties": {
189             "nr-cell-du-count": {
190               "description": "Number of 3GPP:NRCellDUs managed by an O-RAN-RU.",
191               "type": "integer",
192               "enum": [
193                 1,
194                 3
195               ]
196             }
197           }
198         },
199         "nr-cell-du": {
200           "description": "Definition of the relation to 3GPP:NRCellDU children.",
201           "title": "nr-cell-du",
202           "type": "object",
203           "required": [
204             "sector-count"
205           ],
206           "properties": {
207             "sector-count": {
208               "description": "Number of sectors managed by an 3GPP:NRCellDUs.",
209               "type": "integer",
210               "enum": [
211                 1,
212                 3
213               ]
214             }
215           }
216         }
217       }
218     },
219     "generation-tasks":{
220       "title": "generation-tasks",
221       "type": "object",
222       "required": [
223         "topology",
224         "svg",
225         "kml"
226       ],
227       "additionalProperties": false,
228       "properties": {
229         "topology": {
230           "description": "If true, an ietf-network-topology file will be generated.",
231           "type": "boolean"
232         },
233         "svg": {
234           "description": "If true, a kml file will be generated.",
235           "type": "boolean"
236         },
237         "kml": {
238           "description": "If true, a svg file will be generated.",
239           "type": "boolean"
240         }
241       }
242     }
243   }
244 }