This is an automated email from the ASF dual-hosted git repository.

dinglei pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/rocketmq-client-go.git


The following commit(s) were added to refs/heads/master by this push:
     new 3010ce9  feat: Add pause initialization to default PullConsumer to 
prevent panic (#1226)
3010ce9 is described below

commit 3010ce94c06f4cef7ec9d805e2daed744d9fe7f7
Author: wenxuwan <[email protected]>
AuthorDate: Fri Oct 24 09:59:28 2025 +0800

    feat: Add pause initialization to default PullConsumer to prevent panic 
(#1226)
    
    * fix pull consumer panic
    
    ---------
    
    Co-authored-by: 文徐 <[email protected]>
---
 consumer/pull_consumer.go | 1 +
 1 file changed, 1 insertion(+)

diff --git a/consumer/pull_consumer.go b/consumer/pull_consumer.go
index c6af4f7..5fc747d 100644
--- a/consumer/pull_consumer.go
+++ b/consumer/pull_consumer.go
@@ -113,6 +113,7 @@ func NewPullConsumer(options ...Option) 
(*defaultPullConsumer, error) {
                consumerGroup: utils.WrapNamespace(defaultOpts.Namespace, 
defaultOpts.GroupName),
                cType:         _PullConsume,
                state:         
atomic2.NewInt32(int32(internal.StateCreateJust)),
+               pause:         atomic2.NewBool(false),
                prCh:          make(chan PullRequest, 4),
                model:         defaultOpts.ConsumerModel,
                option:        defaultOpts,

Reply via email to