private String formatHeaderEntryListForLogging(final Header[] headers) {
        return NullSafe.stream(headers)
                .map(header -> new SimpleEntry<>(
                        Objects.requireNonNullElse(header.getName(), "null"),
                        header.getValue())
                )
                .sorted(Entry.comparingByKey())
                .map(entry -> "  " + String.join(
                        ":",
                        NullSafe.string(entry.getKey()),
                        NullSafe.stream(entry.getValue())
                                .filter(Objects::nonNull)
                                .map(val -> "'" + val + "'")
                                .collect(Collectors.joining(", "))))
                .collect(Collectors.joining("\n"));
    }
Handler class that forwards the request to a URL.
stroom-proxy/stroom-proxy-app/src/main/java/stroom/proxy/app/handler/HttpSender.java