Resttemplate throws NPE with spring-boot-starter-log4j2 within tests #26120
Labels
in: core
Issues in core modules (aop, beans, core, context, expression)
type: regression
A bug that is also a regression
Milestone
Resttemplate throws a NPE with dependency spring-boot-starter-log4j2 within tests calling RestTemplate construtor.
Repository for reproduce:
https://github.com/mnhock/resttemplate-bug
Simple call the RestConfigurationTest.
If you remove spring-boot-starter-log4j2 dependency from the pom it works.
The problem is that the init of the Logger depends on the SpringProperties as well but is initialized before the localProperties is initialized.
I think the problem exists with other files changed in #25151 as well.
Thanks,
Martin
The text was updated successfully, but these errors were encountered: