public static void benchmarkOutput(HeaderFields responseHeaders, boolean benchmarkCoverage,
                                       Timing t, HitCounts c, int errorCount, Coverage coverage) {
        long renderStartTime = System.currentTimeMillis();
        if (c != null) {
            // Fill inn response getHeaders
            responseHeaders.add(BenchmarkingHeaders.NUM_HITS, String.valueOf(c.getRetrievedHitCount()));
            responseHeaders.add(BenchmarkingHeaders.NUM_FASTHITS, String.valueOf(c.getSummaryCount()));
            responseHeaders.add(BenchmarkingHeaders.TOTAL_HIT_COUNT, String.valueOf(c.getTotalHitCount()));
            responseHeaders.add(BenchmarkingHeaders.QUERY_HITS, String.valueOf(c.getRequestedHits()));
            responseHeaders.add(BenchmarkingHeaders.QUERY_OFFSET, String.valueOf(c.getRequestedOffset()));
        }
        responseHeaders.add(BenchmarkingHeaders.NUM_ERRORS, String.valueOf(errorCount));
        if (t != null) {
            if (t.getSummaryStartTime() != 0) {
                responseHeaders.add(BenchmarkingHeaders.SEARCH_TIME,
                                    String.valueOf(t.getSummaryStartTime() - t.getQueryStartTime()));
                responseHeaders.add(BenchmarkingHeaders.ATTR_TIME, "0");
                responseHeaders.add(BenchmarkingHeaders.FILL_TIME,
                                    String.valueOf(renderStartTime - t.getSummaryStartTime()));
            } else {
                responseHeaders.add(BenchmarkingHeaders.SEARCH_TIME,
                                    String.valueOf(renderStartTime - t.getQueryStartTime()));
                responseHeaders.add(BenchmarkingHeaders.ATTR_TIME, "0");
                responseHeaders.add(BenchmarkingHeaders.FILL_TIME, "0");
            }
        }

        if (benchmarkCoverage && coverage != null) {
            responseHeaders.add(BenchmarkingHeaders.DOCS_SEARCHED, String.valueOf(coverage.getDocs()));
            responseHeaders.add(BenchmarkingHeaders.NODES_SEARCHED, String.valueOf(coverage.getNodes()));
            responseHeaders.add(BenchmarkingHeaders.FULL_COVERAGE, String.valueOf(coverage.getFull() ? 1 : 0));
        }
    }
Add search benchmark output to the HTTP getHeaders.

@param responseHeaders   the response to write the headers to
@param benchmarkCoverage true to include coverage headers
@param t                 the Timing to read data from
@param c                 the Counts to read data from
@param errorCount        the error count
@param coverage          the Coverage to read data from
container-core/src/main/java/com/yahoo/container/jdisc/VespaHeaders.java