The application.yml file has a Long type setting:
producer.init-delay: 15000
It is used in this method:
@Scheduled(fixedRate = 25000, initialDelay = "#{new Long('${producer.init-delay}')}")
public produce() {}
Take an example from the question:Spring @Value TypeMismatchException:...
But I have this code gives an error:
Incompatible types. Found: 'java.lang.String', required: 'long'