From 2527848dfee4b1de282478ff8f3f0e3349656c6f Mon Sep 17 00:00:00 2001 From: Lars Johansson <lars.johansson@ess.eu> Date: Thu, 26 Oct 2023 11:38:37 +0200 Subject: [PATCH] Allow for configuration of log level and set to DEBUG for integration tests --- CONFIGURATION.md | 1 + docker-compose-integrationtest.yml | 1 + src/main/resources/application.properties | 2 +- src/test/resources/application.properties | 2 +- 4 files changed, 4 insertions(+), 2 deletions(-) diff --git a/CONFIGURATION.md b/CONFIGURATION.md index 55342da1..147b4a05 100644 --- a/CONFIGURATION.md +++ b/CONFIGURATION.md @@ -10,6 +10,7 @@ Environment variables | NAMING_DATABASE_URL | jdbc:postgresql://postgres:5432/discs_names | JDBC URL for the database connection | | NAMING_DATABASE_USERNAME | discs_names | user name for the database connection | | NAMING_DATABASE_PASSWORD | discs_names | password for the database connection | +| NAMING_LOGGING_LEVEL | INFO | log level for application | | NAMING_MAIL_ADMINISTRATOR | | comma-separated list of administrator email addresses | | NAMING_MAIL_NOTIFICATION | false | true/false if mail notications are to be sent | | NAMING_SMTP_HOST | mail.esss.lu.se | DNS name of server that accepts connections for SMTP | diff --git a/docker-compose-integrationtest.yml b/docker-compose-integrationtest.yml index dfc80170..960db403 100644 --- a/docker-compose-integrationtest.yml +++ b/docker-compose-integrationtest.yml @@ -13,6 +13,7 @@ services: ports: - "8080:8080" environment: + NAMING_LOGGING_LEVEL: DEBUG skipITCoverage: "true" depends_on: postgres: diff --git a/src/main/resources/application.properties b/src/main/resources/application.properties index 7e8ed0c3..d7935563 100644 --- a/src/main/resources/application.properties +++ b/src/main/resources/application.properties @@ -7,7 +7,7 @@ naming.backend.swagger.url=${NAMING_BACKEND_SWAGGER_URL:http://localhost:8080/sw # logging naming.logging.stacktrace.length=10 -logging.level.org.openepics.names=INFO +logging.level.org.openepics.names=${NAMING_LOGGING_LEVEL:INFO} logging.level.org.springframework.web=INFO spring.http.log-request-details=true diff --git a/src/test/resources/application.properties b/src/test/resources/application.properties index e2b0a094..6cddcfd9 100644 --- a/src/test/resources/application.properties +++ b/src/test/resources/application.properties @@ -7,7 +7,7 @@ naming.backend.swagger.url=${NAMING_BACKEND_SWAGGER_URL:http://localhost:8080/sw # logging naming.logging.stacktrace.length=10 -logging.level.org.openepics.names=INFO +logging.level.org.openepics.names=${NAMING_LOGGING_LEVEL:INFO} logging.level.org.springframework.web=INFO spring.http.log-request-details=true -- GitLab