Language: Java
Label: safe
CWE: NVD-CWE-noinfo \u2014 

Code:
    private static void fillRequest(
            ServiceRequestContext ctx, AggregatedHttpRequest aReq, Request jReq, String mappedPath) {
        DispatcherTypeUtil.setRequestType(jReq);
        jReq.setAsyncSupported(true, null);
        jReq.setSecure(ctx.sessionProtocol().isTls());
        jReq.setMetaData(toRequestMetadata(ctx, aReq, mappedPath));
        final HttpHeaders trailers = aReq.trailers();
        if (!trailers.isEmpty()) {
            final HttpField[] httpFields = trailers.stream()
                                                   .map(e -> new HttpField(e.getKey().toString(), e.getValue()))
                                                   .toArray(HttpField[]::new);
            jReq.setTrailerHttpFields(HttpFields.from(httpFields));
        }
    }