From c6abadb957b5d37f9206ce164eb5b99651655f5a Mon Sep 17 00:00:00 2001 From: Dasar Date: Tue, 16 Apr 2024 16:16:08 +0530 Subject: Remove DMaaP references from AAI-Traversal - Replace DMaaP related configuration with kafka - Update AAI-Common version from 1.13.3 to 1.13.6 in pom.xml Issue-ID: AAI-3820 Change-Id: Ia989fcd65c61ef6abb6e2423a2d391140386589d Signed-off-by: Dasar --- .../src/main/java/org/onap/aai/TraversalApp.java | 3 +- .../src/main/resources/application.properties | 10 ++++++- aai-traversal/src/main/resources/logback.xml | 34 +++++++++++----------- .../src/test/resources/application-test.properties | 2 +- aai-traversal/src/test/resources/logback.xml | 34 +++++++++++----------- 5 files changed, 46 insertions(+), 37 deletions(-) (limited to 'aai-traversal') diff --git a/aai-traversal/src/main/java/org/onap/aai/TraversalApp.java b/aai-traversal/src/main/java/org/onap/aai/TraversalApp.java index 14bfca0..b382a16 100644 --- a/aai-traversal/src/main/java/org/onap/aai/TraversalApp.java +++ b/aai-traversal/src/main/java/org/onap/aai/TraversalApp.java @@ -46,10 +46,11 @@ import org.springframework.boot.autoconfigure.orm.jpa.HibernateJpaAutoConfigurat import org.springframework.context.annotation.ComponentScan; import org.springframework.core.env.Environment; import org.springframework.core.env.Profiles; +import org.springframework.boot.autoconfigure.jms.JmsAutoConfiguration; @SpringBootApplication( exclude = {DataSourceAutoConfiguration.class, - DataSourceTransactionManagerAutoConfiguration.class, HibernateJpaAutoConfiguration.class}) + DataSourceTransactionManagerAutoConfiguration.class, HibernateJpaAutoConfiguration.class, JmsAutoConfiguration.class}) // Component Scan provides a way to look for spring beans // It only searches beans in the following packages // Any method annotated with @Bean annotation or any class diff --git a/aai-traversal/src/main/resources/application.properties b/aai-traversal/src/main/resources/application.properties index e624e96..02e488b 100644 --- a/aai-traversal/src/main/resources/application.properties +++ b/aai-traversal/src/main/resources/application.properties @@ -71,7 +71,15 @@ schema.source.name=onap # JMS bind address host port jms.bind.address=tcp://localhost:61646 -dmaap.ribbon.listOfServers=localhost:3904 +# dmaap is deprecated and now replaced with kafka +# dmaap.ribbon.listOfServers=localhost:3904 +spring.kafka.producer.bootstrap-servers=${BOOTSTRAP_SERVERS} +spring.kafka.producer.properties.security.protocol=SASL_PLAINTEXT +spring.kafka.producer.properties.sasl.mechanism=SCRAM-SHA-512 +spring.kafka.producer.key-serializer=org.apache.kafka.common.serialization.StringSerializer +spring.kafka.producer.value-serializer=org.apache.kafka.common.serialization.StringSerializer +spring.kafka.producer.properties.sasl.jaas.config = ${JAAS_CONFIG} +spring.kafka.producer.retries=3 # Schema related attributes for the oxm and edges # Any additional schema related attributes should start with prefix schema diff --git a/aai-traversal/src/main/resources/logback.xml b/aai-traversal/src/main/resources/logback.xml index 9c0cf90..fee8005 100644 --- a/aai-traversal/src/main/resources/logback.xml +++ b/aai-traversal/src/main/resources/logback.xml @@ -220,14 +220,14 @@ - WARN - ${logDirectory}/dmaapAAIEventConsumer/error.log + ${logDirectory}/kafkaAAIEventConsumer/error.log - ${logDirectory}/dmaapAAIEventConsumer/error.log.%d{yyyy-MM-dd} + ${logDirectory}/kafkaAAIEventConsumer/error.log.%d{yyyy-MM-dd} ${maxHistory} ${totalSizeCap} @@ -238,16 +238,16 @@ - DEBUG ACCEPT DENY - ${logDirectory}/dmaapAAIEventConsumer/debug.log + ${logDirectory}/kafkaAAIEventConsumer/debug.log - ${logDirectory}/dmaapAAIEventConsumer/debug.log.%d{yyyy-MM-dd} + ${logDirectory}/kafkaAAIEventConsumer/debug.log.%d{yyyy-MM-dd} ${maxHistory} ${totalSizeCap} @@ -256,16 +256,16 @@ ${debugPattern} - INFO ACCEPT DENY - ${logDirectory}/dmaapAAIEventConsumer/dmaap-transaction.log + ${logDirectory}/kafkaAAIEventConsumer/kafka-transaction.log - ${logDirectory}/dmaapAAIEventConsumer/dmaap-transaction.log.%d{yyyy-MM-dd} + ${logDirectory}/kafkaAAIEventConsumer/kafka-transaction.log.%d{yyyy-MM-dd} ${maxHistory} ${totalSizeCap} @@ -274,16 +274,16 @@ ${auditPattern} - INFO ACCEPT DENY - ${logDirectory}/dmaapAAIEventConsumer/metrics.log + ${logDirectory}/kafkaAAIEventConsumer/metrics.log - ${logDirectory}/dmaapAAIEventConsumer/metrics.log.%d{yyyy-MM-dd} + ${logDirectory}/kafkaAAIEventConsumer/metrics.log.%d{yyyy-MM-dd} ${maxHistory} ${totalSizeCap} @@ -372,7 +372,7 @@ - + @@ -387,14 +387,14 @@ - - - + + + - + diff --git a/aai-traversal/src/test/resources/application-test.properties b/aai-traversal/src/test/resources/application-test.properties index 00720c8..79281a6 100644 --- a/aai-traversal/src/test/resources/application-test.properties +++ b/aai-traversal/src/test/resources/application-test.properties @@ -49,7 +49,7 @@ server.ssl.enabled=false # JMS bind address host port jms.bind.address=tcp://localhost:61646 -dmaap.ribbon.listOfServers=localhost:3904 +# dmaap.ribbon.listOfServers=localhost:3904 # Schema related attributes for the oxm and edges # Any additional schema related attributes should start with prefix schema diff --git a/aai-traversal/src/test/resources/logback.xml b/aai-traversal/src/test/resources/logback.xml index fc275dd..ac8d4be 100644 --- a/aai-traversal/src/test/resources/logback.xml +++ b/aai-traversal/src/test/resources/logback.xml @@ -181,14 +181,14 @@ - WARN - ${logDirectory}/dmaapAAIEventConsumer/error.log + ${logDirectory}/kafkaAAIEventConsumer/error.log - ${logDirectory}/dmaapAAIEventConsumer/error.log.%d{yyyy-MM-dd} + ${logDirectory}/kafkaAAIEventConsumer/error.log.%d{yyyy-MM-dd} @@ -197,48 +197,48 @@ - DEBUG ACCEPT DENY - ${logDirectory}/dmaapAAIEventConsumer/debug.log + ${logDirectory}/kafkaAAIEventConsumer/debug.log - ${logDirectory}/dmaapAAIEventConsumer/debug.log.%d{yyyy-MM-dd} + ${logDirectory}/kafkaAAIEventConsumer/debug.log.%d{yyyy-MM-dd} ${debugPattern} - INFO ACCEPT DENY - ${logDirectory}/dmaapAAIEventConsumer/dmaap-transaction.log + ${logDirectory}/kafkaAAIEventConsumer/kafka-transaction.log - ${logDirectory}/dmaapAAIEventConsumer/dmaap-transaction.log.%d{yyyy-MM-dd} + ${logDirectory}/kafkaAAIEventConsumer/kafka-transaction.log.%d{yyyy-MM-dd} ${auditPattern} - INFO ACCEPT DENY - ${logDirectory}/dmaapAAIEventConsumer/metrics.log + ${logDirectory}/kafkaAAIEventConsumer/metrics.log - ${logDirectory}/dmaapAAIEventConsumer/metrics.log.%d{yyyy-MM-dd} + ${logDirectory}/kafkaAAIEventConsumer/metrics.log.%d{yyyy-MM-dd} @@ -320,7 +320,7 @@ - + @@ -329,13 +329,13 @@ - - - + + + - + -- cgit 1.2.3-korg