9ba295a5598026281eff95bdf5bb63eed3e3c422
[integration.git] / docs / simulators / nf_simulator.rst
1 .. This work is licensed under a Creative Commons Attribution 4.0
2 .. International License. http://creativecommons.org/licenses/by/4.0
3
4 .. _nf_simulator:
5
6 :orphan:
7
8 NF Simulator
9 ============
10
11 Description
12 -----------
13 An idea behind NF (Network Function) Simulator is to introduce simulator, which supports ORAN defined O1 interface (reporting of NF events to Service Management Orchestrators).
14 Within the use-case, it is expected, that an NF configuration change, happening due to multiple reasons (network mechanism triggered change - e.g. discovery of neighbours) is reported to the network management system, using ONAP`s VES REST events.
15 The simulator is expected to cover planned NF behaviour - receive the config change via a NetConf protocol and report that change (also potentially other related changes) to the network management system using ONAP`s VES event.
16
17 |image1|
18
19 **Figure 1. Architecture Overview**
20
21 NF Simulator code is stored in https://github.com/onap/integration-simulators-nf-simulator and all it's sub repos are:
22
23 - for VES Client - https://github.com/onap/integration-simulators-nf-simulator-ves-client
24 - for Netconf Server - https://github.com/onap/integration-simulators-nf-simulator-netconf-server
25 - for AVCN Manager - https://github.com/onap/integration-simulators-nf-simulator-avcn-manager
26 - for PM HTTPS Server - https://github.com/onap/integration-simulators-nf-simulator-pm-https-server
27
28 For above components have been prepared:
29
30 - docker images in ONAP Nexus:
31
32     -  VES Client image - nexus3.onap.org:10001/onap/org.onap.integration.nfsimulator.vesclient
33     -  AVCN Manager image - nexus3.onap.org:10001/onap/org.onap.integration.nfsimulator.avcnmanager
34     -  PM HTTPS Server image - nexus3.onap.org:10001/onap/org.onap.integration.nfsimulator.pmhttpsserver
35     -  Netconf Server images - nexus3.onap.org:10001/onap/org.onap.integration.nfsimulator.netconfserver
36
37 - example helm charts:
38
39     - `Helm charts <https://github.com/onap/integration-simulators-nf-simulator/tree/master/helm>`_
40
41 **VES Client, Netconf Server and PM HTTPS Server can be used and deployed separately depending on needs.**
42
43 Only AVCN Manger connects VES Client with Netconf Server in order to support O1 interface.
44
45 1. VES Client:
46 --------------
47
48    Application that generates VES events on demand.
49
50    **What does it do?**
51
52    - Supports both basic auth and TLS CMPv2 method of authentication.
53    - Allows to turn on and turn off hostname, verification in SSL.
54    - Allows to send one-time event and periodic events, based on event templates.
55    - Exposes API to manage VES Client
56    - Provides template mechanism (Template is a draft event. Merging event with patch will result in valid VES event.
57      Template itself should be a correct VES event as well as valid json object. )
58    - Patching - User is able to provide patch in request, which will be merged into template.
59    - Simulator supports corresponding keywords in templates: RandomInteger(start,end), RandomPrimitiveInteger(start,end), RandomInteger,
60      RandomString(length), RandomString, Timestamp, TimestampPrimitive, Increment
61    - In place variables support - Simulator supports dynamic keywords e.g. #dN to automatically substitute selected phrases in defined json schema.
62    - Logging - Every start of simulator will generate new logs that can be found in docker ves-client container.
63    - Swagger - Detailed view of simulator REST API is available via Swagger UI
64    - History - User is able to view events history.
65
66
67 2. Netconf Server:
68 ------------------
69
70    This server uses sysrepo to simulate network configuration.
71    It is based on sysrepo-netopeer2 image.
72
73    **What does it do?**
74
75    Server allows to:
76
77    - install custom configuration models on start up.
78    - change configuration of that modules on runtime.
79    - use TLS custom certificates
80    - configure change subscription for particular YANG modules (Netconf server image run python application on the startup.)
81    - manage netconf server using REST interface, with endpoints:
82
83       - GET /healthcheck returns 200 "UP" if server is up and running
84       - POST /readiness return 200 "Ready" if server is ready, if not, returns 503 "Not Ready"
85       - POST /change_config/<path:module_name> changes configuration ad returns 202 "Accepted"
86       - GET /change_history returns 200 and change history as json
87       - GET /get_config/<path:module_name> returns 200 and current configuration
88
89 3. AVCN Manager:
90 ----------------
91
92    Manager that fetches changes of configuration from kafka and sends them to VES client.
93
94    **What does it do?**
95
96    The manager processes notifications from NETCONF server. It does this by being a subscriber of a Kafka topic that is fed
97    with NETCONF notifications. Incoming notifications are then processed and output of this processing is sent to VES client.
98
99 4. PM HTTPS Server:
100 -------------------
101
102    Server that is used in Bulk PM usecases over HTTPS
103
104    **What does it do?**
105
106    - Supports TLS (CMPv2) method of authentication (used during connection to Data File Collector)
107    - Allows to use custom certificates
108    - Exposes REST API in order to manage PM files stored in HTTPS server
109
110
111 Guides
112 ======
113
114 User And Developer Guide
115 ------------------------
116 User guides:
117
118 - `VES Client user guide. <https://github.com/onap/integration-simulators-nf-simulator-ves-client/blob/master/README.md>`_
119 - `AVCN Manager user guide. <https://github.com/onap/integration-simulators-nf-simulator-avcn-manager/blob/master/README.md>`_
120 - `PM HTTPS Server user guide. <https://github.com/onap/integration-simulators-nf-simulator-pm-https-server/blob/master/README.md>`_
121 - `Netconf Server user guide. <https://github.com/onap/integration-simulators-nf-simulator-netconf-server/blob/master/README.md>`_
122 - `Netconf Notification Application user guide. <https://github.com/onap/integration-simulators-nf-simulator-netconf-server/blob/master/src/python/README.md>`_
123 - `NF Simulator CLI user guide <https://github.com/onap/integration-simulators-nf-simulator/blob/master/simulator-cli/README.md>`_
124
125 Jenkins builds:
126
127 - `VES Client jenkins builds <https://jenkins.onap.org/view/integration-simulators-nf-simulator-avcn-manager/>`_
128 - `AVCN Manager jenkins builds <https://jenkins.onap.org/view/integration-simulators-nf-simulator-netconf-server/>`_
129 - `PM HTTPS Server jenkins builds <https://jenkins.onap.org/view/integration-simulators-nf-simulator-pm-https-server/>`_
130 - `Netconf Server jenkins builds <https://jenkins.onap.org/view/integration-simulators-nf-simulator-ves-client/>`_
131
132 NF Simulator CSIT test cases:
133
134 - `Project integration-simulators-nf-simulator-netconf-server-master-verify-csit-testsuites <https://jenkins.onap.org/view/integration-simulators-nf-simulator-netconf-server/job/integration-simulators-nf-simulator-netconf-server-master-verify-csit-testsuites/>`_
135 - `Project integration-simulators-nf-simulator-netconf-server-master-csit-testsuites <https://jenkins.onap.org/view/integration-simulators-nf-simulator-netconf-server/job/integration-simulators-nf-simulator-netconf-server-master-csit-testsuites/>`_
136
137 NF Simulator sanity checks:
138
139 - https://github.com/onap/integration-simulators-nf-simulator/tree/master/sanitycheck
140
141 .. |image1| image:: ../files/simulators/NF-Simulator.png
142    :width: 10in