use of org.zalando.nakadi.repository.zookeeper.ZooKeeperLockFactory in project nakadi by zalando.
the class ConsumerLimitingServiceAT method before.
@Before
public void before() {
eventType = TestUtils.randomValidEventTypeName();
client = TestUtils.randomTextString();
final ZooKeeperHolder zkHolder = Mockito.mock(ZooKeeperHolder.class);
when(zkHolder.get()).thenReturn(CURATOR);
final ZooKeeperLockFactory zkLockFactory = new ZooKeeperLockFactory(zkHolder);
limitingService = new ConsumerLimitingService(zkHolder, zkLockFactory, 5);
}
Aggregations