}
@Override
public void log(Request request, Response response)
{
Duration requestTime = new Duration(max(0, System.currentTimeMillis() - request.getTimeStamp()), TimeUnit.MILLISECONDS);
long dispatchTime = request.getTimeStamp();
Duration schedulingDelay = new Duration(max(0, dispatchTime - request.getTimeStamp()), TimeUnit.MILLISECONDS);
stats.record(request.getMethod(), response.getStatus(), request.getContentRead(), response.getContentCount(), schedulingDelay, requestTime);
detailedRequestStats.requestTimeByCode(response.getStatus()).add(requestTime);
}