Search in sources :

Example 11 with ConsumerConfiguration

use of org.apache.pulsar.client.api.ConsumerConfiguration in project incubator-pulsar by apache.

the class V1_ProducerConsumerTest method testBackoffAndReconnect.

@Test(dataProvider = "batch")
public void testBackoffAndReconnect(int batchMessageDelayMs) throws Exception {
    log.info("-- Starting {} test --", methodName);
    // Create consumer and producer
    ConsumerConfiguration conf = new ConsumerConfiguration();
    conf.setSubscriptionType(SubscriptionType.Exclusive);
    Consumer consumer = pulsarClient.subscribe("persistent://my-property/use/my-ns/my-topic4", "my-subscriber-name", conf);
    ProducerConfiguration producerConf = new ProducerConfiguration();
    if (batchMessageDelayMs != 0) {
        producerConf.setBatchingMaxPublishDelay(batchMessageDelayMs, TimeUnit.MILLISECONDS);
        producerConf.setBatchingMaxMessages(5);
        producerConf.setBatchingEnabled(true);
    }
    Producer producer = pulsarClient.createProducer("persistent://my-property/use/my-ns/my-topic4", producerConf);
    // Produce messages
    CompletableFuture<MessageId> lastFuture = null;
    for (int i = 0; i < 10; i++) {
        lastFuture = producer.sendAsync(("my-message-" + i).getBytes()).thenApply(msgId -> {
            log.info("Published message id: {}", msgId);
            return msgId;
        });
    }
    lastFuture.get();
    Message msg = null;
    for (int i = 0; i < 10; i++) {
        msg = consumer.receive(5, TimeUnit.SECONDS);
        log.info("Received: [{}]", new String(msg.getData()));
    }
    // Restart the broker and wait for the backoff to kick in. The client library will try to reconnect, and once
    // the broker is up, the consumer should receive the duplicate messages.
    log.info("-- Restarting broker --");
    restartBroker();
    msg = null;
    log.info("Receiving duplicate messages..");
    for (int i = 0; i < 10; i++) {
        msg = consumer.receive(5, TimeUnit.SECONDS);
        log.info("Received: [{}]", new String(msg.getData()));
        Assert.assertNotNull(msg, "Message cannot be null");
    }
    consumer.acknowledgeCumulative(msg);
    consumer.close();
    log.info("-- Exiting {} test --", methodName);
}
Also used : Producer(org.apache.pulsar.client.api.Producer) LoggerFactory(org.slf4j.LoggerFactory) Test(org.testng.annotations.Test) AfterMethod(org.testng.annotations.AfterMethod) Future(java.util.concurrent.Future) AtomicInteger(java.util.concurrent.atomic.AtomicInteger) Map(java.util.Map) EncryptionKeyInfo(org.apache.pulsar.client.api.EncryptionKeyInfo) Assert.assertFalse(org.testng.Assert.assertFalse) PulsarClientException(org.apache.pulsar.client.api.PulsarClientException) PulsarDecoder(org.apache.pulsar.common.api.PulsarDecoder) Assert.assertNotEquals(org.testng.Assert.assertNotEquals) CyclicBarrier(java.util.concurrent.CyclicBarrier) ConsumerImpl(org.apache.pulsar.client.impl.ConsumerImpl) MessageBuilder(org.apache.pulsar.client.api.MessageBuilder) CompressionType(org.apache.pulsar.client.api.CompressionType) Mockito.atLeastOnce(org.mockito.Mockito.atLeastOnce) BeforeMethod(org.testng.annotations.BeforeMethod) Set(java.util.Set) UUID(java.util.UUID) ConsumerConfiguration(org.apache.pulsar.client.api.ConsumerConfiguration) Collectors(java.util.stream.Collectors) ProducerConfiguration(org.apache.pulsar.client.api.ProducerConfiguration) Executors(java.util.concurrent.Executors) Sets(com.google.common.collect.Sets) Matchers.any(org.mockito.Matchers.any) MessageIdImpl(org.apache.pulsar.client.impl.MessageIdImpl) CountDownLatch(java.util.concurrent.CountDownLatch) Consumer(org.apache.pulsar.client.api.Consumer) List(java.util.List) PersistentTopic(org.apache.pulsar.broker.service.persistent.PersistentTopic) FutureUtil(org.apache.pulsar.common.util.FutureUtil) Modifier(java.lang.reflect.Modifier) ProducerConsumerBase(org.apache.pulsar.client.api.ProducerConsumerBase) ConsumerCryptoFailureAction(org.apache.pulsar.client.api.ConsumerCryptoFailureAction) TopicName(org.apache.pulsar.common.naming.TopicName) DataProvider(org.testng.annotations.DataProvider) Assert.assertEquals(org.testng.Assert.assertEquals) Callable(java.util.concurrent.Callable) CompletableFuture(java.util.concurrent.CompletableFuture) Message(org.apache.pulsar.client.api.Message) Mockito.spy(org.mockito.Mockito.spy) Lists(com.google.common.collect.Lists) Assert(org.testng.Assert) PulsarClient(org.apache.pulsar.client.api.PulsarClient) ExecutorService(java.util.concurrent.ExecutorService) ManagedLedgerImpl(org.apache.bookkeeper.mledger.impl.ManagedLedgerImpl) Logger(org.slf4j.Logger) Files(java.nio.file.Files) Assert.fail(org.testng.Assert.fail) IOException(java.io.IOException) Field(java.lang.reflect.Field) EntryCacheImpl(org.apache.bookkeeper.mledger.impl.EntryCacheImpl) SubscriptionType(org.apache.pulsar.client.api.SubscriptionType) Mockito.verify(org.mockito.Mockito.verify) ExecutionException(java.util.concurrent.ExecutionException) TimeUnit(java.util.concurrent.TimeUnit) CryptoKeyReader(org.apache.pulsar.client.api.CryptoKeyReader) MessageId(org.apache.pulsar.client.api.MessageId) Paths(java.nio.file.Paths) Assert.assertTrue(org.testng.Assert.assertTrue) Consumer(org.apache.pulsar.client.api.Consumer) Producer(org.apache.pulsar.client.api.Producer) Message(org.apache.pulsar.client.api.Message) ConsumerConfiguration(org.apache.pulsar.client.api.ConsumerConfiguration) ProducerConfiguration(org.apache.pulsar.client.api.ProducerConfiguration) MessageId(org.apache.pulsar.client.api.MessageId) Test(org.testng.annotations.Test)

Example 12 with ConsumerConfiguration

use of org.apache.pulsar.client.api.ConsumerConfiguration in project incubator-pulsar by apache.

the class V1_ProducerConsumerTest method testPriorityConsumer.

@Test
public void testPriorityConsumer() throws Exception {
    log.info("-- Starting {} test --", methodName);
    ConsumerConfiguration conf1 = new ConsumerConfiguration();
    conf1.setSubscriptionType(SubscriptionType.Shared);
    conf1.setPriorityLevel(1);
    conf1.setReceiverQueueSize(5);
    ConsumerConfiguration conf4 = new ConsumerConfiguration();
    conf4.setSubscriptionType(SubscriptionType.Shared);
    conf4.setPriorityLevel(2);
    conf4.setReceiverQueueSize(5);
    Consumer consumer1 = pulsarClient.subscribe("persistent://my-property/use/my-ns/my-topic2", "my-subscriber-name", conf1);
    Consumer consumer2 = pulsarClient.subscribe("persistent://my-property/use/my-ns/my-topic2", "my-subscriber-name", conf1);
    Consumer consumer3 = pulsarClient.subscribe("persistent://my-property/use/my-ns/my-topic2", "my-subscriber-name", conf1);
    Consumer consumer4 = pulsarClient.subscribe("persistent://my-property/use/my-ns/my-topic2", "my-subscriber-name", conf4);
    ProducerConfiguration producerConf = new ProducerConfiguration();
    Producer producer = pulsarClient.createProducer("persistent://my-property/use/my-ns/my-topic2", producerConf);
    List<Future<MessageId>> futures = Lists.newArrayList();
    // Asynchronously produce messages
    for (int i = 0; i < 15; i++) {
        final String message = "my-message-" + i;
        Future<MessageId> future = producer.sendAsync(message.getBytes());
        futures.add(future);
    }
    log.info("Waiting for async publish to complete");
    for (Future<MessageId> future : futures) {
        future.get();
    }
    for (int i = 0; i < 20; i++) {
        consumer1.receive(100, TimeUnit.MILLISECONDS);
        consumer2.receive(100, TimeUnit.MILLISECONDS);
    }
    /**
     * a. consumer1 and consumer2 now has more permits (as received and sent more permits) b. try to produce more
     * messages: which will again distribute among consumer1 and consumer2 and should not dispatch to consumer4
     */
    for (int i = 0; i < 5; i++) {
        final String message = "my-message-" + i;
        Future<MessageId> future = producer.sendAsync(message.getBytes());
        futures.add(future);
    }
    Assert.assertNull(consumer4.receive(100, TimeUnit.MILLISECONDS));
    // Asynchronously acknowledge upto and including the last message
    producer.close();
    consumer1.close();
    consumer2.close();
    consumer3.close();
    consumer4.close();
    log.info("-- Exiting {} test --", methodName);
}
Also used : Consumer(org.apache.pulsar.client.api.Consumer) Producer(org.apache.pulsar.client.api.Producer) ConsumerConfiguration(org.apache.pulsar.client.api.ConsumerConfiguration) ProducerConfiguration(org.apache.pulsar.client.api.ProducerConfiguration) Future(java.util.concurrent.Future) CompletableFuture(java.util.concurrent.CompletableFuture) MessageId(org.apache.pulsar.client.api.MessageId) Test(org.testng.annotations.Test)

Example 13 with ConsumerConfiguration

use of org.apache.pulsar.client.api.ConsumerConfiguration in project incubator-pulsar by apache.

the class V1_ProducerConsumerTest method testEnabledChecksumClient.

@Test
public void testEnabledChecksumClient() throws Exception {
    log.info("-- Starting {} test --", methodName);
    final int totalMsg = 10;
    ConsumerConfiguration conf = new ConsumerConfiguration();
    conf.setSubscriptionType(SubscriptionType.Exclusive);
    Consumer consumer = pulsarClient.subscribe("persistent://my-property/use/my-ns/my-topic1", "my-subscriber-name", conf);
    ProducerConfiguration producerConf = new ProducerConfiguration();
    final int batchMessageDelayMs = 300;
    if (batchMessageDelayMs != 0) {
        producerConf.setBatchingEnabled(true);
        producerConf.setBatchingMaxPublishDelay(batchMessageDelayMs, TimeUnit.MILLISECONDS);
        producerConf.setBatchingMaxMessages(5);
    }
    Producer producer = pulsarClient.createProducer("persistent://my-property/use/my-ns/my-topic1", producerConf);
    for (int i = 0; i < totalMsg; i++) {
        String message = "my-message-" + i;
        producer.send(message.getBytes());
    }
    Message msg = null;
    Set<String> messageSet = Sets.newHashSet();
    for (int i = 0; i < totalMsg; i++) {
        msg = consumer.receive(5, TimeUnit.SECONDS);
        String receivedMessage = new String(msg.getData());
        log.debug("Received message: [{}]", receivedMessage);
        String expectedMessage = "my-message-" + i;
        testMessageOrderAndDuplicates(messageSet, receivedMessage, expectedMessage);
    }
    // Acknowledge the consumption of all messages at once
    consumer.acknowledgeCumulative(msg);
    consumer.close();
    log.info("-- Exiting {} test --", methodName);
}
Also used : Consumer(org.apache.pulsar.client.api.Consumer) Producer(org.apache.pulsar.client.api.Producer) Message(org.apache.pulsar.client.api.Message) ConsumerConfiguration(org.apache.pulsar.client.api.ConsumerConfiguration) ProducerConfiguration(org.apache.pulsar.client.api.ProducerConfiguration) Test(org.testng.annotations.Test)

Example 14 with ConsumerConfiguration

use of org.apache.pulsar.client.api.ConsumerConfiguration in project incubator-pulsar by apache.

the class V1_ProducerConsumerTest method testConsumerBlockingWithUnAckedMessagesMultipleIteration.

/**
 * Verify: iteration of a. message receive w/o acking b. stop receiving msg c. ack msgs d. started receiving msgs
 *
 * 1. Produce total X (1500) messages 2. Consumer consumes messages without acking until stop receiving from broker
 * due to reaching ack-threshold (500) 3. Consumer acks messages after stop getting messages 4. Consumer again tries
 * to consume messages 5. Consumer should be able to complete consuming all 1500 messages in 3 iteration (1500/500)
 *
 * @throws Exception
 */
@Test
public void testConsumerBlockingWithUnAckedMessagesMultipleIteration() throws Exception {
    log.info("-- Starting {} test --", methodName);
    int unAckedMessages = pulsar.getConfiguration().getMaxUnackedMessagesPerConsumer();
    try {
        final int unAckedMessagesBufferSize = 500;
        final int receiverQueueSize = 10;
        final int totalProducedMsgs = 1500;
        // receiver consumes messages in iteration after acknowledging broker
        final int totalReceiveIteration = totalProducedMsgs / unAckedMessagesBufferSize;
        pulsar.getConfiguration().setMaxUnackedMessagesPerConsumer(unAckedMessagesBufferSize);
        ConsumerConfiguration conf = new ConsumerConfiguration();
        conf.setReceiverQueueSize(receiverQueueSize);
        conf.setSubscriptionType(SubscriptionType.Shared);
        Consumer consumer = pulsarClient.subscribe("persistent://my-property/use/my-ns/unacked-topic", "subscriber-1", conf);
        ProducerConfiguration producerConf = new ProducerConfiguration();
        Producer producer = pulsarClient.createProducer("persistent://my-property/use/my-ns/unacked-topic", producerConf);
        // (1) Produced Messages
        for (int i = 0; i < totalProducedMsgs; i++) {
            String message = "my-message-" + i;
            producer.send(message.getBytes());
        }
        int totalReceivedMessages = 0;
        // (2) Receive Messages
        for (int j = 0; j < totalReceiveIteration; j++) {
            Message msg = null;
            List<Message> messages = Lists.newArrayList();
            for (int i = 0; i < totalProducedMsgs; i++) {
                msg = consumer.receive(1, TimeUnit.SECONDS);
                if (msg != null) {
                    messages.add(msg);
                    log.info("Received message: " + new String(msg.getData()));
                } else {
                    break;
                }
            }
            // client must receive number of messages = unAckedMessagesBufferSize rather all produced messages
            assertEquals(messages.size(), unAckedMessagesBufferSize);
            // start acknowledging messages
            messages.forEach(m -> {
                try {
                    consumer.acknowledge(m);
                } catch (PulsarClientException e) {
                    fail("ack failed", e);
                }
            });
            totalReceivedMessages += messages.size();
        }
        // total received-messages should match to produced messages
        assertEquals(totalReceivedMessages, totalProducedMsgs);
        producer.close();
        consumer.close();
        log.info("-- Exiting {} test --", methodName);
    } catch (Exception e) {
        fail();
    } finally {
        pulsar.getConfiguration().setMaxUnackedMessagesPerConsumer(unAckedMessages);
    }
}
Also used : Consumer(org.apache.pulsar.client.api.Consumer) Producer(org.apache.pulsar.client.api.Producer) Message(org.apache.pulsar.client.api.Message) ConsumerConfiguration(org.apache.pulsar.client.api.ConsumerConfiguration) PulsarClientException(org.apache.pulsar.client.api.PulsarClientException) ProducerConfiguration(org.apache.pulsar.client.api.ProducerConfiguration) PulsarClientException(org.apache.pulsar.client.api.PulsarClientException) IOException(java.io.IOException) ExecutionException(java.util.concurrent.ExecutionException) Test(org.testng.annotations.Test)

Example 15 with ConsumerConfiguration

use of org.apache.pulsar.client.api.ConsumerConfiguration in project incubator-pulsar by apache.

the class JavaInstanceRunnableProcessTest method setup.

@BeforeMethod
public void setup() throws Exception {
    mockProducers.clear();
    mockConsumers.clear();
    fnConfig = FunctionConfig.newBuilder().setAutoAck(true).setClassName(TestFunction.class.getName()).addInputs("test-src-topic").setName("test-function").setOutput("test-output-topic").setProcessingGuarantees(ProcessingGuarantees.ATLEAST_ONCE).setTenant("test-tenant").setNamespace("test-namespace").build();
    config = new InstanceConfig();
    config.setFunctionId("test-function-id");
    config.setFunctionVersion("v1");
    config.setInstanceId("test-instance-id");
    config.setMaxBufferedTuples(1000);
    config.setFunctionConfig(fnConfig);
    mockClient = mock(PulsarClientImpl.class);
    // mock FunctionCacheManager
    fnCache = mock(FunctionCacheManager.class);
    doNothing().when(fnCache).registerFunctionInstance(anyString(), anyString(), anyList(), anyList());
    doNothing().when(fnCache).unregisterFunctionInstance(anyString(), anyString());
    ClassLoader clsLoader = JavaInstanceRunnableTest.class.getClassLoader();
    when(fnCache.getClassLoader(anyString())).thenReturn(clsLoader);
    // mock producer & consumer
    when(mockClient.createProducer(anyString(), any(ProducerConfiguration.class))).thenAnswer(invocationOnMock -> {
        String topic = invocationOnMock.getArgumentAt(0, String.class);
        ProducerConfiguration conf = invocationOnMock.getArgumentAt(1, ProducerConfiguration.class);
        String producerName = conf.getProducerName();
        Pair<String, String> pair = Pair.of(topic, producerName);
        ProducerInstance producerInstance = mockProducers.get(pair);
        if (null == producerInstance) {
            Producer producer = mock(Producer.class);
            LinkedBlockingQueue<Message> msgQueue = new LinkedBlockingQueue<>();
            final ProducerInstance instance = new ProducerInstance(producer, msgQueue);
            producerInstance = instance;
            when(producer.getProducerName()).thenReturn(producerName);
            when(producer.getTopic()).thenReturn(topic);
            when(producer.sendAsync(any(Message.class))).thenAnswer(invocationOnMock1 -> {
                Message msg = invocationOnMock1.getArgumentAt(0, Message.class);
                log.info("producer send message {}", msg);
                CompletableFuture<MessageId> future = new CompletableFuture<>();
                instance.addSendFuture(future);
                msgQueue.put(msg);
                return future;
            });
            when(producer.closeAsync()).thenReturn(FutureUtils.Void());
            mockProducers.put(pair, producerInstance);
        }
        return producerInstance.getProducer();
    });
    when(mockClient.subscribe(anyString(), anyString(), any(ConsumerConfiguration.class))).thenAnswer(invocationOnMock -> {
        String topic = invocationOnMock.getArgumentAt(0, String.class);
        String subscription = invocationOnMock.getArgumentAt(1, String.class);
        ConsumerConfiguration conf = invocationOnMock.getArgumentAt(2, ConsumerConfiguration.class);
        Pair<String, String> pair = Pair.of(topic, subscription);
        ConsumerInstance consumerInstance = mockConsumers.get(pair);
        if (null == consumerInstance) {
            Consumer consumer = mock(Consumer.class);
            ConsumerInstance instance = new ConsumerInstance(consumer, conf);
            consumerInstance = instance;
            when(consumer.getTopic()).thenReturn(topic);
            when(consumer.getSubscription()).thenReturn(subscription);
            when(consumer.acknowledgeAsync(any(Message.class))).thenAnswer(invocationOnMock1 -> {
                Message msg = invocationOnMock1.getArgumentAt(0, Message.class);
                log.info("Ack message {} : message id = {}", msg, msg.getMessageId());
                instance.removeMessage(msg.getMessageId());
                return FutureUtils.Void();
            });
            when(consumer.acknowledgeCumulativeAsync(any(Message.class))).thenAnswer(invocationOnMock1 -> {
                Message msg = invocationOnMock1.getArgumentAt(0, Message.class);
                log.info("Ack message cumulatively message id = {}", msg, msg.getMessageId());
                instance.removeMessagesBefore(msg.getMessageId());
                return FutureUtils.Void();
            });
            when(consumer.closeAsync()).thenAnswer(invocationOnMock1 -> {
                mockConsumers.remove(pair, instance);
                return FutureUtils.Void();
            });
            doAnswer(invocationOnMock1 -> {
                mockConsumers.remove(pair, instance);
                return null;
            }).when(consumer).close();
            mockConsumers.put(pair, consumerInstance);
        }
        return consumerInstance.getConsumer();
    });
    // 
    // Mock State Store
    // 
    StorageClientBuilder mockBuilder = mock(StorageClientBuilder.class);
    when(mockBuilder.withNamespace(anyString())).thenReturn(mockBuilder);
    when(mockBuilder.withSettings(any(StorageClientSettings.class))).thenReturn(mockBuilder);
    this.mockStorageClient = mock(StorageClient.class);
    when(mockBuilder.build()).thenReturn(mockStorageClient);
    StorageAdminClient adminClient = mock(StorageAdminClient.class);
    when(mockBuilder.buildAdmin()).thenReturn(adminClient);
    PowerMockito.mockStatic(StorageClientBuilder.class);
    PowerMockito.when(StorageClientBuilder.newBuilder()).thenReturn(mockBuilder);
    when(adminClient.getStream(anyString(), anyString())).thenReturn(FutureUtils.value(StreamProperties.newBuilder().build()));
    mockTable = mock(Table.class);
    when(mockStorageClient.openTable(anyString())).thenReturn(FutureUtils.value(mockTable));
    // 
    // Mock Function Stats
    // 
    mockFunctionStats = spy(new FunctionStats());
    PowerMockito.whenNew(FunctionStats.class).withNoArguments().thenReturn(mockFunctionStats);
    // Mock message builder
    PowerMockito.mockStatic(MessageBuilder.class);
    PowerMockito.when(MessageBuilder.create()).thenAnswer(invocationOnMock -> {
        Message msg = mock(Message.class);
        MessageBuilder builder = mock(MessageBuilder.class);
        when(builder.setContent(any(byte[].class))).thenAnswer(invocationOnMock1 -> {
            byte[] content = invocationOnMock1.getArgumentAt(0, byte[].class);
            when(msg.getData()).thenReturn(content);
            return builder;
        });
        when(builder.setSequenceId(anyLong())).thenAnswer(invocationOnMock1 -> {
            long seqId = invocationOnMock1.getArgumentAt(0, long.class);
            when(msg.getSequenceId()).thenReturn(seqId);
            return builder;
        });
        when(builder.setProperty(anyString(), anyString())).thenAnswer(invocationOnMock1 -> {
            String key = invocationOnMock1.getArgumentAt(0, String.class);
            String value = invocationOnMock1.getArgumentAt(1, String.class);
            when(msg.getProperty(eq(key))).thenReturn(value);
            return builder;
        });
        when(builder.build()).thenReturn(msg);
        return builder;
    });
}
Also used : Message(org.apache.pulsar.client.api.Message) ProducerConfiguration(org.apache.pulsar.client.api.ProducerConfiguration) Matchers.anyString(org.mockito.Matchers.anyString) LinkedBlockingQueue(java.util.concurrent.LinkedBlockingQueue) CompletableFuture(java.util.concurrent.CompletableFuture) Consumer(org.apache.pulsar.client.api.Consumer) MessageBuilder(org.apache.pulsar.client.api.MessageBuilder) ConsumerConfiguration(org.apache.pulsar.client.api.ConsumerConfiguration) FunctionCacheManager(org.apache.pulsar.functions.utils.functioncache.FunctionCacheManager) Table(org.apache.bookkeeper.api.kv.Table) StorageClientBuilder(org.apache.bookkeeper.clients.StorageClientBuilder) StorageAdminClient(org.apache.bookkeeper.clients.admin.StorageAdminClient) StorageClient(org.apache.bookkeeper.api.StorageClient) StorageClientSettings(org.apache.bookkeeper.clients.config.StorageClientSettings) Producer(org.apache.pulsar.client.api.Producer) PulsarClientImpl(org.apache.pulsar.client.impl.PulsarClientImpl) MessageId(org.apache.pulsar.client.api.MessageId) BeforeMethod(org.testng.annotations.BeforeMethod)

Aggregations

ConsumerConfiguration (org.apache.pulsar.client.api.ConsumerConfiguration)36 Test (org.testng.annotations.Test)32 Producer (org.apache.pulsar.client.api.Producer)29 ProducerConfiguration (org.apache.pulsar.client.api.ProducerConfiguration)29 Consumer (org.apache.pulsar.client.api.Consumer)28 Message (org.apache.pulsar.client.api.Message)25 PulsarClientException (org.apache.pulsar.client.api.PulsarClientException)15 IOException (java.io.IOException)14 ExecutionException (java.util.concurrent.ExecutionException)14 CompletableFuture (java.util.concurrent.CompletableFuture)9 MessageId (org.apache.pulsar.client.api.MessageId)9 Future (java.util.concurrent.Future)7 ConsumerImpl (org.apache.pulsar.client.impl.ConsumerImpl)7 Map (java.util.Map)6 CountDownLatch (java.util.concurrent.CountDownLatch)6 ExecutorService (java.util.concurrent.ExecutorService)6 CryptoKeyReader (org.apache.pulsar.client.api.CryptoKeyReader)6 EncryptionKeyInfo (org.apache.pulsar.client.api.EncryptionKeyInfo)6 Field (java.lang.reflect.Field)5 ManagedLedgerImpl (org.apache.bookkeeper.mledger.impl.ManagedLedgerImpl)5