I have a CDI bean in a JSF application with this property:
@NotNull(message = "Senha não informada.")
public String getSenha()
{
return _senha;
}
The problem is that when validation fails the message displayed on the page is this:
Senha não informada.
The problem is not with JSF, but with Bean Validation, because if I place the message in a standard JSF validator and use it instead of the bean validation annotation, the message is displayed correctly with the right accented characters.
I tried changing the request and response encoding to UTF-8 in a filter to see if the problem was fixed, but the problem remains.
Of course, if I change the annotation message to this Senha n\u00e3o informada. I get the right message on the page, but I don't want this. I want a way to instruct the bean validation API (or another thing) to use the accented characters in my own language.
I'm using Wildfly 10 with all default libraries.
P.S.: I don't want to use a message bundle for my messages.