1efc5ad5dc93c69574961975cad0e69f71dc9ad2
[clamp.git] / docs / index.rst
1
2
3
4
5 .. This work is licensed under a Creative Commons Attribution 4.0 International License.
6 .. http://creativecommons.org/licenses/by/4.0
7 .. Copyright © 2017 AT&T Intellectual Property. All rights reserved.
8
9 CLAMP - Closed Loop Automation Management Platform
10 ==================================================
11 .. High level architecture, design, and packaging information for release planning and delivery.
12
13 CLAMP is a platform for designing and managing control loops. It is used to design a closed loop, configure it with specific parameters for a particular network service, then deploying and undeploying it.  Once deployed, the user can also update the loop with new parameters during runtime, as well as suspending and restarting it.
14
15 It interacts with other systems to deploy and execute the closed loop. For example, it pushes the control loop design to the SDC catalog, associating it with the VF resource.  It requests from DCAE the instantiation of microservices to manage the closed loop flow.  Further, it creates and updates multiple policies in the Policy Engine that define the closed loop flow.
16
17 The ONAP CLAMP platform abstracts the details of these systems under the concept of a control loop model.  The design of a control loop and its management is represented by a workflow in which all relevant system interactions take place.  This is essential for a self-service model of creating and managing control loops, where no low-level user interaction with other components is required.
18
19 At a higher level, CLAMP is about supporting and managing the broad operational life cycle of VNFs/VMs and ultimately ONAP components itself. It will offer the ability to design, test, deploy and update control loop automation - both closed and open. Automating these functions would represent a significant saving on operational costs compared to traditional methods.
20
21
22
23 .. toctree::
24 :maxdepth: 1
25
26 Offered APIs
27 ------------
28 CLAMP offers the following API:
29 * HealthCheck
30     URL: http://<host>:8080/restservices/clds/v1/clds/healthcheck
31         if in good health it will return OK: "HTTP/1.1 200", and the following json string content:
32 .. code-block:: json
33     {
34         "healthCheckComponent": "CLDS-APP",
35         "healthCheckStatus": "UP",
36         "description": "OK"
37     }
38
39
40 Consumed APIs
41 -------------
42 CLAMP uses the API's exposed by the following ONAP components:
43 * SDC : REST based interface exposed by the SDC, Distribution of service to DCAE
44 * DCAE: REST based interface exposed by DCAE, Common Controller Framework, DCAE microservices onboarded (TCA, Stringmatch, Holmes (optional))
45 * Policy: REST based interface (the Policy team provide a "jar" to handle the communication), both XACML and Drools PDP, APIs to App-C/VF-C/SDN-C
46
47
48 Delivery
49 --------
50 CLAMP component is composed of a UI layer and a BackEnd layer and packaged into a single container.
51 CLAMP also requires a database instance with 2 DB, it uses MariaDB.
52
53 .. blockdiag::
54
55
56    blockdiag layers {
57    orientation = portrait
58    CLAMP_UI -> CLAMP_BACKEND;
59    CLAMP_BACKEND -> CAMUNDADB;
60    CLAMP_BACKEND -> CLDSDB;
61    group l1 {
62    color = blue;
63    label = "CLAMP container";
64    CLAMP_UI; CLAMP_BACKEND;
65    }
66    group l3 {
67    color = orange;
68    label = "MariaDB container";
69    CAMUNDADB; CLDSDB;
70    }
71    }
72
73
74 Logging & Diagnostic Information
75 --------------------------------
76 CLAMP uses logback framework to generate logs. The logback.xml file cand be found under the [src/main/resources/ folder](src/main/resources).
77
78 With the default log settings, all logs will be generated into console and into root.log file under the CLAMP root folder. The root.log file is not allowed to be appended, thus restarting the CLAMP will result in cleaning of the old log files.
79
80
81
82 Installation
83 ------------
84 A [docker-compose example file](extra/docker/clamp/docker-compose.yml) can be found under the [extra/docker/clamp/ folder](extra/docker/).
85
86 Once the image has been built and is available locally, you can use the `docker-compose up` command to deploy a prepopullated database and a CLAMP instance available on [http://localhost:8080/designer/index.html](http://localhost:8080/designer/index.html).
87
88 Configuration
89 -------------
90 .. Where are they provided?
91 .. What are parameters and values?
92
93
94 Currently, the CLAMP docker image can be deployed with small configuration needs. Though, you might need to make small adjustments to the configuration. As CLAMP is spring based, you can use the SPRING_APPLICATION_JSON environment variable to update its parameters.
95
96 .. TODO detail config parameters and the usage
97
98
99 There are two needed datasource for Clamp. By default, both will try to connect to the localhost server using the credentials available in the example SQL files. If you need to change the default database host and/or credentials, you can do it by using the following json as SPRING_APPLICATION_JSON environment variable :
100
101 .. code-block:: json
102
103     {
104         "spring.datasource.camunda.url": "jdbc:mariadb://anotherDB.onap.org:3306/camundabpm?verifyServerCertificate=false&useSSL=false&requireSSL=false&autoReconnect=true",
105         "spring.datasource.camunda.username": "admin",
106         "spring.datasource.camunda.password": "password",
107         "spring.datasource.cldsdb.url": "jdbc:mariadb://anotherDB.onap.org:3306/cldsdb4?verifyServerCertificate=false&useSSL=false&requireSSL=false&autoReconnect=true",
108         "spring.datasource.cldsdb.username": "admin",
109         "spring.datasource.cldsdb.password": "password"
110     }
111
112 OR
113
114 .. code-block:: json
115
116     {
117         "spring":
118         {
119             "datasource":
120             {
121                 "camunda":
122                 {
123                     "url": "jdbc:mariadb://anotherDB.onap.org:3306/camundabpm?verifyServerCertificate=false&useSSL=false&requireSSL=false&autoReconnect=true",
124                     "username": "admin",
125                     "password": "password"
126                 },
127
128                 "cldsdb":
129                 {
130                 "url": "jdbc:mariadb://anotherDB.onap.org:3306/cldsdb4?verifyServerCertificate=false&useSSL=false&requireSSL=false&autoReconnect=true",
131                 "username": "admin",
132                 "password": "password"
133                 }
134             }
135         }
136     }
137
138 Administration
139 --------------
140
141 A user can access CLAMP UI at the following URL : http://localhost:8080/designer/index.html.
142 (in this URL 'localhost' must be replaced by the actual host where CLAMP has been installed if it is not your current localhost)
143 .. code-block::
144     Default username : admin
145     Default password : password
146
147
148 Human Interfaces
149 ----------------
150 .. Basic info on the interface type, ports/protocols provided over, etc.
151
152 User Interface (CLAMP Designer) - serve to configure control loop
153 The following actions are done using the UI:
154
155 •     Design a control loop flow by selecting a predefined template from a list
156      (a template is an orchestration chain of Micro-services, so the template defines how the micro-services of the control loop are chained together)
157 •     Give value to the configuration the parameters of each micro-service of the control loop
158 •     Select the service and VNF(of that service) to which the control loop will be attached
159 •     Configure the operational policy(the actual operation resulting from the control loop)
160 •     Generate the “TOSCA” blueprint that will be used by DCAE to start the control loop
161         (The blueprint will be sent first to SDC and SDC will publish it to DCAE)
162 •     Trigger the deployment of the Control loop in DCAE
163 •     Control (start/stop) the operation of the control loop in DCAE
164
165
166
167 HealthCheck API - serve to verify CLAMP status (see offered API's section)