I need to define Duration value (spring.redis.timeout) by application.properties.
I was trying to use one point defined in Spri
If your Spring-Boot version or its dependencies don't put ApplicationConversionService into context (and Spring-Boot doesn't until 2.1), you can expose it explicitly
@Bean
public ConversionService conversionService() {
return ApplicationConversionService.getSharedInstance();
}
It invokes Duration.parse
, so you may use PT3S
, PT1H30M
, etc in properties files.