Merge "[UUI] New Solve 2 components in one Docker"
[oom.git] / kubernetes / policy / components / policy-pap / resources / config / papParameters.yaml
index 195b087..b68e8d6 100644 (file)
@@ -1,5 +1,6 @@
 #  ============LICENSE_START=======================================================
 #   Copyright (C) 2022 Bell Canada. All rights reserved.
+#   Modifications Copyright © 2022 Nordix Foundation
 #  ================================================================================
 #  Licensed under the Apache License, Version 2.0 (the "License");
 #  you may not use this file except in compliance with the License.
@@ -40,25 +41,23 @@ spring:
       naming:
         physical-strategy: org.hibernate.boot.model.naming.PhysicalNamingStrategyStandardImpl
         implicit-strategy: org.onap.policy.common.spring.utils.CustomImplicitNamingStrategy
-{{- if .Values.config.useStrimziKafka }}
   kafka:
+    consumer:
+      group-id: {{ .Values.config.kafka.consumer.groupId }}
+{{- if .Values.config.useStrimziKafka }}
     bootstrap-servers: {{ include "common.release" . }}-{{ .Values.config.kafkaBootstrap }}:9092
     security.protocol: SASL_PLAINTEXT
     properties.sasl:
       mechanism: SCRAM-SHA-512
       jaas.config: ${JAASLOGIN}
 {{ else }}
-{{ toYaml .Values.config.eventPublisher | nindent 2 }}
-{{- end }}
-
-{{- if .Values.config.additional }}
-{{ toYaml .Values.config.additional | nindent 2 }}
+{{ toYaml .Values.config.eventConsumption | nindent 2 }}
 {{- end }}
 
 server:
   port: 6969
   ssl:
-    enabled: true
+    enabled: {{ (eq "true" (include "common.needTLS" .)) | ternary true false }}
 
 pap:
   name: PapGroup
@@ -77,7 +76,7 @@ pap:
     - topic: POLICY-PDP-PAP
       servers:
       - message-router
-      useHttps: true
+      useHttps: {{ (eq "true" (include "common.needTLS" .)) | ternary true false }}
       fetchTimeout: 15000
       topicCommInfrastructure: dmaap
     - topic: POLICY-HEARTBEAT
@@ -85,39 +84,48 @@ pap:
       consumerGroup: policy-pap
       servers:
       - message-router
-      useHttps: true
+      useHttps: {{ (eq "true" (include "common.needTLS" .)) | ternary true false }}
       fetchTimeout: 15000
       topicCommInfrastructure: dmaap
     topicSinks:
     - topic: POLICY-PDP-PAP
       servers:
       - message-router
-      useHttps: true
+      useHttps: {{ (eq "true" (include "common.needTLS" .)) | ternary true false }}
       topicCommInfrastructure: dmaap
     - topic: POLICY-NOTIFICATION
       servers:
       - message-router
-      useHttps: true
+      useHttps: {{ (eq "true" (include "common.needTLS" .)) | ternary true false }}
       topicCommInfrastructure: dmaap
+# If Strimzi Kafka to be used for communication, replace following configuration for topicSources and topicSinks
+#          servers:
+#            - {{ include "common.release" . }}-{{ .Values.config.kafkaBootstrap }}:9092
+#          topicCommInfrastructure: kafka
+#          additionalProps:
+#            security.protocol: SASL_PLAINTEXT
+#            sasl.mechanism: SCRAM-SHA-512
+#            sasl.jaas.config: ${JAASLOGIN}
+
   healthCheckRestClientParameters:
   - clientName: api
     hostname: policy-api
     port: 6969
     userName: "${API_USER}"
     password: "${API_PASSWORD}"
-    useHttps: true
+    useHttps: {{ (eq "true" (include "common.needTLS" .)) | ternary true false }}
     basePath: policy/api/v1/healthcheck
   - clientName: distribution
     hostname: policy-distribution
     port: 6969
     userName: "${DISTRIBUTION_USER}"
     password: "${DISTRIBUTION_PASSWORD}"
-    useHttps: true
+    useHttps: {{ (eq "true" (include "common.needTLS" .)) | ternary true false }}
     basePath: healthcheck
   - clientName: dmaap
     hostname: message-router
-    port: 3905
-    useHttps: true
+    port: {{ (eq "true" (include "common.needTLS" .)) | ternary 3905 3904 }}
+    useHttps: {{ (eq "true" (include "common.needTLS" .)) | ternary true false }}
     basePath: topics
 
 management: