...
Code Block | ||||
---|---|---|---|---|
| ||||
{
"artifact": {
"name": "dcae-analytics-cdap-tca",
"version": "2.0.0",
"scope": "user"
},
"config": {
"appName": "dcae-tca",
"appDescription": "DCAE Analytics Threshold Crossing Alert Application",
"tcaVESMessageStatusTableName": "TCAVESMessageStatusTable",
"tcaVESMessageStatusTableTTLSeconds": 86400.0,
"tcaAlertsAbatementTableName": "TCAAlertsAbatementTable",
"tcaAlertsAbatementTableTTLSeconds": 1728000.0,
"tcaVESAlertsTableName": "TCAVESAlertsTable",
"tcaVESAlertsTableTTLSeconds": 1728000.0,
"thresholdCalculatorFlowletInstances": 2.0,
"tcaSubscriberOutputStreamName": "TCASubscriberOutputStream"
}
}
|
...
Code Block | ||||||
---|---|---|---|---|---|---|
| ||||||
#!/bin/sh TCA_JAR=dcae-analytics-cdap-tca-2.0.0.jar rm -f /home/ubuntu/$TCA_JAR cd /home/ubuntu/ wget https://nexus.onap.org/service/local/repositories/staging/content/org/onap/dcaegen2/analytics/tca/dcae-analytics-cdap-tca/2.0.0/$TCA_JAR if [ $? -eq 0 ]; then if [ -f /home/ubuntu/$TCA_JAR ]; then echo "Restarting TCA CDAP application using $TCA_JAR artifact" else echo "ERROR: $TCA_JAR missing" exit 1 fi else echo "ERROR: $TCA_JAR not found in nexus" exit 1 fi # stop programs curl -X POST http://localhost:11015/v3/namespaces/cdap_tca_hi_lo/apps/dcae-tca/workers/TCADMaaPMRPublisherWorker/stop curl -X POST http://localhost:11015/v3/namespaces/cdap_tca_hi_lo/apps/dcae-tca/workers/TCADMaaPMRSubscriberWorker/stop curl -X POST http://localhost:11015/v3/namespaces/cdap_tca_hi_lo/apps/dcae-tca/flows/TCAVESCollectorFlow/stop # delete application curl -X DELETE http://localhost:11015/v3/namespaces/cdap_tca_hi_lo/apps/dcae-tca# delete artifact curl -X DELETE http://localhost:11015/v3/namespaces/cdap_tca_hi_lo/artifacts/dcae-analytics-cdap-tca/versions/2.0.0 # load artifact curl -X POST --data-binary @/home/ubuntu/$TCA_JAR http://localhost:11015/v3/namespaces/cdap_tca_hi_lo/artifacts/dcae-analytics-cdap-tcaechotca echo # create app curl -X PUT -d @/home/ubuntu/tca_app_config.json http://localhost:11015/v3/namespaces/cdap_tca_hi_lo/apps/dcae-tca# load preferences curl -X PUT -d @/home/ubuntu/tca_app_preferences.json http://localhost:11015/v3/namespaces/cdap_tca_hi_lo/apps/dcae-tca/preferences # start programs curl -X POST http://localhost:11015/v3/namespaces/cdap_tca_hi_lo/apps/dcae-tca/workers/TCADMaaPMRPublisherWorker/start curl -X POST http://localhost:11015/v3/namespaces/cdap_tca_hi_lo/apps/dcae-tca/workers/TCADMaaPMRSubscriberWorker/start curl -X POST http://localhost:11015/v3/namespaces/cdap_tca_hi_lo/apps/dcae-tca/flows/TCAVESCollectorFlow/startechostart echo # get status of programs curl http://localhost:11015/v3/namespaces/cdap_tca_hi_lo/apps/dcae-tca/workers/TCADMaaPMRPublisherWorker/status curl http://localhost:11015/v3/namespaces/cdap_tca_hi_lo/apps/dcae-tca/workers/TCADMaaPMRSubscriberWorker/status curl http://localhost:11015/v3/namespaces/cdap_tca_hi_lo/apps/dcae-tca/flows/TCAVESCollectorFlow/statusechostatus echo |
8) Verify TCA application and logs via CDAP GUI processes
...