summaryrefslogtreecommitdiffstats
path: root/rulemgt/src
diff options
context:
space:
mode:
authorYiLi <li.yi101@zte.com.cn>2018-03-16 10:21:23 +0800
committerYiLi <li.yi101@zte.com.cn>2018-03-16 10:21:23 +0800
commitc88c32f8d11daac84dd5573a9c24bbfad8ee9418 (patch)
tree12dda1dea031256f39ae864e9f5bd5ea454097d4 /rulemgt/src
parent18aceb1795fc25fbe770b6d6bb6bbe68d4bf70fc (diff)
add init log filter and modify rulemgt.yml
Change-Id: Ia895ffd658164993d0532efb0e51eb0c4c56377e Issue-ID: HOLMES-112 Signed-off-by: YiLi <li.yi101@zte.com.cn>
Diffstat (limited to 'rulemgt/src')
-rw-r--r--rulemgt/src/main/java/org/onap/holmes/rulemgt/RuleActiveApp.java5
1 files changed, 5 insertions, 0 deletions
diff --git a/rulemgt/src/main/java/org/onap/holmes/rulemgt/RuleActiveApp.java b/rulemgt/src/main/java/org/onap/holmes/rulemgt/RuleActiveApp.java
index e7f30a7..5f96912 100644
--- a/rulemgt/src/main/java/org/onap/holmes/rulemgt/RuleActiveApp.java
+++ b/rulemgt/src/main/java/org/onap/holmes/rulemgt/RuleActiveApp.java
@@ -17,16 +17,19 @@
package org.onap.holmes.rulemgt;
import io.dropwizard.setup.Environment;
+import java.util.EnumSet;
import java.util.HashSet;
import java.util.Set;
import java.util.concurrent.Executors;
import java.util.concurrent.ScheduledExecutorService;
import java.util.concurrent.TimeUnit;
+import javax.servlet.DispatcherType;
import lombok.extern.slf4j.Slf4j;
import org.onap.holmes.common.config.MicroServiceConfig;
import org.onap.holmes.common.dropwizard.ioc.bundle.IOCApplication;
import org.onap.holmes.common.exception.CorrelationException;
import org.onap.holmes.common.utils.MSBRegisterUtil;
+import org.onap.holmes.common.utils.transactionid.TransactionIdFilter;
import org.onap.holmes.rulemgt.dcae.DcaeConfigurationPolling;
import org.onap.holmes.rulemgt.resources.RuleMgtResources;
import org.onap.msb.sdk.discovery.entity.MicroServiceInfo;
@@ -59,6 +62,8 @@ public class RuleActiveApp extends IOCApplication<RuleAppConfig> {
service.scheduleAtFixedRate(
new DcaeConfigurationPolling(MicroServiceConfig.getEnv(MicroServiceConfig.HOSTNAME)), 0,
DcaeConfigurationPolling.POLLING_PERIOD, TimeUnit.MILLISECONDS);
+ environment.servlets().addFilter("customFilter",new TransactionIdFilter()).addMappingForUrlPatterns(EnumSet
+ .allOf(DispatcherType.class),true,"/*");
}
private MicroServiceInfo createMicroServiceInfo() {