回调通知
This commit is contained in:
parent
d21b849bba
commit
c2b2d52195
|
|
@ -128,8 +128,8 @@ func (w *WechatNotifyConsumer) consumeMessages(ctx context.Context, mqConsumer m
|
||||||
// 长轮询消费消息,网络超时时间默认为35s。
|
// 长轮询消费消息,网络超时时间默认为35s。
|
||||||
// 长轮询表示如果Topic没有消息,则客户端请求会在服务端挂起3s,3s内如果有消息可以消费则立即返回响应。
|
// 长轮询表示如果Topic没有消息,则客户端请求会在服务端挂起3s,3s内如果有消息可以消费则立即返回响应。
|
||||||
mqConsumer.ConsumeMessage(respChan, errChan,
|
mqConsumer.ConsumeMessage(respChan, errChan,
|
||||||
3, // 一次最多消费3条(最多可设置为16条)。
|
3, // 一次最多消费3条(最多可设置为16条)。
|
||||||
5, // 长轮询时间3s(最多可设置为30s)。
|
10, // 长轮询时间3s(最多可设置为30s)。
|
||||||
)
|
)
|
||||||
<-endChan
|
<-endChan
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue