Skip to content

Commit ae3c226

Browse files
authored
fix pop
1 parent 825002f commit ae3c226

File tree

1 file changed

+6
-4
lines changed

1 file changed

+6
-4
lines changed

lib/resty/rocketmq/client.lua

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -649,10 +649,12 @@ function _M:getPopRequest(topic, consumerGroup, extraInfo)
649649
local offset = extraInfoStrs[8]
650650
-- finalOffset popTime invisibleTime reviveQid topicVersion brokerName queueId queueOffset
651651
local realTopic = topic
652-
if topicVersion == 1 then
653-
realTopic = '%RETRY%' .. consumerGroup .. '_' .. topic
654-
elseif topicVersion == 2 then
655-
realTopic = '%RETRY%' .. consumerGroup .. '+' .. topic
652+
if not utils.startsWith(topic, core.RETRY_GROUP_TOPIC_PREFIX) then
653+
if topicVersion == 1 then
654+
realTopic = '%RETRY%' .. consumerGroup .. '_' .. topic
655+
elseif topicVersion == 2 then
656+
realTopic = '%RETRY%' .. consumerGroup .. '+' .. topic
657+
end
656658
end
657659
local brokerAddr = findBrokerAddressInSubscribe(self, brokerName)
658660
if brokerAddr == nil then

0 commit comments

Comments
 (0)