You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@rocketmq.apache.org by GitBox <gi...@apache.org> on 2022/07/11 08:40:41 UTC

[GitHub] [rocketmq] Oliverwqcwrw opened a new issue, #4581: Maybe it can put same MessageQueue

Oliverwqcwrw opened a new issue, #4581:
URL: https://github.com/apache/rocketmq/issues/4581

   
   
   **BUG REPORT**
   
   1. Please describe the issue you observed:
   
   In `org.apache.rocketmq.broker.transaction.queue.TransactionalMessageServiceImpl#getOpQueue`
   
   > private MessageQueue getOpQueue(MessageQueue messageQueue) {
           MessageQueue opQueue = opQueueMap.get(messageQueue);
           if (opQueue == null) {
               opQueue = new MessageQueue(TransactionalMessageUtil.buildOpTopic(), messageQueue.getBrokerName(),
                   messageQueue.getQueueId());
               opQueueMap.putIfAbsent(messageQueue, opQueue);
           }
           return opQueue;
   
       }
   
   When multiple threads execute getOpQueue() concurrently, maybe it can put same MessageQueue
   
   - What did you do (The steps to reproduce)?
   
   - What is expected to see?
   
   - What did you see instead?
   
   3. Please tell us about your environment:
   
   4. Other information (e.g. detailed explanation, logs, related issues, suggestions on how to fix, etc):
   
   


-- 
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: dev-unsubscribe@rocketmq.apache.org.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [rocketmq] lizhiboo commented on issue #4581: Maybe it can put same MessageQueue

Posted by GitBox <gi...@apache.org>.
lizhiboo commented on issue #4581:
URL: https://github.com/apache/rocketmq/issues/4581#issuecomment-1181211213

   @Oliverwqcwrw It seems that TransactionalMessageServiceImpl.check() is only called by TransactionalMessageCheckService, and TransactionalMessageCheckService is a scheduled task. Maybe no need to concern concurrency problem.


-- 
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: dev-unsubscribe@rocketmq.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [rocketmq] Oliverwqcwrw commented on issue #4581: Maybe it can put same MessageQueue

Posted by GitBox <gi...@apache.org>.
Oliverwqcwrw commented on issue #4581:
URL: https://github.com/apache/rocketmq/issues/4581#issuecomment-1183853072

   Thanks for your reply,
   Agree with, it do not need to concern about concurrency problem now,  But we can avoid some unpredictable problems if we have multithreaded calls in the future


-- 
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: dev-unsubscribe@rocketmq.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [rocketmq] Oliverwqcwrw closed issue #4581: Maybe it can put same MessageQueue

Posted by GitBox <gi...@apache.org>.
Oliverwqcwrw closed issue #4581: Maybe it can put same MessageQueue
URL: https://github.com/apache/rocketmq/issues/4581


-- 
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: dev-unsubscribe@rocketmq.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org