I am trying to use resource bundles with Spring\'s Message Source. Here is the way I am doing it:
@Component
public class MessageResolver implements MessageS
YAML version for this
spring:
messages:
basename: i18n/validation, i18n/message # for multiple properties just use comma separated values
encoding: UTF-8
You can refer to documentation to see full description.
Also I should mention that the default MessageSource
bean is a ResourceBundleMessageSource
which is already reading form a classpath so there is no need to use nonation like classpath:i18n/validation
.