Changing the Log Level in a Spring Boot Application During Development

Permanently switching the log level of a Spring Boot Application during development can be achieved with a dev profile only section in a application-dev configuration file. The following snippet changes the log level for the package de.datenkollektiv to DEBUG:

logging:
  level:
    de:
      datenkollektiv: DEBUG

The only thing you have to remember is setting the active profile e.g. via Java System Property: -Dspring.profiles.active=dev.

Show Comments