summaryrefslogtreecommitdiffstats
path: root/engine-d
diff options
context:
space:
mode:
authorGuangrong Fu <fu.guangrong@zte.com.cn>2022-08-17 16:18:25 +0800
committerGuangrong Fu <fu.guangrong@zte.com.cn>2022-08-17 17:03:23 +0800
commitb7f3d4425348905ad0e7ead67eb51c45048b48a4 (patch)
tree05e8c8d57954167e269eec66f03ecc30846dfc61 /engine-d
parent89b122983361d25d3208330c588b921c5804c5e9 (diff)
bugfix - added transactionID
Issue-ID: HOLMES-563 Signed-off-by: Guangrong Fu <fu.guangrong@zte.com.cn> Change-Id: Ibd87fb819ffb49a641b89d2597c220a2d898cf42
Diffstat (limited to 'engine-d')
-rw-r--r--engine-d/src/main/java/org/onap/holmes/engine/dmaap/SubscriberAction.java7
-rw-r--r--engine-d/src/main/resources/logback-spring.xml2
2 files changed, 2 insertions, 7 deletions
diff --git a/engine-d/src/main/java/org/onap/holmes/engine/dmaap/SubscriberAction.java b/engine-d/src/main/java/org/onap/holmes/engine/dmaap/SubscriberAction.java
index 21f5961..035b796 100644
--- a/engine-d/src/main/java/org/onap/holmes/engine/dmaap/SubscriberAction.java
+++ b/engine-d/src/main/java/org/onap/holmes/engine/dmaap/SubscriberAction.java
@@ -1,5 +1,5 @@
/*
- * Copyright 2017 - 2022 ZTE Corporation.
+ * Copyright 2017-2022 ZTE Corporation.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
@@ -17,10 +17,8 @@ package org.onap.holmes.engine.dmaap;
import jakarta.annotation.PreDestroy;
import lombok.extern.slf4j.Slf4j;
-import org.onap.holmes.common.database.DbDaoUtil;
import org.onap.holmes.dsa.dmaappolling.Subscriber;
import org.onap.holmes.engine.db.AlarmInfoDaoService;
-import org.onap.holmes.engine.db.jdbi.AlarmInfoDao;
import org.onap.holmes.engine.manager.DroolsEngine;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Component;
@@ -36,8 +34,6 @@ public class SubscriberAction {
@Autowired
private DroolsEngine droolsEngine;
@Autowired
- private DbDaoUtil daoUtil;
- @Autowired
private AlarmInfoDaoService alarmInfoDaoService;
private HashMap<String, DMaaPAlarmPolling> pollingTasks = new HashMap<>();
@@ -48,7 +44,6 @@ public class SubscriberAction {
if (pollingTasks.containsKey(topic)) {
removeSubscriber(subscriber);
}
- AlarmInfoDao alarmInfoDao = daoUtil.getJdbiDaoByOnDemand(AlarmInfoDao.class);
DMaaPAlarmPolling pollingTask = new DMaaPAlarmPolling(subscriber, droolsEngine, alarmInfoDaoService);
Thread thread = new Thread(pollingTask);
thread.start();
diff --git a/engine-d/src/main/resources/logback-spring.xml b/engine-d/src/main/resources/logback-spring.xml
index 197057e..eda9c6b 100644
--- a/engine-d/src/main/resources/logback-spring.xml
+++ b/engine-d/src/main/resources/logback-spring.xml
@@ -1,7 +1,7 @@
<?xml version="1.0" encoding="UTF-8"?>
<configuration debug="false">
<property name="LOG_HOME" value="/var/log/ONAP/holmes"/>
- <property name="LOG_PATTERN" value="%d{yyyy-MM-dd HH:mm:ss SSS} %-5p [%c][%t] - %msg%n" />
+ <property name="LOG_PATTERN" value="%d{yyyy-MM-dd HH:mm:ss SSS} %-5p [%c][%t][%X{RequestID}][%X{InvocationID}] - %m%n" />
<appender name="Console" class="ch.qos.logback.core.ConsoleAppender">
<encoder class="ch.qos.logback.classic.encoder.PatternLayoutEncoder">