public static void postRestRequestFromServlet(HttpServletRequest request, String endpoint, Map<String, Object> attrs, boolean quiet, boolean throwException) {
String token = (String) request.getSession().getAttribute(AdminConsoleAuthModule.REST_TOKEN);
WebTarget target = JERSEY_CLIENT.target(endpoint);
MultivaluedMap formData = buildMultivalueMap(attrs);
Response cr = target
.request(RESPONSE_TYPE)
.cookie(new Cookie(REST_TOKEN_COOKIE, token))
.post(Entity.entity(formData, MediaType.APPLICATION_FORM_URLENCODED), Response.class);
RestResponse rr = RestResponse.getRestResponse(cr);
parseResponse(rr, null, endpoint, attrs, quiet, throwException);