private HttpPost createHttpPost(final AttributeMap attributeMap) {
        final HttpPost httpPost = new HttpPost(forwardUrl);
        httpPost.addHeader("User-Agent", userAgent);
        httpPost.addHeader("Content-Type", "application/audit");

        addAuthHeaders(httpPost);

        final AttributeMap sendHeader = AttributeMapUtil.cloneAllowable(attributeMap);
        for (Entry<String, String> entry : sendHeader.entrySet()) {
            httpPost.addHeader(entry.getKey(), entry.getValue());
        }

        // We may be doing an instant forward so need to pass on the compression type.
        // If it is a forward after a store/agg then the caller should have set it in
        // the attr map
        final String compression = attributeMap.get(StandardHeaderArguments.COMPRESSION);
        if (NullSafe.isNonBlankString(compression)) {
            httpPost.addHeader(StandardHeaderArguments.COMPRESSION, compression);
        }

        return httpPost;
    }
Handler class that forwards the request to a URL.
stroom-proxy/stroom-proxy-app/src/main/java/stroom/proxy/app/handler/HttpSender.java