@Override @GET @Path("/user/username/{userName}") public Response getUserWithUserName(@PathParam("userName") final String userName) { try { final User user = ticketSystemService.getUserWithUserName(userName); return Response.status(200).entity(gson.toJson(user)).build(); } catch (final TicketSystemServiceException exception) { return Response.status(400).entity(exception).build(); } }