vagrant | ea1a3df | 2018-04-30 19:52:01 +0000 | [diff] [blame] | 1 | # |
| 2 | # ============LICENSE_START==================================================== |
| 3 | # ============================================================================= |
Vijay Venkatesh Kumar | aa72417 | 2019-05-07 20:03:36 +0000 | [diff] [blame] | 4 | # Copyright (c) 2019 AT&T Intellectual Property. All rights reserved. |
vagrant | ea1a3df | 2018-04-30 19:52:01 +0000 | [diff] [blame] | 5 | # ============================================================================= |
| 6 | # Licensed under the Apache License, Version 2.0 (the "License"); |
| 7 | # you may not use this file except in compliance with the License. |
| 8 | # You may obtain a copy of the License at |
| 9 | # |
| 10 | # http://www.apache.org/licenses/LICENSE-2.0 |
| 11 | # |
| 12 | # Unless required by applicable law or agreed to in writing, software |
| 13 | # distributed under the License is distributed on an "AS IS" BASIS, |
| 14 | # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
| 15 | # See the License for the specific language governing permissions and |
| 16 | # limitations under the License. |
| 17 | # ============LICENSE_END====================================================== |
| 18 | |
| 19 | tosca_definitions_version: cloudify_dsl_1_3 |
| 20 | |
| 21 | description: > |
| 22 | This blueprint deploys/manages the TCA module as a Docker container |
| 23 | |
| 24 | imports: |
Vijay Venkatesh Kumar | 2c662f2 | 2019-09-09 15:33:32 +0000 | [diff] [blame] | 25 | - https://www.getcloudify.org/spec/cloudify/4.5.5/types.yaml |
Jack Lucas | 01d6019 | 2020-06-17 17:11:17 -0400 | [diff] [blame] | 26 | - plugin:k8splugin?version=3.0.0 |
| 27 | - plugin:clamppolicyplugin?version=1.1.0 |
vagrant | ea1a3df | 2018-04-30 19:52:01 +0000 | [diff] [blame] | 28 | inputs: |
| 29 | aaiEnrichmentHost: |
| 30 | type: string |
| 31 | default: "aai.onap.svc.cluster.local" |
| 32 | aaiEnrichmentPort: |
| 33 | type: string |
| 34 | default: "8443" |
| 35 | enableAAIEnrichment: |
| 36 | type: string |
Vijay Venkatesh Kumar | b9d1f7a | 2020-03-02 23:36:13 +0000 | [diff] [blame] | 37 | default: "true" |
vagrant | ea1a3df | 2018-04-30 19:52:01 +0000 | [diff] [blame] | 38 | dmaap_host: |
| 39 | type: string |
Vijay Venkatesh Kumar | b9d1f7a | 2020-03-02 23:36:13 +0000 | [diff] [blame] | 40 | default: "message-router.onap.svc.cluster.local" |
vagrant | ea1a3df | 2018-04-30 19:52:01 +0000 | [diff] [blame] | 41 | dmaap_port: |
| 42 | type: string |
| 43 | default: "3904" |
| 44 | enableRedisCaching: |
| 45 | type: string |
Vijay Venkatesh Kumar | b9d1f7a | 2020-03-02 23:36:13 +0000 | [diff] [blame] | 46 | default: "false" |
vagrant | ea1a3df | 2018-04-30 19:52:01 +0000 | [diff] [blame] | 47 | redisHosts: |
| 48 | type: string |
Vijay Venkatesh Kumar | b9d1f7a | 2020-03-02 23:36:13 +0000 | [diff] [blame] | 49 | default: "dcae-redis.onap.svc.cluster.local:6379" |
vagrant | ea1a3df | 2018-04-30 19:52:01 +0000 | [diff] [blame] | 50 | tag_version: |
| 51 | type: string |
Jack Lucas | cb44718 | 2020-01-22 11:48:50 -0500 | [diff] [blame] | 52 | default: "nexus3.onap.org:10001/onap/org.onap.dcaegen2.deployments.tca-cdap-container:1.2.2" |
vagrant | ea1a3df | 2018-04-30 19:52:01 +0000 | [diff] [blame] | 53 | consul_host: |
| 54 | type: string |
Vijay Venkatesh Kumar | b9d1f7a | 2020-03-02 23:36:13 +0000 | [diff] [blame] | 55 | default: "consul-server.onap" |
vagrant | ea1a3df | 2018-04-30 19:52:01 +0000 | [diff] [blame] | 56 | consul_port: |
| 57 | type: string |
| 58 | default: "8500" |
| 59 | cbs_host: |
| 60 | type: string |
Vijay Venkatesh Kumar | 0710d1d | 2019-05-14 08:04:16 +0000 | [diff] [blame] | 61 | default: "config-binding-service" |
vagrant | ea1a3df | 2018-04-30 19:52:01 +0000 | [diff] [blame] | 62 | cbs_port: |
| 63 | type: string |
| 64 | default: "10000" |
| 65 | policy_id: |
| 66 | type: string |
Vijay Venkatesh Kumar | aa72417 | 2019-05-07 20:03:36 +0000 | [diff] [blame] | 67 | default: "onap.restart.tca" |
vagrant | ea1a3df | 2018-04-30 19:52:01 +0000 | [diff] [blame] | 68 | external_port: |
| 69 | type: string |
| 70 | description: Kubernetes node port on which CDAPgui is exposed |
Vijay Venkatesh Kumar | aa72417 | 2019-05-07 20:03:36 +0000 | [diff] [blame] | 71 | default: "32012" |
| 72 | policy_model_id: |
| 73 | type: string |
| 74 | default: "onap.policies.monitoring.cdap.tca.hi.lo.app" |
vagrant | ea1a3df | 2018-04-30 19:52:01 +0000 | [diff] [blame] | 75 | node_templates: |
| 76 | tca_k8s: |
| 77 | type: dcae.nodes.ContainerizedServiceComponent |
| 78 | relationships: |
| 79 | - target: tca_policy |
| 80 | type: cloudify.relationships.depends_on |
| 81 | properties: |
| 82 | service_component_type: 'dcaegen2-analytics-tca' |
| 83 | application_config: {} |
| 84 | docker_config: {} |
| 85 | image: |
| 86 | get_input: tag_version |
| 87 | log_info: |
| 88 | log_directory: "/opt/app/TCAnalytics/logs" |
| 89 | application_config: |
| 90 | app_config: |
| 91 | appDescription: DCAE Analytics Threshold Crossing Alert Application |
| 92 | appName: dcae-tca |
| 93 | tcaAlertsAbatementTableName: TCAAlertsAbatementTable |
| 94 | tcaAlertsAbatementTableTTLSeconds: '1728000' |
| 95 | tcaSubscriberOutputStreamName: TCASubscriberOutputStream |
| 96 | tcaVESAlertsTableName: TCAVESAlertsTable |
| 97 | tcaVESAlertsTableTTLSeconds: '1728000' |
| 98 | tcaVESMessageStatusTableName: TCAVESMessageStatusTable |
| 99 | tcaVESMessageStatusTableTTLSeconds: '86400' |
| 100 | thresholdCalculatorFlowletInstances: '2' |
| 101 | app_preferences: |
| 102 | aaiEnrichmentHost: |
| 103 | get_input: aaiEnrichmentHost |
| 104 | aaiEnrichmentIgnoreSSLCertificateErrors: 'true' |
| 105 | aaiEnrichmentPortNumber: '8443' |
| 106 | aaiEnrichmentProtocol: https |
Vijay Venkatesh Kumar | dded643 | 2018-10-26 01:14:38 +0000 | [diff] [blame] | 107 | aaiEnrichmentUserName: dcae@dcae.onap.org |
| 108 | aaiEnrichmentUserPassword: demo123456! |
vagrant | ea1a3df | 2018-04-30 19:52:01 +0000 | [diff] [blame] | 109 | aaiVMEnrichmentAPIPath: /aai/v11/search/nodes-query |
| 110 | aaiVNFEnrichmentAPIPath: /aai/v11/network/generic-vnfs/generic-vnf |
| 111 | enableAAIEnrichment: |
| 112 | get_input: enableAAIEnrichment |
| 113 | enableRedisCaching: |
| 114 | get_input: enableRedisCaching |
| 115 | redisHosts: |
| 116 | get_input: redisHosts |
| 117 | enableAlertCEFFormat: 'false' |
| 118 | publisherContentType: application/json |
| 119 | publisherHostName: |
| 120 | get_input: dmaap_host |
| 121 | publisherHostPort: |
| 122 | get_input: dmaap_port |
| 123 | publisherMaxBatchSize: '1' |
| 124 | publisherMaxRecoveryQueueSize: '100000' |
| 125 | publisherPollingInterval: '20000' |
| 126 | publisherProtocol: http |
| 127 | publisherTopicName: unauthenticated.DCAE_CL_OUTPUT |
Vijay Venkatesh Kumar | aa72417 | 2019-05-07 20:03:36 +0000 | [diff] [blame] | 128 | subscriberConsumerGroup: OpenDCAE-clamp |
vagrant | ea1a3df | 2018-04-30 19:52:01 +0000 | [diff] [blame] | 129 | subscriberConsumerId: c12 |
| 130 | subscriberContentType: application/json |
| 131 | subscriberHostName: |
| 132 | get_input: dmaap_host |
| 133 | subscriberHostPort: |
| 134 | get_input: dmaap_port |
| 135 | subscriberMessageLimit: '-1' |
| 136 | subscriberPollingInterval: '30000' |
| 137 | subscriberProtocol: http |
| 138 | subscriberTimeoutMS: '-1' |
Lusheng Ji | 42f9508 | 2018-05-11 11:16:27 -0400 | [diff] [blame] | 139 | subscriberTopicName: unauthenticated.VES_MEASUREMENT_OUTPUT |
Vijay Venkatesh Kumar | d8e7721 | 2019-05-17 10:24:30 +0000 | [diff] [blame] | 140 | #tca_policy: '{"domain":"measurementsForVfScaling","metricsPerEventName":[{"eventName":"vFirewallBroadcastPackets","controlLoopSchemaType":"VM","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.vNicPerformanceArray[*].receivedTotalPacketsDelta","thresholdValue":300,"direction":"LESS_OR_EQUAL","severity":"MAJOR","closedLoopEventStatus":"ONSET"},{"closedLoopControlName":"ControlLoop-vFirewall-d0a1dfc6-94f5-4fd4-a5b5-4630b438850a","version":"1.0.2","fieldPath":"$.event.measurementsForVfScalingFields.vNicPerformanceArray[*].receivedTotalPacketsDelta","thresholdValue":700,"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":"ControlLoop-vDNS-6f37f56d-a87d-4b85-b6a9-cc953cf779b3","version":"1.0.2","fieldPath":"$.event.measurementsForVfScalingFields.vNicPerformanceArray[*].receivedTotalPacketsDelta","thresholdValue":300,"direction":"GREATER_OR_EQUAL","severity":"CRITICAL","closedLoopEventStatus":"ONSET"}]},{"eventName":"Measurement_vGMUX","controlLoopSchemaType":"VNF","policyScope":"DCAE","policyName":"DCAE.Config_tca-hi-lo","policyVersion":"v0.0.1","thresholds":[{"closedLoopControlName":"ControlLoop-vCPE-48f0c2c3-a172-4192-9ae3-052274181b6e","version":"1.0.2","fieldPath":"$.event.measurementsForVfScalingFields.additionalMeasurements[*].arrayOfFields[0].value","thresholdValue":0,"direction":"EQUAL","severity":"MAJOR","closedLoopEventStatus":"ABATED"},{"closedLoopControlName":"ControlLoop-vCPE-48f0c2c3-a172-4192-9ae3-052274181b6e","version":"1.0.2","fieldPath":"$.event.measurementsForVfScalingFields.additionalMeasurements[*].arrayOfFields[0].value","thresholdValue":0,"direction":"GREATER","severity":"CRITICAL","closedLoopEventStatus":"ONSET"}]}]}' |
Vijay Venkatesh Kumar | 0710d1d | 2019-05-14 08:04:16 +0000 | [diff] [blame] | 141 | tca_policy: '' |
vagrant | ea1a3df | 2018-04-30 19:52:01 +0000 | [diff] [blame] | 142 | service_component_type: dcaegen2-analytics_tca |
| 143 | interfaces: |
| 144 | cloudify.interfaces.lifecycle: |
| 145 | start: |
| 146 | inputs: |
| 147 | envs: |
| 148 | DMAAPHOST: |
| 149 | { get_input: dmaap_host } |
Vijay Venkatesh Kumar | b9d1f7a | 2020-03-02 23:36:13 +0000 | [diff] [blame] | 150 | DMAAPPORT: "3904" |
vagrant | ea1a3df | 2018-04-30 19:52:01 +0000 | [diff] [blame] | 151 | DMAAPPUBTOPIC: "unauthenticated.DCAE_CL_OUTPUT" |
Lusheng Ji | 42f9508 | 2018-05-11 11:16:27 -0400 | [diff] [blame] | 152 | DMAAPSUBTOPIC: "unauthenticated.VES_MEASUREMENT_OUTPUT" |
vagrant | ea1a3df | 2018-04-30 19:52:01 +0000 | [diff] [blame] | 153 | AAIHOST: |
| 154 | { get_input: aaiEnrichmentHost } |
Vijay Venkatesh Kumar | b9d1f7a | 2020-03-02 23:36:13 +0000 | [diff] [blame] | 155 | AAIPORT: "8443" |
vagrant | ea1a3df | 2018-04-30 19:52:01 +0000 | [diff] [blame] | 156 | CONSUL_HOST: |
| 157 | { get_input: consul_host } |
Vijay Venkatesh Kumar | b9d1f7a | 2020-03-02 23:36:13 +0000 | [diff] [blame] | 158 | CONSUL_PORT: "8500" |
vagrant | ea1a3df | 2018-04-30 19:52:01 +0000 | [diff] [blame] | 159 | CBS_HOST: |
| 160 | { get_input: cbs_host } |
Vijay Venkatesh Kumar | b9d1f7a | 2020-03-02 23:36:13 +0000 | [diff] [blame] | 161 | CBS_PORT: "10000" |
vagrant | ea1a3df | 2018-04-30 19:52:01 +0000 | [diff] [blame] | 162 | CONFIG_BINDING_SERVICE: "config_binding_service" |
| 163 | ports: |
| 164 | - concat: ["11011:", { get_input: external_port }] |
| 165 | tca_policy: |
Vijay Venkatesh Kumar | aa72417 | 2019-05-07 20:03:36 +0000 | [diff] [blame] | 166 | type: clamp.nodes.policy |
vagrant | ea1a3df | 2018-04-30 19:52:01 +0000 | [diff] [blame] | 167 | properties: |
| 168 | policy_id: |
| 169 | get_input: policy_id |
Jack Lucas | b3eebb8 | 2020-01-10 13:24:50 -0500 | [diff] [blame] | 170 | policy_model_id: |
Vijay Venkatesh Kumar | aa72417 | 2019-05-07 20:03:36 +0000 | [diff] [blame] | 171 | get_input: policy_model_id |
Vijay Venkatesh Kumar | b9d1f7a | 2020-03-02 23:36:13 +0000 | [diff] [blame] | 172 | |