TCA: use VES 5.28.4
[dcaegen2/analytics/tca.git] / dpo / tcaSpec.json
1 {
2   "self": {
3     "name": "cdap.tca.hi.lo.app",
4     "version": "1.0.4",
5     "description": "cdap tca hi lo application",
6     "component_type": "cdap"
7   },
8   "streams": {
9     "subscribes": [
10       {
11         "config_key": "tca_handle_in",
12         "format": "VES_specification",
13         "version": "5.28.4",
14         "type": "message router"
15       }
16     ],
17     "publishes": [
18       {
19         "config_key": "tca_handle_out",
20         "format": "TCA Alert Definition",
21         "version": "1.0.0",
22         "type": "message router"
23       }
24     ]
25   },
26   "services": {
27     "calls": [],
28     "provides": []
29   },
30   "auxilary": {
31     "streamname": "TCASubscriberOutputStream",
32     "artifact_name": "dcae-analytics-cdap-tca",
33     "artifact_version": "2.0.0",
34     "namespace": "cdap_tca_hi_lo",
35     "programs": [
36       {
37         "program_type": "flows",
38         "program_id": "TCAVESCollectorFlow"
39       },
40       {
41         "program_type": "workers",
42         "program_id": "TCADMaaPMRSubscriberWorker"
43       },
44       {
45         "program_type": "workers",
46         "program_id": "TCADMaaPMRPublisherWorker"
47       }
48     ]
49   },
50   "artifacts": [
51     {
52       "uri": "${nexusproxy}/repository/dcae-dev-raw/jar_files/dcae-analytics-tca-2.0.0.jar",
53       "type": "jar"
54     }
55   ],
56   "parameters": {
57     "app_config": [
58       {
59         "name": "appName",
60         "description": "CDAP Application Name for TCA App",
61         "value": "dcae-tca"
62       },
63       {
64         "name": "appDescription",
65         "description": "CDAP Application Description for TCA App",
66         "value": "DCAE Analytics Threshold Crossing Alert Application"
67       },
68       {
69         "name": "tcaSubscriberOutputStreamName",
70         "description": "Name of Stream where TCA DMaaP Subscriber pushes incoming messages to TCA App for processing",
71         "value": "TCASubscriberOutputStream"
72       },
73       {
74         "name": "thresholdCalculatorFlowletInstances",
75         "description": "Number of instances for Threshold Calculator",
76         "value": 2
77       },
78       {
79         "name": "tcaVESMessageStatusTableName",
80         "description": "TCA Message Status Table Name where status of each TCA message is stored",
81         "value": "TCAVESMessageStatusTable"
82       },
83       {
84         "name": "tcaVESMessageStatusTableTTLSeconds",
85         "description": "Time to Live for entries in Message Status Table",
86         "value": 86400
87       },
88       {
89         "name": "tcaVESAlertsTableName",
90         "description": "Table where TCA generated alerts are temporarily stored before published to DMaaP MR topic",
91         "value": "TCAVESAlertsTable"
92       },
93       {
94         "name": "tcaVESAlertsTableTTLSeconds",
95         "description": "Time to Live for entries in Alerts Table",
96         "value": 1728000
97       },
98       {
99         "name" : "tcaAlertsAbatementTableName",
100         "description" : "Table where information to determine sending of Abatement Alerts is stored",
101         "value" : "TCAAlertsAbatementTable"
102       },
103       {
104         "name" : "tcaAlertsAbatementTableTTLSeconds",
105         "description": "Time to Live for entries in  Alerts Abatement Table",
106         "value" : 1728000
107       }
108     ],
109     "app_preferences": [
110       {
111         "name": "subscriberContentType",
112         "description": "Subscriber Content Type",
113         "value": "application/json"
114       },
115       {
116         "name": "subscriberConsumerId",
117         "description": "Subscriber Consumer Id",
118         "value": "c12"
119       },
120       {
121         "name": "subscriberConsumerGroup",
122         "description": "Subscriber Group Id",
123         "value": "OpenDCAE-c12"
124       },
125       {
126         "name": "subscriberTimeoutMS",
127         "description": "Subscriber timeout in milliseconds",
128         "value": -1
129       },
130       {
131         "name": "subscriberMessageLimit",
132         "description": "Subscriber max message fetch limit",
133         "value": -1
134       },
135       {
136         "name": "subscriberPollingInterval",
137         "description": "Subscriber Polling Interval in milliseconds",
138         "value": 30000
139       },
140       {
141         "name": "publisherContentType",
142         "description": "Publisher Content Type",
143         "value": "application/json"
144       },
145       {
146         "name": "publisherMaxBatchSize",
147         "description": "Publisher max batch size",
148         "value": 1
149       },
150       {
151         "name": "publisherMaxRecoveryQueueSize",
152         "description": "Publisher Max Recovery Queue Size",
153         "value": 100000
154       },
155       {
156         "name": "publisherPollingInterval",
157         "description": "Publisher Polling Interval in milliseconds",
158         "value": 20000
159       },
160       {
161         "name": "enableAlertCEFFormat",
162         "description": "",
163         "value": "false"
164       },
165       {
166         "name": "tca_policy",
167         "description": "TCA Policy JSON",
168         "value": "{\"domain\":\"measurementsForVfScaling\",\"metricsPerEventName\":[{\"eventName\":\"Mfvs_eNodeB_RANKPI\",\"controlLoopSchemaType\":\"VNF\",\"policyScope\":\"resource=vFirewall;type=configuration\",\"policyName\":\"configuration.dcae.microservice.tca.xml\",\"policyVersion\":\"v0.0.1\",\"thresholds\":[{\"closedLoopControlName\":\"CL-FRWL-LOW-TRAFFIC-SIG-d925ed73-8231-4d02-9545-db4e101f88f8\",\"closedLoopEventStatus\":\"ONSET\",\"version\":\"1.0.2\",\"fieldPath\":\"$.event.measurementsForVfScalingFields.vNicPerformanceArray[*].receivedBroadcastPacketsAccumulated\",\"thresholdValue\":4000,\"direction\":\"LESS_OR_EQUAL\",\"severity\":\"MAJOR\"},{\"closedLoopControlName\":\"CL-FRWL-HIGH-TRAFFIC-SIG-EA36FE84-9342-5E13-A656-EC5F21309A09\",\"closedLoopEventStatus\":\"ONSET\",\"version\":\"1.0.2\",\"fieldPath\":\"$.event.measurementsForVfScalingFields.vNicPerformanceArray[*].receivedBroadcastPacketsAccumulated\",\"thresholdValue\":20000,\"direction\":\"GREATER_OR_EQUAL\",\"severity\":\"CRITICAL\"},{\"closedLoopControlName\":\"CL-FRWL-HIGH-TRAFFIC-SIG-EA36FE84-9342-5E13-A656-EC5F21309A09\",\"closedLoopEventStatus\":\"ABATED\",\"version\":\"1.0.2\",\"fieldPath\":\"$.event.measurementsForVfScalingFields.vNicPerformanceArray[*].receivedBroadcastPacketsAccumulated\",\"thresholdValue\":0,\"direction\":\"EQUAL\",\"severity\":\"CRITICAL\"}]},{\"eventName\":\"vLoadBalancer\",\"controlLoopSchemaType\":\"VNF\",\"policyScope\":\"resource=vLoadBalancer;type=configuration\",\"policyName\":\"configuration.dcae.microservice.tca.xml\",\"policyVersion\":\"v0.0.1\",\"thresholds\":[{\"closedLoopControlName\":\"CL-LBAL-LOW-TRAFFIC-SIG-FB480F95-A453-6F24-B767-FD703241AB1A\",\"closedLoopEventStatus\":\"ONSET\",\"version\":\"1.0.2\",\"fieldPath\":\"$.event.measurementsForVfScalingFields.vNicPerformanceArray[*].receivedBroadcastPacketsAccumulated\",\"thresholdValue\":500,\"direction\":\"LESS_OR_EQUAL\",\"severity\":\"MAJOR\"},{\"closedLoopControlName\":\"CL-LBAL-LOW-TRAFFIC-SIG-0C5920A6-B564-8035-C878-0E814352BC2B\",\"closedLoopEventStatus\":\"ONSET\",\"version\":\"1.0.2\",\"fieldPath\":\"$.event.measurementsForVfScalingFields.vNicPerformanceArray[*].receivedBroadcastPacketsAccumulated\",\"thresholdValue\":5000,\"direction\":\"GREATER_OR_EQUAL\",\"severity\":\"CRITICAL\"}]}]}"
169       }
170     ],
171     "program_preferences": [],
172     "policy_schema": [
173       {
174         "name": "domain",
175         "description": "Domain name to which TCA needs to be applied",
176         "type": "string",
177         "value": "measurementsForVfScaling",
178         "constraints": [
179           {
180             "equal": "measurementsForVfScaling"
181           }
182         ]
183       },
184       {
185         "name": "metricsPerEventName",
186         "description": "Contains eventName and threshold details that need to be applied to given eventName",
187         "type": "list",
188         "entry_schema": [
189           {
190             "name": "eventName",
191             "description": "Event name to which thresholds need to be applied",
192             "type": "string",
193             "value": ""
194           },
195           {
196             "name": "controlLoopSchemaType",
197             "description": "Specifies Control Loop Schema Type for the event Name e.g. VNF, VM",
198             "type": "string",
199             "value": "",
200             "constraints": [
201               {
202                 "valid_value": [
203                   "VM",
204                   "VNF"
205                 ]
206               }
207             ]
208           },
209           {
210             "name": "policyScope",
211             "description": "TCA Policy Scope",
212             "type": "string",
213             "value": ""
214           },
215           {
216             "name": "policyName",
217             "description": "TCA Policy Scope Name",
218             "type": "string",
219             "value": ""
220           },
221           {
222             "name": "policyVersion",
223             "description": "TCA Policy Scope Version",
224             "type": "string",
225             "value": ""
226           },
227           {
228             "name": "thresholds",
229             "description": "Thresholds associated with eventName",
230             "type": "list",
231             "entry_schema": [
232               {
233                 "name": "closedLoopControlName",
234                 "description": "Closed Loop Control Name associated with the threshold",
235                 "type": "string",
236                 "value": ""
237               },
238               {
239                 "name": "version",
240                 "description": "Version number associated with the threshold",
241                 "type": "string",
242                 "value": ""
243               },
244               {
245                 "name": "fieldPath",
246                 "description": "Json field Path as per CEF message which needs to be analyzed for TCA",
247                 "type": "string",
248                 "value": ""
249               },
250               {
251                 "name": "thresholdValue",
252                 "description": "Threshold value for the field Path inside CEF message",
253                 "type": "number",
254                 "value": ""
255               },
256               {
257                 "name": "direction",
258                 "description": "Direction of the threshold",
259                 "type": "string",
260                 "value": "",
261                 "constraints": [
262                   {
263                     "valid_value": [
264                       "LESS",
265                       "LESS_OR_EQUAL",
266                       "GREATER",
267                       "GREATER_OR_EQUAL"
268                     ]
269                   }
270                 ]
271               },
272               {
273                 "name": "closedLoopEventStatus",
274                 "description": "Closed Loop Event Status of the threshold",
275                 "type": "string",
276                 "value": "",
277                 "constraints": [
278                   {
279                     "valid_value": [
280                       "ONSET",
281                       "ABATED"
282                     ]
283                   }
284                 ]
285               },
286               {
287                 "name": "severity",
288                 "description": "Threshold Event Severity",
289                 "value": "",
290                 "type": "string",
291                 "constraints": [
292                   {
293                     "valid_value": [
294                       "CRITICAL",
295                       "MAJOR",
296                       "MINOR",
297                       "WARNING",
298                       "NORMAL"
299                     ]
300                   }
301                 ]
302               }
303             ]
304           }
305         ]
306       }
307     ]
308   }
309 }
310