0
votes

I use Cyrillic symbols in my project.

My way to read Cyrillic symbols from the swagger-message.properties is here:

@Bean
    public ResourceBundleMessageSource translator() {
        ResourceBundleMessageSource source = new ResourceBundleMessageSource();
        source.setBasenames("swagger-message");
        source.setUseCodeAsDefaultMessage(true);
        return source;
    }

I want not to translate my words to unicode symbols. Is it possible to set encoding like UTF-8 for the beans?

1

1 Answers

0
votes

I've already found the answer:

source.setDefaultEncoding("utf-8");

I just needed to add default encoding using the method