Spring @Value TypeMismatchException:Failed to convert value of type ‘java.lang.String’ to required type ‘java.lang.Double’

Try changing the following line

@Value("${item.priceFactor}")

to

@Value("#{new Double('${item.priceFactor}')}")

Leave a Comment