@Override
    public void errorRequest(Throwable ex, long consumeTimeMs) {
        baseStats(consumeTimeMs);
        failRequestCount.incrementAndGet();
    }
@Test
    public void errorRequest() {
        final InstanceStats stats = new InstanceStats();
        long consumerMs = 100L;
        stats.errorRequest(new Exception("ss"), consumerMs);
        Assert.assertEquals(stats.getFailRequestCount().get(), 1);
        Assert.assertEquals(stats.getActiveRequests(), 0);
        Assert.assertEquals(stats.getAllRequestConsumeTime().get(), 100);
        stats.beforeRequest();
        stats.errorRequest(new Exception("ss"), consumerMs);
        Assert.assertEquals(stats.getActiveRequests(), 0);

    }