From 82075a4476c16e1ab3806d914e571e0cf48bebc0 Mon Sep 17 00:00:00 2001 From: Wenjun Ruan Date: Thu, 23 Dec 2021 09:26:42 +0800 Subject: [PATCH] Fix database lose data in standalone (#7556) --- .../dolphinscheduler/api/aspect/AccessLogAnnotation.java | 2 +- .../src/main/resources/application.yaml | 5 ++++- 2 files changed, 5 insertions(+), 2 deletions(-) diff --git a/dolphinscheduler-api/src/main/java/org/apache/dolphinscheduler/api/aspect/AccessLogAnnotation.java b/dolphinscheduler-api/src/main/java/org/apache/dolphinscheduler/api/aspect/AccessLogAnnotation.java index a7bee62a7e..db62bcda3a 100644 --- a/dolphinscheduler-api/src/main/java/org/apache/dolphinscheduler/api/aspect/AccessLogAnnotation.java +++ b/dolphinscheduler-api/src/main/java/org/apache/dolphinscheduler/api/aspect/AccessLogAnnotation.java @@ -28,7 +28,7 @@ import java.lang.annotation.Target; @Documented public @interface AccessLogAnnotation { // ignore request args - String[] ignoreRequestArgs() default {}; + String[] ignoreRequestArgs() default {"loginUser"}; boolean ignoreRequest() default false; diff --git a/dolphinscheduler-standalone-server/src/main/resources/application.yaml b/dolphinscheduler-standalone-server/src/main/resources/application.yaml index bd98cd280e..7f5db4f14e 100644 --- a/dolphinscheduler-standalone-server/src/main/resources/application.yaml +++ b/dolphinscheduler-standalone-server/src/main/resources/application.yaml @@ -31,9 +31,12 @@ spring: - taskDefinition caffeine: spec: maximumSize=100,expireAfterWrite=300s,recordStats + sql: + init: + schema-locations: classpath:sql/dolphinscheduler_h2.sql datasource: driver-class-name: org.h2.Driver - url: jdbc:h2:mem:dolphinscheduler;MODE=MySQL;DB_CLOSE_DELAY=-1;DATABASE_TO_LOWER=true;INIT=runscript from 'classpath:sql/dolphinscheduler_h2.sql' + url: jdbc:h2:mem:dolphinscheduler;MODE=MySQL;DB_CLOSE_DELAY=-1;DATABASE_TO_LOWER=true username: sa password: "" hikari: