summaryrefslogtreecommitdiffstats
path: root/feature-legacy-config/src/main
diff options
context:
space:
mode:
Diffstat (limited to 'feature-legacy-config/src/main')
-rw-r--r--feature-legacy-config/src/main/feature/config/feature-legacy-config.properties33
-rw-r--r--feature-legacy-config/src/main/java/org/onap/policy/drools/legacy/config/LegacyConfig.java6
2 files changed, 14 insertions, 25 deletions
diff --git a/feature-legacy-config/src/main/feature/config/feature-legacy-config.properties b/feature-legacy-config/src/main/feature/config/feature-legacy-config.properties
index 15a35b8b..47a4e229 100644
--- a/feature-legacy-config/src/main/feature/config/feature-legacy-config.properties
+++ b/feature-legacy-config/src/main/feature/config/feature-legacy-config.properties
@@ -2,6 +2,7 @@
# ONAP
# ================================================================================
# Copyright (C) 2021 AT&T Intellectual Property. All rights reserved.
+# Modifications Copyright (C) 2024 Nordix Foundation.
# ================================================================================
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
@@ -16,25 +17,13 @@
# limitations under the License.
# ============LICENSE_END=========================================================
-dmaap.source.topics=PDPD-CONFIGURATION
-
-dmaap.source.topics.PDPD-CONFIGURATION.servers=${envd:DMAAP_SERVERS}
-dmaap.source.topics.PDPD-CONFIGURATION.effectiveTopic=${envd:PDPD_CONFIGURATION_TOPIC}
-dmaap.source.topics.PDPD-CONFIGURATION.apiKey=${envd:PDPD_CONFIGURATION_API_KEY}
-dmaap.source.topics.PDPD-CONFIGURATION.apiSecret=${envd:PDPD_CONFIGURATION_API_SECRET}
-dmaap.source.topics.PDPD-CONFIGURATION.consumerGroup=${envd:PDPD_CONFIGURATION_CONSUMER_GROUP}
-dmaap.source.topics.PDPD-CONFIGURATION.consumerInstance=${envd:PDPD_CONFIGURATION_CONSUMER_INSTANCE}
-dmaap.source.topics.PDPD-CONFIGURATION.managed=false
-dmaap.source.topics.PDPD-CONFIGURATION.https=${envd:DMAAP_HTTPS:true}
-
-#Replace the properties with the following to use kafka message broker
-#kafka.source.topics=pdpd-configuration
-#kafka.source.topics.fetchTimeout=15000
-#kafka.source.topics.pdpd-configuration.servers=${envd:DMAAP_SERVERS}
-#kafka.source.topics.pdpd-configuration.effectiveTopic=${envd:PDPD_CONFIGURATION_TOPIC}
-#kafka.source.topics.pdpd-configuration.apiKey=${envd:PDPD_CONFIGURATION_API_KEY}
-#kafka.source.topics.pdpd-configuration.apiSecret=${envd:PDPD_CONFIGURATION_API_SECRET}
-#kafka.source.topics.pdpd-configuration.consumerGroup=${envd:PDPD_CONFIGURATION_CONSUMER_GROUP}
-#kafka.source.topics.pdpd-configuration.consumerInstance=${envd:PDPD_CONFIGURATION_CONSUMER_INSTANCE}
-#kafka.source.topics.pdpd-configuration.managed=false
-#kafka.source.topics.pdpd-configuration.https=${envd:DMAAP_HTTPS:true}
+kafka.source.topics=pdpd-configuration
+kafka.source.topics.fetchTimeout=15000
+kafka.source.topics.pdpd-configuration.servers=${envd:KAFKA_SERVERS}
+kafka.source.topics.pdpd-configuration.effectiveTopic=${envd:PDPD_CONFIGURATION_TOPIC}
+kafka.source.topics.pdpd-configuration.apiKey=${envd:PDPD_CONFIGURATION_API_KEY}
+kafka.source.topics.pdpd-configuration.apiSecret=${envd:PDPD_CONFIGURATION_API_SECRET}
+kafka.source.topics.pdpd-configuration.consumerGroup=${envd:PDPD_CONFIGURATION_CONSUMER_GROUP}
+kafka.source.topics.pdpd-configuration.consumerInstance=${envd:PDPD_CONFIGURATION_CONSUMER_INSTANCE}
+kafka.source.topics.pdpd-configuration.managed=false
+kafka.source.topics.pdpd-configuration.https=${envd:KAFKA_HTTPS:true}
diff --git a/feature-legacy-config/src/main/java/org/onap/policy/drools/legacy/config/LegacyConfig.java b/feature-legacy-config/src/main/java/org/onap/policy/drools/legacy/config/LegacyConfig.java
index 01cc3b34..7ca4632c 100644
--- a/feature-legacy-config/src/main/java/org/onap/policy/drools/legacy/config/LegacyConfig.java
+++ b/feature-legacy-config/src/main/java/org/onap/policy/drools/legacy/config/LegacyConfig.java
@@ -3,6 +3,7 @@
* ONAP
* ================================================================================
* Copyright (C) 2021 AT&T Intellectual Property. All rights reserved.
+ * Modifications Copyright (C) 2024 Nordix Foundation.
* ================================================================================
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
@@ -36,16 +37,15 @@ import org.slf4j.LoggerFactory;
/**
* Legacy Configurator.
*/
+@Getter
public class LegacyConfig implements Startable, TopicListener {
private static final Logger logger = LoggerFactory.getLogger(LegacyConfig.class);
private static final String CONFIGURATION_PROPERTIES_NAME = "feature-legacy-config";
- @Getter
private final Properties properties;
- @Getter
- private TopicSource source;
+ private final TopicSource source;
/**
* Constructor.