@RequestMapping(value = "/district/{state}", method = RequestMethod.GET) @ResponseBody public ArrayList<String> getAllDistrict(@PathVariable("state") String state) { ArrayList<String> response = null; try { response = signupService.getAllDistrictByState(state); } catch (Exception e) { e.printStackTrace(); } return response; }