private void handleError(Throwable cause) {
        ZuulException ze = (cause instanceof ZuulException)
                ? (ZuulException) cause
                : requestAttemptFactory.mapNettyToOutboundException(cause, context);
        logger.debug("Proxy endpoint failed.", cause);
        if (!startedSendingResponseToClient) {
            startedSendingResponseToClient = true;
            zuulResponse = new HttpResponseMessageImpl(context, zuulRequest, ze.getStatusCode());
            zuulResponse
                    .getHeaders()
                    .add(
                            "Connection",
                            "close"); // TODO - why close the connection? maybe don't always want this to happen ...
            zuulResponse.finishBufferedBodyIfIncomplete();
            invokeNext(zuulResponse);
        } else {
            channelCtx.fireExceptionCaught(ze);
        }
    }
Override to track your own request stats.
zuul-core/src/main/java/com/netflix/zuul/filters/endpoint/ProxyEndpoint.java