+ " made to wrong domain " + host;
if (LOG.isLoggable(Level.INFO)) {
LOG.logp(Level.INFO, classname, "processRequest", MessageKeys.EMBEDED_IMG_WRONG_DOMAIN,
new Object[] { resourceUri != null ? resourceUri.toString() : "n/a", host });
}
throw new GadgetException(GadgetException.Code.INVALID_PARAMETER, msg,
HttpResponse.SC_BAD_REQUEST);
}
if ("POST".equalsIgnoreCase(request.getMethod())) {
StringBuffer buffer = getPOSTContent(request);
response = proxyHandler.fetch(proxyUri, buffer.toString());
} else {
response = proxyHandler.fetch(proxyUri);
}
} catch (GadgetException e) {
response = ServletUtil.errorResponse(new GadgetException(e.getCode(), e.getMessage(),
HttpServletResponse.SC_BAD_REQUEST));
}
ServletUtil.copyToServletResponseAndOverrideCacheHeaders(response, servletResponse);
}