This is my method inside my controller which is annotated by @Controller
@RequestMapping(value = \"/getServerAlertFilters/{serverName}/\", produ
The 406 Not Acceptable status code means that Spring couldn't convert the object to json. You can either make your controller method return a String and do return json.toString(); or configure your own HandlerMethodReturnValueHandler. Check this similar question Returning JsonObject using @ResponseBody in SpringMVC