a11enhuang commented on issue #18224:
URL: https://github.com/apache/pulsar/issues/18224#issuecomment-1342772981
I wrote a test case that reproduces the issue:
This is the code when the producer sends the message
```java
producer.newMessage()
.value("hello")
.deliverAfter(2L, TimeUnit.SECONDS)
.send();
```
Here is the code for the consumer to receive the message:
```java
Consumer<byte[]> consumer = client.newConsumer()
.subscriptionType(SubscriptionType.Shared)
.subscribe();
Message<byte[]> message = consumer.receive();
```
When the producer sends the message, the consumer receives the message
immediately.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]