aboutsummaryrefslogtreecommitdiffstats
path: root/docs/development/devtools/smoke/files
diff options
context:
space:
mode:
authorFrancescoFioraEst <francesco.fiora@est.tech>2024-05-09 16:53:01 +0100
committerFrancesco Fiora <francesco.fiora@est.tech>2024-05-13 10:43:46 +0000
commit4c1415e7b9f1a9fbf4ee10e50b0a5c82bfacca4e (patch)
treee5a3b568fe367e66ee9f8c0230a4aeeeabfbe4d0 /docs/development/devtools/smoke/files
parentb003f61033296b3c385d1b6fa033c0061588f9df (diff)
Update docs for CLAMP Policy Participant Smoke Tests
Issue-ID: POLICY-4994 Change-Id: I5aa91130556bbc35d55aefa11ac39c1bd996b01e Signed-off-by: FrancescoFioraEst <francesco.fiora@est.tech>
Diffstat (limited to 'docs/development/devtools/smoke/files')
-rw-r--r--docs/development/devtools/smoke/files/api-application.yaml23
-rw-r--r--docs/development/devtools/smoke/files/docker-compose-policy.yaml61
-rw-r--r--docs/development/devtools/smoke/files/pap-application.yaml91
-rw-r--r--docs/development/devtools/smoke/files/participant-policy-application.yaml41
4 files changed, 216 insertions, 0 deletions
diff --git a/docs/development/devtools/smoke/files/api-application.yaml b/docs/development/devtools/smoke/files/api-application.yaml
new file mode 100644
index 00000000..39f1de5d
--- /dev/null
+++ b/docs/development/devtools/smoke/files/api-application.yaml
@@ -0,0 +1,23 @@
+spring:
+ profiles:
+ active: default
+ security.user:
+ name: policyadmin
+ password: zb!XztG34
+ mvc.converters.preferred-json-mapper: gson
+ datasource:
+ url: jdbc:mariadb://localhost:3306/policyadmin
+ driverClassName: org.mariadb.jdbc.Driver
+ username: policy_user
+ password: policy_user
+ jpa:
+ hibernate:
+ ddl-auto: none
+ naming:
+ physical-strategy: org.hibernate.boot.model.naming.PhysicalNamingStrategyStandardImpl
+ implicit-strategy: org.onap.policy.common.spring.utils.CustomImplicitNamingStrategy
+
+server:
+ port: 6968
+ servlet:
+ context-path: /policy/api/v1
diff --git a/docs/development/devtools/smoke/files/docker-compose-policy.yaml b/docs/development/devtools/smoke/files/docker-compose-policy.yaml
new file mode 100644
index 00000000..cdb50ebb
--- /dev/null
+++ b/docs/development/devtools/smoke/files/docker-compose-policy.yaml
@@ -0,0 +1,61 @@
+services:
+ mariadb:
+ image: mariadb:10.10.2
+ command: ['mysqld', '--lower_case_table_names=1']
+ volumes:
+ - type: bind
+ source: ./mariadb.sql
+ target: /docker-entrypoint-initdb.d/data.sql
+ environment:
+ - MYSQL_ROOT_PASSWORD=my-secret-pw
+ ports:
+ - "3306:3306"
+
+ policy-db-migrator:
+ image: nexus3.onap.org:10001/onap/policy-db-migrator:3.1.3-SNAPSHOT
+ container_name: policy-db-migrator
+ hostname: policy-db-migrator
+ depends_on:
+ - mariadb
+ expose:
+ - 6824
+ environment:
+ SQL_DB: policyadmin
+ SQL_HOST: mariadb
+ MYSQL_ROOT_PASSWORD: my-secret-pw
+ MYSQL_USER: policy_user
+ MYSQL_PASSWORD: policy_user
+ MYSQL_CMD: mysql
+ volumes:
+ - ./init.sh:/opt/app/policy/bin/db_migrator_policy_init.sh:ro
+ - ./wait_for_port.sh:/opt/app/policy/bin/wait_for_port.sh:ro
+ entrypoint: /opt/app/policy/bin/wait_for_port.sh
+ command: [
+ '-c',
+ '/opt/app/policy/bin/db_migrator_policy_init.sh',
+ 'mariadb', '3306'
+ ]
+
+ zookeeper:
+ image: confluentinc/cp-zookeeper:latest
+ environment:
+ ZOOKEEPER_CLIENT_PORT: 2181
+ ZOOKEEPER_TICK_TIME: 2000
+ ports:
+ - 2181:2181
+
+ kafka:
+ image: confluentinc/cp-kafka:latest
+ container_name: kafka
+ depends_on:
+ - zookeeper
+ ports:
+ - 29092:29092
+ - 9092:9092
+ environment:
+ KAFKA_BROKER_ID: 1
+ KAFKA_ZOOKEEPER_CONNECT: zookeeper:2181
+ KAFKA_ADVERTISED_LISTENERS: PLAINTEXT://kafka:9092,PLAINTEXT_HOST://localhost:29092
+ KAFKA_LISTENER_SECURITY_PROTOCOL_MAP: PLAINTEXT:PLAINTEXT,PLAINTEXT_HOST:PLAINTEXT
+ KAFKA_INTER_BROKER_LISTENER_NAME: PLAINTEXT
+ KAFKA_OFFSETS_TOPIC_REPLICATION_FACTOR: 1
diff --git a/docs/development/devtools/smoke/files/pap-application.yaml b/docs/development/devtools/smoke/files/pap-application.yaml
new file mode 100644
index 00000000..8a03b1dd
--- /dev/null
+++ b/docs/development/devtools/smoke/files/pap-application.yaml
@@ -0,0 +1,91 @@
+spring:
+ security:
+ user:
+ name: policyadmin
+ password: zb!XztG34
+ datasource:
+ url: jdbc:mariadb://localhost:3306/policyadmin
+ driverClassName: org.mariadb.jdbc.Driver
+ username: policy_user
+ password: policy_user
+ jpa:
+ hibernate:
+ ddl-auto: none
+ naming:
+ physical-strategy: org.hibernate.boot.model.naming.PhysicalNamingStrategyStandardImpl
+ implicit-strategy: org.onap.policy.common.spring.utils.CustomImplicitNamingStrategy
+ mvc:
+ converters:
+ preferred-json-mapper: gson
+
+server:
+ port: 6970
+ servlet:
+ context-path: /policy/pap/v1
+pap:
+ name: PapGroup
+ topic:
+ pdp-pap.name: POLICY-PDP-PAP
+ notification.name: POLICY-NOTIFICATION
+ heartbeat.name: POLICY-HEARTBEAT
+ pdpParameters:
+ heartBeatMs: 120000
+ updateParameters:
+ maxRetryCount: 1
+ maxWaitMs: 30000
+ stateChangeParameters:
+ maxRetryCount: 1
+ maxWaitMs: 30000
+ topicParameterGroup:
+ topicSources:
+ - topic: ${pap.topic.pdp-pap.name}
+ servers:
+ - kafka
+ topicCommInfrastructure: NOOP
+ fetchTimeout: 15000
+ - topic: ${pap.topic.heartbeat.name}
+ effectiveTopic: ${pap.topic.pdp-pap.name}
+ consumerGroup: policy-pap
+ servers:
+ - kafka
+ topicCommInfrastructure: NOOP
+ fetchTimeout: 15000
+ topicSinks:
+ - topic: ${pap.topic.pdp-pap.name}
+ servers:
+ - kafka
+ topicCommInfrastructure: NOOP
+ - topic: ${pap.topic.notification.name}
+ servers:
+ - kafka
+ topicCommInfrastructure: NOOP
+ healthCheckRestClientParameters:
+ - clientName: api
+ hostname: localhost
+ port: 6968
+ userName: policyadmin
+ password: zb!XztG34
+ useHttps: false
+ basePath: policy/api/v1/healthcheck
+ - clientName: distribution
+ hostname: policy-distribution
+ port: 6969
+ userName: healthcheck
+ password: zb!XztG34
+ useHttps: true
+ basePath: healthcheck
+ - clientName: kafka
+ hostname: kafka
+ port: 3905
+ useHttps: true
+ basePath: topics
+
+management:
+ endpoints:
+ web:
+ base-path: /
+ exposure:
+ include: health, metrics, prometheus
+ path-mapping:
+ -metrics: plain-metrics
+ -prometheus: metrics
diff --git a/docs/development/devtools/smoke/files/participant-policy-application.yaml b/docs/development/devtools/smoke/files/participant-policy-application.yaml
new file mode 100644
index 00000000..5b87d1b3
--- /dev/null
+++ b/docs/development/devtools/smoke/files/participant-policy-application.yaml
@@ -0,0 +1,41 @@
+participant:
+ pdpGroup: defaultGroup
+ pdpType: apex
+ policyApiParameters:
+ clientName: api
+ hostname: localhost
+ port: 6968
+ userName: policyadmin
+ password: zb!XztG34
+ useHttps: false
+ allowSelfSignedCerts: false
+ policyPapParameters:
+ clientName: pap
+ hostname: localhost
+ port: 6970
+ userName: policyadmin
+ password: zb!XztG34
+ useHttps: false
+ allowSelfSignedCerts: false
+ intermediaryParameters:
+ reportingTimeIntervalMs: 120000
+ description: Participant Description
+ participantId: 101c62b3-8918-41b9-a747-d21eb79c6c03
+ clampAutomationCompositionTopics:
+ topicSources:
+ -
+ topic: policy-acruntime-participant
+ servers:
+ - ${topicServer:localhost:29092}
+ topicCommInfrastructure: kafka
+ fetchTimeout: 15000
+ topicSinks:
+ -
+ topic: policy-acruntime-participant
+ servers:
+ - ${topicServer:localhost:29092}
+ topicCommInfrastructure: kafka
+ participantSupportedElementTypes:
+ -
+ typeName: org.onap.policy.clamp.acm.PolicyAutomationCompositionElement
+ typeVersion: 1.0.0