class HostRequestIntervalRegistry {

    public long tick(String clientHostId) {
        if (whiteList.contains(clientHostId)) {
            return 0;
        } else if (blackList.contains(clientHostId)) {
            return Long.MAX_VALUE;
        }
        IntervalCount intervalCount = hostCounts.computeIfAbsent(clientHostId, s -> new IntervalCount(intervalDurationMs));
        return intervalCount.resetIfExpiredAndTick();
    }

}

class HostRequestIntervalRegistryTest {

    private HostRequestIntervalRegistry registry;

    @Test
    public void emptyBlacklistParsedOk(){

        registry = new HostRequestIntervalRegistry(10000L, 100L,"", "");
        assertEquals(1L, registry.tick("aaa"));
    }

}