xujianhai666 commented on a change in pull request #156: [ISSUE #152][consumer] 
add consumer timeout
URL: https://github.com/apache/pulsar-client-go/pull/156#discussion_r362692794
 
 

 ##########
 File path: pulsar/consumer.go
 ##########
 @@ -135,6 +135,10 @@ type Consumer interface {
        // This calls blocks until a message is available.
        Receive(context.Context) (Message, error)
 
+       // Receive a single message.
+       // This calls blocks until a message is available or timeout.
+       ReceiveBlock(context.Context, time.Duration) (Message, error)
 
 Review comment:
   @cckellogg I agree with u, And under wolfstudy  idea, I thought the 
ConsumerOptions is better, Do u agree with that?

----------------------------------------------------------------
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.
 
For queries about this service, please contact Infrastructure at:
[email protected]


With regards,
Apache Git Services

Reply via email to