private void doFailure(String string) {
        failure = failureFactory.createFailure(PolicyFailureType.Authorization, 400, "CORS: " + string); //$NON-NLS-1$
        failure.setHeaders(responseHeaders);
        failure.setResponseCode(400);
    }
Is the request related to CORS? Helps avoid unnecessary object creation.

@param request the request
@return true if CORS is a request
plugins/cors-policy/src/main/java/io/apiman/plugins/cors_policy/CorsConnector.java