I’m writing rest service and I explicitly add encoding on produces annotation @Produces(MediaType.APPLICATION_JSON + “;charset=utf-8”) is that mandatory because I found few articles saying that sometimes browser can interpret it incorrectly
Jersey uses UTF-8 as default encoding for response data. BUT it does not specify it explicitly in the response header, which might lead to unexpected results. So, to make sure target browsers are directed to use your character encoding specify it explicitly in your Jersey service.
Any ideas if it’s mandatory or not? I’m exposing the service for the mobile application. By the way, my Jersey version is 2.22.1.