eclipse-ee4j / eclipse-ee4j/jersey

bean validation use ISO-8859-1 for file encoding by default

Open
#4,162 0 comments 0 reactions 0 assignees View on GitHub
Dominant language
Java
Stars
730
Forks
382
PR merge metrics
No merged PRs in 30d

Description

I want to implement international (i18n) bean validation in my javaee project. So i have ValidationMessages_fr.properties for french bean validation. And i use default implementation which is in bean-validation-example project project by jersey team. But after bean validation, in ConstraintViolationException Messages, this "La donnée n'existe pas" become this "La donnée n'exite pas". But i take care to encode ValidationMessages_fr.properties and java class file in utf-8.
But jersey decide each time to use ISO-8859-1. i know jersey use ISO-8859-1 because when i write my codes like that "message = new String(message.getBytes("ISO-8851-1"), "utf-8"), it work son local server and works also on google app engine.
So how to correctly configure bean validator to use on configuration step utf-8 to read bean validation files ?

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.