TCA spec updates: URI and tca_policy
[dcaegen2/analytics/tca.git] / dpo / tcaSpec.json
1 {\r
2   "self": {\r
3     "name": "cdap.tca.hi.lo.app",\r
4     "version": "1.0.5",\r
5     "description": "cdap tca hi lo application",\r
6     "component_type": "cdap"\r
7   },\r
8   "streams": {\r
9     "subscribes": [\r
10       {\r
11         "config_key": "tca_handle_in",\r
12         "format": "VES_specification",\r
13         "version": "5.28.4",\r
14         "type": "message router"\r
15       }\r
16     ],\r
17     "publishes": [\r
18       {\r
19         "config_key": "tca_handle_out",\r
20         "format": "TCA Alert Definition",\r
21         "version": "1.0.0",\r
22         "type": "message router"\r
23       }\r
24     ]\r
25   },\r
26   "services": {\r
27     "calls": [],\r
28     "provides": []\r
29   },\r
30   "auxilary": {\r
31     "streamname": "TCASubscriberOutputStream",\r
32     "artifact_name": "dcae-analytics-cdap-tca",\r
33     "artifact_version": "2.0.0",\r
34     "namespace": "cdap_tca_hi_lo",\r
35     "programs": [\r
36       {\r
37         "program_type": "flows",\r
38         "program_id": "TCAVESCollectorFlow"\r
39       },\r
40       {\r
41         "program_type": "workers",\r
42         "program_id": "TCADMaaPMRSubscriberWorker"\r
43       },\r
44       {\r
45         "program_type": "workers",\r
46         "program_id": "TCADMaaPMRPublisherWorker"\r
47       }\r
48     ]\r
49   },\r
50   "artifacts": [\r
51     {\r
52       "uri": "https://nexus.onap.org/service/local/repositories/staging/content/org/onap/dcaegen2/analytics/tca/dcae-analytics-cdap-tca/2.0.0/dcae-analytics-cdap-tca-2.0.0.jar",\r
53       "type": "jar"\r
54     }\r
55   ],\r
56   "parameters": {\r
57     "app_config": [\r
58       {\r
59         "name": "appName",\r
60         "description": "CDAP Application Name for TCA App",\r
61         "value": "dcae-tca"\r
62       },\r
63       {\r
64         "name": "appDescription",\r
65         "description": "CDAP Application Description for TCA App",\r
66         "value": "DCAE Analytics Threshold Crossing Alert Application"\r
67       },\r
68       {\r
69         "name": "tcaSubscriberOutputStreamName",\r
70         "description": "Name of Stream where TCA DMaaP Subscriber pushes incoming messages to TCA App for processing",\r
71         "value": "TCASubscriberOutputStream"\r
72       },\r
73       {\r
74         "name": "thresholdCalculatorFlowletInstances",\r
75         "description": "Number of instances for Threshold Calculator",\r
76         "value": 2\r
77       },\r
78       {\r
79         "name": "tcaVESMessageStatusTableName",\r
80         "description": "TCA Message Status Table Name where status of each TCA message is stored",\r
81         "value": "TCAVESMessageStatusTable"\r
82       },\r
83       {\r
84         "name": "tcaVESMessageStatusTableTTLSeconds",\r
85         "description": "Time to Live for entries in Message Status Table",\r
86         "value": 86400\r
87       },\r
88       {\r
89         "name": "tcaVESAlertsTableName",\r
90         "description": "Table where TCA generated alerts are temporarily stored before published to DMaaP MR topic",\r
91         "value": "TCAVESAlertsTable"\r
92       },\r
93       {\r
94         "name": "tcaVESAlertsTableTTLSeconds",\r
95         "description": "Time to Live for entries in Alerts Table",\r
96         "value": 1728000\r
97       },\r
98       {\r
99         "name" : "tcaAlertsAbatementTableName",\r
100         "description" : "Table where information to determine sending of Abatement Alerts is stored",\r
101         "value" : "TCAAlertsAbatementTable"\r
102       },\r
103       {\r
104         "name" : "tcaAlertsAbatementTableTTLSeconds",\r
105         "description": "Time to Live for entries in  Alerts Abatement Table",\r
106         "value" : 1728000\r
107       }\r
108     ],\r
109     "app_preferences": [\r
110       {\r
111         "name" :  "subscriberHostName",\r
112         "description" :  "",\r
113         "value" : "HOSTNAME"\r
114       },\r
115       {\r
116         "name" :  "subscriberHostPort",\r
117         "description" :  "",\r
118         "value" : 1234\r
119       },\r
120       {\r
121         "name" :  "subscriberTopicName",\r
122         "description" :  "",\r
123         "value" : "com.att.dcae.dmaap.mtnje2.DcaeTestVESSub"\r
124       },\r
125       {\r
126         "name" :  "subscriberProtocol",\r
127         "description" :  "",\r
128         "value" : "https"\r
129       },\r
130       {\r
131         "name" :  "subscriberUserName",\r
132         "description" :  "",\r
133         "value" : "USERNAME"\r
134       },\r
135       {\r
136         "name" :  "subscriberUserPassword",\r
137         "description" :  "",\r
138         "value" : "PASSWORD"\r
139       },\r
140       {\r
141         "name": "subscriberContentType",\r
142         "description": "Subscriber Content Type",\r
143         "value": "application/json"\r
144       },\r
145       {\r
146         "name": "subscriberConsumerId",\r
147         "description": "Subscriber Consumer Id",\r
148         "value": "c12"\r
149       },\r
150       {\r
151         "name": "subscriberConsumerGroup",\r
152         "description": "Subscriber Group Id",\r
153         "value": "OpenDCAE-c12"\r
154       },\r
155       {\r
156         "name": "subscriberTimeoutMS",\r
157         "description": "Subscriber timeout in milliseconds",\r
158         "value": -1\r
159       },\r
160       {\r
161         "name": "subscriberMessageLimit",\r
162         "description": "Subscriber max message fetch limit",\r
163         "value": -1\r
164       },\r
165       {\r
166         "name": "subscriberPollingInterval",\r
167         "description": "Subscriber Polling Interval in milliseconds",\r
168         "value": 30000\r
169       },\r
170       {\r
171         "name" :  "publisherHostName",\r
172         "description" :  "",\r
173         "value" : "HOSTNAME"\r
174       },\r
175       {\r
176         "name" :  "publisherHostPort",\r
177         "description" :  "",\r
178         "value" : 1234\r
179       },\r
180       {\r
181         "name" :  "publisherTopicName",\r
182         "description" :  "",\r
183         "value" : "com.att.dcae.dmaap.mtnje2.DcaeTestVESPub"\r
184       },\r
185       {\r
186         "name" :  "publisherProtocol",\r
187         "description" :  "",\r
188         "value" : "https"\r
189       },\r
190       {\r
191         "name" :  "publisherUserName",\r
192         "description" :  "",\r
193         "value" : "USERNAME"\r
194       },\r
195       {\r
196         "name" :  "publisherUserPassword",\r
197         "description" :  "",\r
198         "value" : "PASSWORD"\r
199       },\r
200       {\r
201         "name": "publisherContentType",\r
202         "description": "Publisher Content Type",\r
203         "value": "application/json"\r
204       },\r
205       {\r
206         "name": "publisherMaxBatchSize",\r
207         "description": "Publisher max batch size",\r
208         "value": 1\r
209       },\r
210       {\r
211         "name": "publisherMaxRecoveryQueueSize",\r
212         "description": "Publisher Max Recovery Queue Size",\r
213         "value": 100000\r
214       },\r
215       {\r
216         "name": "publisherPollingInterval",\r
217         "description": "Publisher Polling Interval in milliseconds",\r
218         "value": 20000\r
219       },\r
220       {\r
221         "name": "enableAlertCEFFormat",\r
222         "description": "Enable output alert to be in CEF Format",\r
223         "value": "false"\r
224       },
225       {
226         "name": "enableAAIEnrichment",
227         "description": "Enable A&AI Enrichment of generated TCA Alerts",
228         "value": "true"
229       },
230       {
231         "name": "aaiEnrichmentHost",
232         "description": "A&AI Enrichment API Host name",
233         "value": "123.123.123.123"
234       },
235       {
236         "name": "aaiEnrichmentPortNumber",
237         "description": "A&AI Enrichment API Host port number",
238         "value": 8443
239       },
240       {
241         "name": "aaiEnrichmentProtocol",
242         "description": "A&AI Enrichment API protocol",
243         "value": "https"
244       },
245       {
246         "name": "aaiEnrichmentUserName",
247         "description": "A&AI Enrichment API username",
248         "value": "USERNAME"
249       },
250       {
251         "name": "aaiEnrichmentUserPassword",
252         "description": "A&AI Enrichment API password",
253         "value": "PASSWORD"
254       },
255       {
256         "name": "aaiEnrichmentIgnoreSSLCertificateErrors",
257         "description": "A&AI Ignore SSL Certification Errors",
258         "value": "true"
259       },
260       {
261         "name": "aaiVNFEnrichmentAPIPath",
262         "description": "A&AI VNF Enrichment API Path",
263         "value": "/aai/v11/network/generic-vnfs/generic-vnf"
264       },
265       {
266         "name": "aaiVMEnrichmentAPIPath",
267         "description": "A&AI VM Enrichment API Path",
268         "value": "/aai/v11/search/nodes-query"
269       },
270       {
271         "name": "aaiEnrichmentProxyURL",
272         "description": "A&AI Enrichment API Proxy URL",
273         "value": "URL"
274       },      \r
275       {\r
276         "name": "tca_policy",\r
277         "description": "TCA Policy JSON",\r
278         "value": "{\"domain\":\"measurementsForVfScaling\",\"metricsPerEventName\":[{\"eventName\":\"vFirewallBroadcastPackets\",\"controlLoopSchemaType\":\"VNF\",\"policyScope\":\"DCAE\",\"policyName\":\"DCAE.Config_tca-hi-lo\",\"policyVersion\":\"v0.0.1\",\"thresholds\":[{\"closedLoopControlName\":\"ControlLoop-vFirewall-d0a1dfc6-94f5-4fd4-a5b5-4630b438850a\",\"version\":\"1.0.2\",\"fieldPath\":\"$.event.measurementsForVfScalingFields.vNicUsageArray[*].receivedTotalPacketsDelta\",\"thresholdValue\":1000,\"direction\":\"GREATER_OR_EQUAL\",\"severity\":\"MAJOR\",\"closedLoopEventStatus\":\"ONSET\"},{\"closedLoopControlName\":\"ControlLoop-vFirewall-d0a1dfc6-94f5-4fd4-a5b5-4630b438850a\",\"version\":\"1.0.2\",\"fieldPath\":\"$.event.measurementsForVfScalingFields.vNicUsageArray[*].receivedTotalPacketsDelta\",\"thresholdValue\":20000,\"direction\":\"GREATER_OR_EQUAL\",\"severity\":\"CRITICAL\",\"closedLoopEventStatus\":\"ONSET\"}]},{\"eventName\":\"vLoadBalancer\",\"controlLoopSchemaType\":\"VM\",\"policyScope\":\"DCAE\",\"policyName\":\"DCAE.Config_tca-hi-lo\",\"policyVersion\":\"v0.0.1\",\"thresholds\":[{\"closedLoopControlName\":\"CL-LBAL-LOW-TRAFFIC-SIG-FB480F95-A453-6F24-B767-FD703241AB1A\",\"version\":\"1.0.2\",\"fieldPath\":\"$.event.measurementsForVfScalingFields.vNicPerformanceArray[*].receivedBroadcastPacketsAccumulated\",\"thresholdValue\":500,\"direction\":\"LESS_OR_EQUAL\",\"severity\":\"MAJOR\",\"closedLoopEventStatus\":\"ONSET\"},{\"closedLoopControlName\":\"CL-LBAL-HIGH-TRAFFIC-SIG-0C5920A6-B564-8035-C878-0E814352BC2B\",\"version\":\"1.0.2\",\"fieldPath\":\"$.event.measurementsForVfScalingFields.vNicPerformanceArray[*].receivedBroadcastPacketsAccumulated\",\"thresholdValue\":5000,\"direction\":\"GREATER_OR_EQUAL\",\"severity\":\"CRITICAL\",\"closedLoopEventStatus\":\"ONSET\"}]},{\"eventName\":\"Measurement_vGMUX\",\"controlLoopSchemaType\":\"VM\",\"policyScope\":\"DCAE\",\"policyName\":\"DCAE.Config_tca-hi-lo\",\"policyVersion\":\"v0.0.1\",\"thresholds\":[{\"closedLoopControlName\":\"CL-vCPEvGMUX-TRAFFIC-SIG-FB480F95-A453-6F24-B767-FD703241ABA1\",\"version\":\"1.0.2\",\"fieldPath\":\"$.event.measurementsForVfScalingFields.additionalMeasurements[*].arrayOfFields[0].value\",\"thresholdValue\":0,\"direction\":\"EQUAL\",\"severity\":\"MAJOR\",\"closedLoopEventStatus\":\"ABATED\"},{\"closedLoopControlName\":\"CL-vCPEvGMUX-TRAFFIC-SIG-FB480F95-A453-6F24-B767-FD703241ABA1\",\"version\":\"1.0.2\",\"fieldPath\":\"$.event.measurementsForVfScalingFields.additionalMeasurements[*].arrayOfFields[0].value\",\"thresholdValue\":0,\"direction\":\"GREATER\",\"severity\":\"CRITICAL\",\"closedLoopEventStatus\":\"ONSET\"}]}]}",\r
279         "policy_editable": true,
280         "policy_schema": [{
281           "name": "domain",
282           "description": "Domain name to which TCA needs to be applied",
283           "type": "string",
284           "value": "measurementsForVfScaling",
285           "constraints": [{
286             "equal": "measurementsForVfScaling"
287           }]
288         }, {
289           "name": "metricsPerEventName",
290           "description": "Contains eventName and threshold details that need to be applied to given eventName",
291           "type": "list",
292           "entry_schema": [{
293             "name": "eventName",
294             "description": "Event name to which thresholds need to be applied",
295             "type": "string",
296             "value": ""
297           }, {
298             "name": "controlLoopSchemaType",
299             "description": "Specifies Control Loop Schema Type for the event Name e.g. VNF, VM",
300             "type": "string",
301             "value": "",
302             "constraints": [{
303               "valid_values": ["VM", "VNF"]
304             }]
305           }, {
306             "name": "policyScope",
307             "description": "TCA Policy Scope",
308             "type": "string",
309             "value": ""
310           }, {
311             "name": "policyName",
312             "description": "TCA Policy Scope Name",
313             "type": "string",
314             "value": ""
315           }, {
316             "name": "policyVersion",
317             "description": "TCA Policy Scope Version",
318             "type": "string",
319             "value": ""
320           }, {
321             "name": "thresholds",
322             "description": "Thresholds associated with eventName",
323             "type": "list",
324             "entry_schema": [{
325               "name": "closedLoopControlName",
326               "description": "Closed Loop Control Name associated with the threshold",
327               "type": "string",
328               "value": ""
329             }, {
330               "name": "version",
331               "description": "Version number associated with the threshold",
332               "type": "string",
333               "value": ""
334             }, {
335               "name": "fieldPath",
336               "description": "Json field Path as per CEF message which needs to be analyzed for TCA",
337               "type": "string",
338               "value": ""
339             }, {
340               "name": "thresholdValue",
341               "description": "Threshold value for the field Path inside CEF message",
342               "type": "number",
343               "value": ""
344             }, {
345               "name": "direction",
346               "description": "Direction of the threshold",
347               "type": "string",
348               "value": "",
349               "constraints": [{
350                 "valid_values": [
351                       "LESS",
352                       "LESS_OR_EQUAL",
353                       "GREATER",
354                       "GREATER_OR_EQUAL",\r
355                       "EQUAL"
356                 ]
357               }]
358             }, {
359               "name": "closedLoopEventStatus",
360               "description": "Closed Loop Event Status of the threshold",
361               "type": "string",
362               "value": "",
363               "constraints": [{
364                 "valid_values": ["ONSET", "ABATED"]
365               }]
366             }, {
367               "name": "severity",
368               "description": "Threshold Event Severity",
369               "value": "",
370               "type": "string",
371               "constraints": [{
372                 "valid_values": [
373                   "CRITICAL",
374                   "MAJOR",
375                   "MINOR",
376                   "WARNING",
377                   "NORMAL"
378                 ]
379               }]
380             }]
381           }]
382         }]
383       }
384     ],
385     "program_preferences": []
386   }
387 }