Open
Description
The WebMvcConfigurerAdapter
will be executed methods twice (addViewControllers
, addResourceHandlers
) if you use management.port = 9251
(for instance). There are two application contexts and they use the same WebMvcConfigurerAdapter
.
That's why the same urls does not work. if you have rest api with /health
for example.
I guess the good solution is don't give management (Actuators) use WebMvcConfigurerAdapter
.
or found the solution to filter it out form Actuators.
server:
port: 9250
address: 0.0.0.0
context-path: /path
session-timeout: 300
management:
port: 9251
address: 0.0.0.0
addApplicationContextHeader: false
context-path: /
security:
enabled: false
role: ADMIN