-
Notifications
You must be signed in to change notification settings - Fork 41.5k
Description
Starting with 2.1.0.M4, org.springframework.boot.convert.ApplicationConversionService.getSharedInstance()
now returns an ApplicationConversionService
instead of a ConversionService
.
While ApplicationConversionService
inherits from ConversionService
, this does break binary compatibility according to Java rules.
This means that client code that called ApplicationConversionService.getSharedInstance()
needs to be recompiled to work with Spring Boot 2.1, and will not be backward compatible with prior Spring Boot versions.
Currently this affects jasypt-spring-boot, as seen in ulisesbocchio/jasypt-spring-boot#102
While I understand that breaking changes must sometimes be introduced, I was wondering if there is a strong reason for this change, and if it might still be reversed if not?
I checked Spring Boot's code base, and it appears that only the following methods require that ApplicationConversionService.getSharedInstance()
returns a ConfigurableConversionService
(not an ApplicationConversionService
).
- org.springframework.boot.SpringApplication#configureEnvironment
- org.springframework.boot.SpringApplication#postProcessApplicationContext
The commit that introduces this change was 0c00508, with the comment
Update
SpringApplication
to automatically register the sharedApplicationConversionService
instance with theBeanFactory
andEnvironment
.
Thanks in advance