You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@rocketmq.apache.org by "joewong-rf (via GitHub)" <gi...@apache.org> on 2025/07/04 01:34:34 UTC

[I] [Bug] rocketmq5.3.x, 开启 acl 2.0,消费者接收不到消息 [rocketmq]

joewong-rf opened a new issue, #9518:
URL: https://github.com/apache/rocketmq/issues/9518

   ### Before Creating the Bug Report
   
   - [x] I found a bug, not just asking a question, which should be created in [GitHub Discussions](https://github.com/apache/rocketmq/discussions).
   
   - [x] I have searched the [GitHub Issues](https://github.com/apache/rocketmq/issues) and [GitHub Discussions](https://github.com/apache/rocketmq/discussions)  of this repository and believe that this is not a duplicate.
   
   - [x] I have confirmed that this bug belongs to the current repository, not other repositories of RocketMQ.
   
   
   ### Runtime platform environment
   
   OS: Centos7
   容器化部署
   
   ### RocketMQ version
   
   5.3.2、5.3.3
   
   ### JDK Version
   
   openjdk version "1.8.0_452"
   
   ### Describe the Bug
   
   开启 acl2.0 之后,发送者正常发送,消费者无法消费消息
   
   ### Steps to Reproduce
   
   1、Docker 部署 rocketmq,集群模式
   broker.conf 配置文件:
   ![Image](https://github.com/user-attachments/assets/afac41d6-f38c-4bed-b485-0ee10a52b675)
   
   rmq-proxy.json 配置文件
   ![Image](https://github.com/user-attachments/assets/cdc88786-f5d6-41ef-ae7e-e63aefee9327)
   
   2、生产者发送消息
   3、消费者订阅消息
   
   ### What Did You Expect to See?
   
   开启 acl 2.0,消费者正常接收消息
   
   ### What Did You See Instead?
   
   消费者接收不到消息
   
   ### Additional Context
   
   _No response_


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

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


Re: [I] [Bug] rocketmq5.3.x, 开启 acl 2.0,消费者接收不到消息 [rocketmq]

Posted by "JaneYork (via GitHub)" <gi...@apache.org>.
JaneYork commented on issue #9518:
URL: https://github.com/apache/rocketmq/issues/9518#issuecomment-3105860779

   > > 我遇到的也是这个 多网卡情况下 显示的配置公网brokerId 已解决
   > 
   > 请问具体如何配置公网brokerId
   
   brokerIP1=YOUR_PUBLIC_IP
   brokerIP2=rmqbroker
   namesrvAddr=rmqnamesrv:9876


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

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


Re: [I] [Bug] rocketmq5.3.x, 开启 acl 2.0,消费者接收不到消息 [rocketmq]

Posted by "joewong-rf (via GitHub)" <gi...@apache.org>.
joewong-rf commented on issue #9518:
URL: https://github.com/apache/rocketmq/issues/9518#issuecomment-3106089260

   > > > 我遇到的也是这个 多网卡情况下 显示的配置公网brokerId 已解决
   > > 
   > > 
   > > 请问具体如何配置公网brokerId
   > 
   > brokerIP1=YOUR_PUBLIC_IP brokerIP2=rmqbroker namesrvAddr=rmqnamesrv:9876
   
   <img width="904" height="549" alt="Image" src="https://github.com/user-attachments/assets/64fc345b-070e-4d2e-ad1e-1884d0a08499" />
   Linux 虚拟机是网络如上图,但是把 brokerIP1 设置为 192.168.137.128 没用


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

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


Re: [I] [Bug] rocketmq5.3.x, 开启 acl 2.0,消费者接收不到消息 [rocketmq]

Posted by "joewong-rf (via GitHub)" <gi...@apache.org>.
joewong-rf commented on issue #9518:
URL: https://github.com/apache/rocketmq/issues/9518#issuecomment-3105369813

   > 我遇到的也是这个 多网卡情况下 显示的配置公网brokerId 已解决
   
   请问具体如何配置公网brokerId 


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

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


Re: [I] [Bug] rocketmq5.3.x, 开启 acl 2.0,消费者接收不到消息 [rocketmq]

Posted by "joewong-rf (via GitHub)" <gi...@apache.org>.
joewong-rf commented on issue #9518:
URL: https://github.com/apache/rocketmq/issues/9518#issuecomment-3072272299

   _无 acl.yml、proxy.conf 文件,proxy 配置文件为 **rmq-proxy.json**_
   
   [rmq-proxy.json](https://github.com/user-attachments/files/21227265/rmq-proxy.json)
   
   broker.conf (conf 类型文件无法上传,直接把内容贴在这里)
   
   brokerClusterName = DefaultCluster
   brokerName = broker-a
   brokerId = 0
   deleteWhen = 04
   fileReservedTime = 48
   brokerRole = ASYNC_MASTER
   flushDiskType = ASYNC_FLUSH
   ## if acl is open,the flag will be true
   ##aclEnable=true
   authenticationEnabled = true
   authenticationProvider = org.apache.rocketmq.auth.authentication.provider.DefaultAuthenticationProvider
   initAuthenticationUser = {"username":"MultiEnergy","password":"oilfield"}
   innerClientAuthenticationCredentials = {"accessKey":"MultiEnergy","secretKey":"oilfield"}
   authenticationMetadataProvider = org.apache.rocketmq.auth.authentication.provider.LocalAuthenticationMetadataProvider
   authorizationEnabled = true
   authorizationProvider = org.apache.rocketmq.auth.authorization.provider.DefaultAuthorizationProvider
   authorizationMetadataProvider = org.apache.rocketmq.auth.authorization.provider.LocalAuthorizationMetadataProvider
   #migrateAuthFromV1Enabled = true
   


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

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


Re: [I] [Bug] rocketmq5.3.x, 开启 acl 2.0,消费者接收不到消息 [rocketmq]

Posted by "NoeLiYa (via GitHub)" <gi...@apache.org>.
NoeLiYa commented on issue #9518:
URL: https://github.com/apache/rocketmq/issues/9518#issuecomment-3112757399

   > > > > [rocketmqOnly.zip](https://github.com/user-attachments/files/21401831/rocketmqOnly.zip)
   > > > > emmmm我这里也是,有点抽象了,后面发现是没有给挂在的容器设置访问权限,然后我就出现了能发送消息但是没有可以消费的情况,不知道你是不是这种情况 容器内部是只允许rocketmq的用户有访问权限,但是我用容器映射进行绑定挂在的话,容器的权限就变成root了,然后rockemq用户就没有权限写入commitlog的文件取存储消息数据,这时候启动容器后还要给store目录下的允许rockemq用户进行操作 `chmod 777 /home/rocketmq/ -R && chown -R rocketmq:rocketmq /home/rocketmq/logs/ && chown -R rocketmq:rocketmq /home/rocketmq/store/ && ls -ld /home/rocketmq/store/ `
   > > > > 也可能是rmq-proxy需要加这个"enableAclRpcHookForClusterMode": true,选项
   > > > > 或许这个大佬的文章详细的可以给你一点参考https://blog.zcw159357.com/article/1/2025-03-15-0048.html
   > > > > 我的配置文件参考,或许可以帮助到你
   > > > 
   > > > 
   > > > 我没有用容器部署也是出现了这种情况(5.3.x),我用tools.sh测试跑了一下是可以正常发送和消费的(应该是使用remoting协议的客户端)。我用java的Grpc协议sdk,消费者可以正常连接上但是就无法接收到消息,PushConsumer和SimpleConsumer都不行,去掉acl2.0鉴权就没问题。 你现在问题解决了吗?
   > > 
   > > 
   > > 可以参考一下的你的测试用的proxy配置吗,我之前也不行,就加了个这个"enableAclRpcHookForClusterMode": true选项就可以正常调用了,其实我大多是参考这篇文章里写的[https://blog.zcw159357.com/article/1/2025-03-15-0048.html,官方的文档太多标的不详细了,acl2.0除了这篇文章以外其他都没有说明到https://rocketmq-learning.com/learning/rocketmq_learning-acl/,都得debug源码进去看](https://blog.zcw159357.com/article/1/2025-03-15-0048.html%EF%BC%8C%E5%AE%98%E6%96%B9%E7%9A%84%E6%96%87%E6%A1%A3%E5%A4%AA%E5%A4%9A%E6%A0%87%E7%9A%84%E4%B8%8D%E8%AF%A6%E7%BB%86%E4%BA%86%EF%BC%8Cacl2.0%E9%99%A4%E4%BA%86%E8%BF%99%E7%AF%87%E6%96%87%E7%AB%A0%E4%BB%A5%E5%A4%96%E5%85%B6%E4%BB%96%E9%83%BD%E6%B2%A1%E6%9C%89%E8%AF%B4%E6%98%8E%E5%88%B0https://rocketmq-learning.com/learning/rocketmq_learning-acl/,%E9%83%BD%E5%BE%97debug%E6%BA%90%E7%A0%81%E8%BF%9B%E5%8E%BB%E7%9C%8B)
   > > 我的配置在我第一个回复的zip压缩包里,测试的时候正常能跑通,不过没有测过集群,这两天应该会重新用集群部署看看
   > 
   > [rmq-proxy.json](https://github.com/user-attachments/files/21404748/rmq-proxy.json)
   > 
   > 我看了咱们两个的配置几乎是一样的,应该不是配置上的问题,这个大佬的文章我来参考来着,不过没有奏效。
   > 
   > 我这边服务器阿里云的centos6,JDK1.8.0,RMQ3.3.1,除了环境和非容器部署,咱们应该没有什么区别。
   
   我用集群部署的时候重新测试一遍,感觉还是acl2.0的问题,稳定的还是先用1.0吧😂


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

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


Re: [I] [Bug] rocketmq5.3.x, 开启 acl 2.0,消费者接收不到消息 [rocketmq]

Posted by "NoeLiYa (via GitHub)" <gi...@apache.org>.
NoeLiYa commented on issue #9518:
URL: https://github.com/apache/rocketmq/issues/9518#issuecomment-3112232211

   emmmm我这里也是,有点抽象了,后面发现是没有给挂在的容器设置访问权限,然后我就出现了能发送消息但是没有可以消费的情况,不知道你是不是这种情况
   容器内部是只允许rocketmq的用户有访问权限,但是我用容器映射进行绑定挂在的话,容器的权限就变成root了,然后rockemq用户就没有权限写入commitlog的文件取存储消息数据,这时候启动容器后还要给store目录下的允许rockemq用户进行操作
   `chmod 777 /home/rocketmq/ -R && chown -R rocketmq:rocketmq /home/rocketmq/logs/ && chown -R rocketmq:rocketmq /home/rocketmq/store/ && ls -ld /home/rocketmq/store/
   `


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

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


Re: [I] [Bug] rocketmq5.3.x, 开启 acl 2.0,消费者接收不到消息 [rocketmq]

Posted by "dingshuangxi888 (via GitHub)" <gi...@apache.org>.
dingshuangxi888 commented on issue #9518:
URL: https://github.com/apache/rocketmq/issues/9518#issuecomment-3551554079

   > > 客户端有报错日志吗,能否看下日志报什么错误,我这边看下
   > 
   > 客户端没有任何异常,服务端也没有任何异常
   
   我来复现下,你们是怎么访问的,用的什么客户端


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

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


Re: [I] [Bug] rocketmq5.3.x, 开启 acl 2.0,消费者接收不到消息 [rocketmq]

Posted by "TingFeng-Git (via GitHub)" <gi...@apache.org>.
TingFeng-Git commented on issue #9518:
URL: https://github.com/apache/rocketmq/issues/9518#issuecomment-3116849662

   https://github.com/apache/rocketmq/pull/9570


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

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


Re: [I] [Bug] rocketmq5.3.x, 开启 acl 2.0,消费者接收不到消息 [rocketmq]

Posted by "ZongZihao (via GitHub)" <gi...@apache.org>.
ZongZihao commented on issue #9518:
URL: https://github.com/apache/rocketmq/issues/9518#issuecomment-3551536559

   > 客户端有报错日志吗,能否看下日志报什么错误,我这边看下
   
   客户端没有任何异常,服务端也没有任何异常


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

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


Re: [I] [Bug] rocketmq5.3.x, 开启 acl 2.0,消费者接收不到消息 [rocketmq]

Posted by "dingshuangxi888 (via GitHub)" <gi...@apache.org>.
dingshuangxi888 commented on issue #9518:
URL: https://github.com/apache/rocketmq/issues/9518#issuecomment-3555481033

   > > 根因:
   > > 
   > > 1. pop接口要求传递bornTime, 在存算分离架构里面,这个bornTime为了防止proxy和broker的机器出现时钟偏差,所以没有传,让broker自己设置,但是broker上设置的是RemotingCommand#extFields这个值。
   > > 2. 当开启ACL2.0的时候,为了能够获取到POP请求的参数,会提前进行一次deocde,这会导致RemotingCommand#cachedHeader已经缓存了旧值,因此上面的设置是无效的
   > > 3. 消费消息的时候,由于这个bornTime没有正确设置,服务端在计算`System.currentTimeMillis() - bornTime - pollTime > 500`的永远返回true, 就报"the broker[%s] pop message is timeout too much"这个异常,一直拉不到消息
   > > 
   > > 修复方法: bornTime的设置基于decode之后的对象进行设置
   > 
   > > ,你们是怎么访问的,客户端访问的proxy吗,还是broker, 然后用的是remoting客户端还
   > 
   > proxy和broker分离部署,使用gRPC访问proxy, 可以正常发送消息,消息时无法获取消息(POP方式),客户端和服务端proxy,broker均无异常日志。 还有个前提是开启ACL2.0,使用ACL1.0就没有这个问题。 我看到你提的修复了,应该就是bronTime的问题,我纳闷的是这应该是一个影响极大的BUG,尤其是5.3.3只能使用acl2.0的版本,结果反映的人却寥寥无几,官方也没有回应。
   
   大部分的用户,在部署proxy之后,broker不会开启ACL,所以不会有这个问题。


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

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


Re: [I] [Bug] rocketmq5.3.x, 开启 acl 2.0,消费者接收不到消息 [rocketmq]

Posted by "ZongZihao (via GitHub)" <gi...@apache.org>.
ZongZihao commented on issue #9518:
URL: https://github.com/apache/rocketmq/issues/9518#issuecomment-3112743792

   > > > [rocketmqOnly.zip](https://github.com/user-attachments/files/21401831/rocketmqOnly.zip)
   > > > emmmm我这里也是,有点抽象了,后面发现是没有给挂在的容器设置访问权限,然后我就出现了能发送消息但是没有可以消费的情况,不知道你是不是这种情况 容器内部是只允许rocketmq的用户有访问权限,但是我用容器映射进行绑定挂在的话,容器的权限就变成root了,然后rockemq用户就没有权限写入commitlog的文件取存储消息数据,这时候启动容器后还要给store目录下的允许rockemq用户进行操作 `chmod 777 /home/rocketmq/ -R && chown -R rocketmq:rocketmq /home/rocketmq/logs/ && chown -R rocketmq:rocketmq /home/rocketmq/store/ && ls -ld /home/rocketmq/store/ `
   > > > 也可能是rmq-proxy需要加这个"enableAclRpcHookForClusterMode": true,选项
   > > > 或许这个大佬的文章详细的可以给你一点参考https://blog.zcw159357.com/article/1/2025-03-15-0048.html
   > > > 我的配置文件参考,或许可以帮助到你
   > > 
   > > 
   > > 我没有用容器部署也是出现了这种情况(5.3.x),我用tools.sh测试跑了一下是可以正常发送和消费的(应该是使用remoting协议的客户端)。我用java的Grpc协议sdk,消费者可以正常连接上但是就无法接收到消息,PushConsumer和SimpleConsumer都不行,去掉acl2.0鉴权就没问题。 你现在问题解决了吗?
   > 
   > 可以参考一下的你的测试用的proxy配置吗,我之前也不行,就加了个这个"enableAclRpcHookForClusterMode": true选项就可以正常调用了,其实我大多是参考这篇文章里写的[https://blog.zcw159357.com/article/1/2025-03-15-0048.html,官方的文档太多标的不详细了,acl2.0除了这篇文章以外其他都没有说明到https://rocketmq-learning.com/learning/rocketmq_learning-acl/,都得debug源码进去看](https://blog.zcw159357.com/article/1/2025-03-15-0048.html%EF%BC%8C%E5%AE%98%E6%96%B9%E7%9A%84%E6%96%87%E6%A1%A3%E5%A4%AA%E5%A4%9A%E6%A0%87%E7%9A%84%E4%B8%8D%E8%AF%A6%E7%BB%86%E4%BA%86%EF%BC%8Cacl2.0%E9%99%A4%E4%BA%86%E8%BF%99%E7%AF%87%E6%96%87%E7%AB%A0%E4%BB%A5%E5%A4%96%E5%85%B6%E4%BB%96%E9%83%BD%E6%B2%A1%E6%9C%89%E8%AF%B4%E6%98%8E%E5%88%B0https://rocketmq-learning.com/learning/rocketmq_learning-acl/,%E9%83%BD%E5%BE%97debug%E6%BA%90%E7%A0%81%E8%BF%9B%E5%8E%BB%E7%9C%8B)
   > 
   > 我的配置在我第一个回复的zip压缩包里,测试的时候正常能跑通,不过没有测过集群,这两天应该会重新用集群部署看看
   
   [rmq-proxy.json](https://github.com/user-attachments/files/21404748/rmq-proxy.json)
   
   我看了咱们两个的配置几乎是一样的,应该不是配置上的问题,这个大佬的文章我来参考来着,不过没有奏效。
   
   我这边服务器阿里云的centos6,JDK1.8.0,RMQ3.3.1,除了环境和非容器部署,咱们应该没有什么区别。


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

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


Re: [I] [Bug] rocketmq5.3.x, 开启 acl 2.0,消费者接收不到消息 [rocketmq]

Posted by "ZongZihao (via GitHub)" <gi...@apache.org>.
ZongZihao commented on issue #9518:
URL: https://github.com/apache/rocketmq/issues/9518#issuecomment-3116451294

   > mq自身问题,初步定位到原因了,broker判断请求超时,
   
   是在什么特定条件下才能出现么?这种部署方式应该是最常用的方式,要是有这个问题的话,岂不是所有开启的ACL2.0的rocketmq都无法正常消费了。


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

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


Re: [I] [Bug] rocketmq5.3.x, 开启 acl 2.0,消费者接收不到消息 [rocketmq]

Posted by "TingFeng-Git (via GitHub)" <gi...@apache.org>.
TingFeng-Git commented on issue #9518:
URL: https://github.com/apache/rocketmq/issues/9518#issuecomment-3551842165

   > > > 客户端有报错日志吗,能否看下日志报什么错误,我这边看下
   > > 
   > > 
   > > 客户端没有任何异常,服务端也没有任何异常
   > 
   > 我来复现下,你们是怎么访问的,客户端访问的proxy吗,还是broker, 然后用的是remoting客户端还是gRPC客户端
   
   proxy 和 broker 分开部署,均开启认证、授权功能,客户端endpoint连接proxy进行生产消费,通过grpc生产消息能够成功,消费不到消息,印象里通过remoting端口也是同样的问题


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

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


Re: [I] [Bug] rocketmq5.3.x, 开启 acl 2.0,消费者接收不到消息 [rocketmq]

Posted by "ZongZihao (via GitHub)" <gi...@apache.org>.
ZongZihao commented on issue #9518:
URL: https://github.com/apache/rocketmq/issues/9518#issuecomment-3555618009

   > > > 根因:
   > > > 
   > > > 1. pop接口要求传递bornTime, 在存算分离架构里面,这个bornTime为了防止proxy和broker的机器出现时钟偏差,所以没有传,让broker自己设置,但是broker上设置的是RemotingCommand#extFields这个值。
   > > > 2. 当开启ACL2.0的时候,为了能够获取到POP请求的参数,会提前进行一次deocde,这会导致RemotingCommand#cachedHeader已经缓存了旧值,因此上面的设置是无效的
   > > > 3. 消费消息的时候,由于这个bornTime没有正确设置,服务端在计算`System.currentTimeMillis() - bornTime - pollTime > 500`的永远返回true, 就报"the broker[%s] pop message is timeout too much"这个异常,一直拉不到消息
   > > > 
   > > > 修复方法: bornTime的设置基于decode之后的对象进行设置
   > > 
   > > 
   > > > ,你们是怎么访问的,客户端访问的proxy吗,还是broker, 然后用的是remoting客户端还
   > > 
   > > 
   > > proxy和broker分离部署,使用gRPC访问proxy, 可以正常发送消息,消息时无法获取消息(POP方式),客户端和服务端proxy,broker均无异常日志。 还有个前提是开启ACL2.0,使用ACL1.0就没有这个问题。 我看到你提的修复了,应该就是bronTime的问题,我纳闷的是这应该是一个影响极大的BUG,尤其是5.3.3只能使用acl2.0的版本,结果反映的人却寥寥无几,官方也没有回应。
   > 
   > 1. 大部分的用户,在部署proxy之后,broker不会开启ACL,所以不会有这个问题。
   > 2. 最开始发布ACL2.0的时候的版本都是没问题的,后面他们改pop相关逻辑没考虑这个场景
   
   可能大部分人都是内网自己的服务在使用,所以不需要权限控制了。  关键这个acl2.0到现在官方都没有给一个详细的可用文档出来。 还有同问一下proxy开启acl之后, broker就不用开启了么?  这个我好像没有尝试过


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

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


Re: [I] [Bug] rocketmq5.3.x, 开启 acl 2.0,消费者接收不到消息 [rocketmq]

Posted by "lollipopjin (via GitHub)" <gi...@apache.org>.
lollipopjin closed issue #9518: [Bug] rocketmq5.3.x, 开启 acl 2.0,消费者接收不到消息
URL: https://github.com/apache/rocketmq/issues/9518


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

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


Re: [I] [Bug] rocketmq5.3.x, 开启 acl 2.0,消费者接收不到消息 [rocketmq]

Posted by "joewong-rf (via GitHub)" <gi...@apache.org>.
joewong-rf commented on issue #9518:
URL: https://github.com/apache/rocketmq/issues/9518#issuecomment-3083120481

   目前还没有解决


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

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


Re: [I] [Bug] rocketmq5.3.x, 开启 acl 2.0,消费者接收不到消息 [rocketmq]

Posted by "joewong-rf (via GitHub)" <gi...@apache.org>.
joewong-rf commented on issue #9518:
URL: https://github.com/apache/rocketmq/issues/9518#issuecomment-3116829285

   > [rocketmqOnly.zip](https://github.com/user-attachments/files/21401831/rocketmqOnly.zip)
   > 
   > emmmm我这里也是,有点抽象了,后面发现是没有给挂在的容器设置访问权限,然后我就出现了能发送消息但是没有可以消费的情况,不知道你是不是这种情况 容器内部是只允许rocketmq的用户有访问权限,但是我用容器映射进行绑定挂在的话,容器的权限就变成root了,然后rockemq用户就没有权限写入commitlog的文件取存储消息数据,这时候启动容器后还要给store目录下的允许rockemq用户进行操作 `chmod 777 /home/rocketmq/ -R && chown -R rocketmq:rocketmq /home/rocketmq/logs/ && chown -R rocketmq:rocketmq /home/rocketmq/store/ && ls -ld /home/rocketmq/store/ `
   > 
   > 也可能是rmq-proxy需要加这个"enableAclRpcHookForClusterMode": true,选项
   > 
   > 或许这个大佬的文章详细的可以给你一点参考https://blog.zcw159357.com/article/1/2025-03-15-0048.html
   > 
   > 我的配置文件参考,或许可以帮助到你
   
   参考配置测试之后,依然不可以消费消息


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

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


Re: [I] [Bug] rocketmq5.3.x, 开启 acl 2.0,消费者接收不到消息 [rocketmq]

Posted by "syyfs (via GitHub)" <gi...@apache.org>.
syyfs commented on issue #9518:
URL: https://github.com/apache/rocketmq/issues/9518#issuecomment-3126480139

   > [rocketmqOnly.zip](https://github.com/user-attachments/files/21401831/rocketmqOnly.zip)
   > 
   > emmmm我这里也是,有点抽象了,后面发现是没有给挂在的容器设置访问权限,然后我就出现了能发送消息但是没有可以消费的情况,不知道你是不是这种情况 容器内部是只允许rocketmq的用户有访问权限,但是我用容器映射进行绑定挂在的话,容器的权限就变成root了,然后rockemq用户就没有权限写入commitlog的文件取存储消息数据,这时候启动容器后还要给store目录下的允许rockemq用户进行操作 `chmod 777 /home/rocketmq/ -R && chown -R rocketmq:rocketmq /home/rocketmq/logs/ && chown -R rocketmq:rocketmq /home/rocketmq/store/ && ls -ld /home/rocketmq/store/ `
   > 
   > 也可能是rmq-proxy需要加这个"enableAclRpcHookForClusterMode": true,选项
   > 
   > 或许这个大佬的文章详细的可以给你一点参考https://blog.zcw159357.com/article/1/2025-03-15-0048.html
   > 
   > 我的配置文件参考,或许可以帮助到你
   
   你好,请问一下使用docker部署rocketmq5.3.3版本服务集群,你的宿主机是什么操作系统?容器中使用的是rocketmq用户,如果挂载broker的store目录,执行容器内部授权操作之后,启动服务的时候挂载的store中新增的文件权限还是无法生效?报错:java.lang.RuntimeException: Failed to load the authentication metadata provider
   	at org.apache.rocketmq.auth.authentication.factory.AuthenticationFactory.lambda$getMetadataProvider$1(AuthenticationFactory.java:89)
   	at org.apache.rocketmq.auth.authentication.factory.AuthenticationFactory.computeIfAbsent(AuthenticationFactory.java:144)
   	at org.apache.rocketmq.auth.authentication.factory.AuthenticationFactory.getMetadataProvider(AuthenticationFactory.java:78)
   	at org.apache.rocketmq.auth.authentication.factory.AuthenticationFactory.getMetadataProvider(AuthenticationFactory.java:66)
   	at org.apache.rocketmq.auth.authentication.manager.AuthenticationMetadataManagerImpl.<init>(AuthenticationMetadataManagerImpl.java:42)
   	at org.apache.rocketmq.auth.authentication.factory.AuthenticationFactory.getMetadataManager(AuthenticationFactory.java:70)
   	at org.apache.rocketmq.broker.BrokerController.<init>(BrokerController.java:362)
   	at org.apache.rocketmq.broker.BrokerStartup.buildBrokerController(BrokerStartup.java:215)
   	at org.apache.rocketmq.broker.BrokerStartup.createBrokerController(BrokerStartup.java:247)
   	at org.apache.rocketmq.broker.BrokerStartup.main(BrokerStartup.java:52)
   Caused by: java.lang.RuntimeException: Failed to load rocksdb for auth_user, please check whether it is occupied
   	at org.apache.rocketmq.auth.authentication.provider.LocalAuthenticationMetadataProvider.initialize(LocalAuthenticationMetadataProvider.java:50)
   	at org.apache.rocketmq.auth.authentication.factory.AuthenticationFactory.lambda$getMetadataProvider$1(AuthenticationFactory.java:86)
   	... 9 more


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

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


Re: [I] [Bug] rocketmq5.3.x, 开启 acl 2.0,消费者接收不到消息 [rocketmq]

Posted by "dingshuangxi888 (via GitHub)" <gi...@apache.org>.
dingshuangxi888 commented on issue #9518:
URL: https://github.com/apache/rocketmq/issues/9518#issuecomment-3551526445

   客户端有报错日志吗,能否看下日志报什么错误,我这边看下


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

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


Re: [I] [Bug] rocketmq5.3.x, 开启 acl 2.0,消费者接收不到消息 [rocketmq]

Posted by "ZongZihao (via GitHub)" <gi...@apache.org>.
ZongZihao commented on issue #9518:
URL: https://github.com/apache/rocketmq/issues/9518#issuecomment-3116418947

   > > > > > [rocketmqOnly.zip](https://github.com/user-attachments/files/21401831/rocketmqOnly.zip)
   > > > > > emmmm我这里也是,有点抽象了,后面发现是没有给挂在的容器设置访问权限,然后我就出现了能发送消息但是没有可以消费的情况,不知道你是不是这种情况 容器内部是只允许rocketmq的用户有访问权限,但是我用容器映射进行绑定挂在的话,容器的权限就变成root了,然后rockemq用户就没有权限写入commitlog的文件取存储消息数据,这时候启动容器后还要给store目录下的允许rockemq用户进行操作 `chmod 777 /home/rocketmq/ -R && chown -R rocketmq:rocketmq /home/rocketmq/logs/ && chown -R rocketmq:rocketmq /home/rocketmq/store/ && ls -ld /home/rocketmq/store/ `
   > > > > > 也可能是rmq-proxy需要加这个"enableAclRpcHookForClusterMode": true,选项
   > > > > > 或许这个大佬的文章详细的可以给你一点参考https://blog.zcw159357.com/article/1/2025-03-15-0048.html
   > > > > > 我的配置文件参考,或许可以帮助到你
   > > > > 
   > > > > 
   > > > > 我没有用容器部署也是出现了这种情况(5.3.x),我用tools.sh测试跑了一下是可以正常发送和消费的(应该是使用remoting协议的客户端)。我用java的Grpc协议sdk,消费者可以正常连接上但是就无法接收到消息,PushConsumer和SimpleConsumer都不行,去掉acl2.0鉴权就没问题。 你现在问题解决了吗?
   > > > 
   > > > 
   > > > 可以参考一下的你的测试用的proxy配置吗,我之前也不行,就加了个这个"enableAclRpcHookForClusterMode": true选项就可以正常调用了,其实我大多是参考这篇文章里写的[https://blog.zcw159357.com/article/1/2025-03-15-0048.html,官方的文档太多标的不详细了,acl2.0除了这篇文章以外其他都没有说明到https://rocketmq-learning.com/learning/rocketmq_learning-acl/,都得debug源码进去看](https://blog.zcw159357.com/article/1/2025-03-15-0048.html%EF%BC%8C%E5%AE%98%E6%96%B9%E7%9A%84%E6%96%87%E6%A1%A3%E5%A4%AA%E5%A4%9A%E6%A0%87%E7%9A%84%E4%B8%8D%E8%AF%A6%E7%BB%86%E4%BA%86%EF%BC%8Cacl2.0%E9%99%A4%E4%BA%86%E8%BF%99%E7%AF%87%E6%96%87%E7%AB%A0%E4%BB%A5%E5%A4%96%E5%85%B6%E4%BB%96%E9%83%BD%E6%B2%A1%E6%9C%89%E8%AF%B4%E6%98%8E%E5%88%B0https://rocketmq-learning.com/learning/rocketmq_learning-acl/,%E9%83%BD%E5%BE%97debug%E6%BA%90%E7%A0%81%E8%BF%9B%E5%8E%BB%E7%9C%8B)
   > > > 我的配置在我第一个回复的zip压缩包里,测试的时候正常能跑通,不过没有测过集群,这两天应该会重新用集群部署看看
   > > 
   > > 
   > > [rmq-proxy.json](https://github.com/user-attachments/files/21404748/rmq-proxy.json)
   > > 我看了咱们两个的配置几乎是一样的,应该不是配置上的问题,这个大佬的文章我来参考来着,不过没有奏效。
   > > 我这边服务器阿里云的centos6,JDK1.8.0,RMQ3.3.1,除了环境和非容器部署,咱们应该没有什么区别。
   > 
   > 我用集群部署的时候重新测试一遍,感觉还是acl2.0的问题,稳定的还是先用1.0吧😂
   
   我实际上也没有集群,也是1broker+1proxy分开部署,你现在是打开acl2.0的情况下可以正常消费了么?  我在服务器和macos系统都尝试部署但是都是无法正常消费。  auth-audit.log显示acl已经放行,rocketmq-client.log也能正常显示消费者已经注册并且有正常的心跳记录,可是消息就是接收不到。


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

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


Re: [I] [Bug] rocketmq5.3.x, 开启 acl 2.0,消费者接收不到消息 [rocketmq]

Posted by "ZongZihao (via GitHub)" <gi...@apache.org>.
ZongZihao commented on issue #9518:
URL: https://github.com/apache/rocketmq/issues/9518#issuecomment-3112441437

   > [rocketmqOnly.zip](https://github.com/user-attachments/files/21401831/rocketmqOnly.zip)
   > 
   > emmmm我这里也是,有点抽象了,后面发现是没有给挂在的容器设置访问权限,然后我就出现了能发送消息但是没有可以消费的情况,不知道你是不是这种情况 容器内部是只允许rocketmq的用户有访问权限,但是我用容器映射进行绑定挂在的话,容器的权限就变成root了,然后rockemq用户就没有权限写入commitlog的文件取存储消息数据,这时候启动容器后还要给store目录下的允许rockemq用户进行操作 `chmod 777 /home/rocketmq/ -R && chown -R rocketmq:rocketmq /home/rocketmq/logs/ && chown -R rocketmq:rocketmq /home/rocketmq/store/ && ls -ld /home/rocketmq/store/ `
   > 
   > 也可能是rmq-proxy需要加这个"enableAclRpcHookForClusterMode": true,选项
   > 
   > 或许这个大佬的文章详细的可以给你一点参考https://blog.zcw159357.com/article/1/2025-03-15-0048.html
   > 
   > 我的配置文件参考,或许可以帮助到你
   
   我没有用容器部署也是出现了这种情况(5.3.x),我用tools.sh测试跑了一下是可以正常发送和消费的(应该是使用remoting协议的客户端)。我用java的Grpc协议sdk,消费者可以正常连接上但是就无法接收到消息,PushConsumer和SimpleConsumer都不行,去掉acl2.0鉴权就没问题。  你现在问题解决了吗?


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

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


Re: [I] [Bug] rocketmq5.3.x, 开启 acl 2.0,消费者接收不到消息 [rocketmq]

Posted by "isy09945 (via GitHub)" <gi...@apache.org>.
isy09945 commented on issue #9518:
URL: https://github.com/apache/rocketmq/issues/9518#issuecomment-3103622874

   我遇到的也是这个 多网卡情况下 显示的配置公网brokerId 已解决


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

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


Re: [I] [Bug] rocketmq5.3.x, 开启 acl 2.0,消费者接收不到消息 [rocketmq]

Posted by "JaneYork (via GitHub)" <gi...@apache.org>.
JaneYork commented on issue #9518:
URL: https://github.com/apache/rocketmq/issues/9518#issuecomment-3072110015

   麻烦提供下 broker.conf,proxy.conf,acl.yaml


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

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


Re: [I] [Bug] rocketmq5.3.x, 开启 acl 2.0,消费者接收不到消息 [rocketmq]

Posted by "dingshuangxi888 (via GitHub)" <gi...@apache.org>.
dingshuangxi888 commented on issue #9518:
URL: https://github.com/apache/rocketmq/issues/9518#issuecomment-3552340074

   I have identified the root cause of this issue and fixed it. Please refer to:https://github.com/apache/rocketmq/pull/9863


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

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


Re: [I] [Bug] rocketmq5.3.x, 开启 acl 2.0,消费者接收不到消息 [rocketmq]

Posted by "NoeLiYa (via GitHub)" <gi...@apache.org>.
NoeLiYa commented on issue #9518:
URL: https://github.com/apache/rocketmq/issues/9518#issuecomment-3112675395

   > > [rocketmqOnly.zip](https://github.com/user-attachments/files/21401831/rocketmqOnly.zip)
   > > emmmm我这里也是,有点抽象了,后面发现是没有给挂在的容器设置访问权限,然后我就出现了能发送消息但是没有可以消费的情况,不知道你是不是这种情况 容器内部是只允许rocketmq的用户有访问权限,但是我用容器映射进行绑定挂在的话,容器的权限就变成root了,然后rockemq用户就没有权限写入commitlog的文件取存储消息数据,这时候启动容器后还要给store目录下的允许rockemq用户进行操作 `chmod 777 /home/rocketmq/ -R && chown -R rocketmq:rocketmq /home/rocketmq/logs/ && chown -R rocketmq:rocketmq /home/rocketmq/store/ && ls -ld /home/rocketmq/store/ `
   > > 也可能是rmq-proxy需要加这个"enableAclRpcHookForClusterMode": true,选项
   > > 或许这个大佬的文章详细的可以给你一点参考https://blog.zcw159357.com/article/1/2025-03-15-0048.html
   > > 我的配置文件参考,或许可以帮助到你
   > 
   > 我没有用容器部署也是出现了这种情况(5.3.x),我用tools.sh测试跑了一下是可以正常发送和消费的(应该是使用remoting协议的客户端)。我用java的Grpc协议sdk,消费者可以正常连接上但是就无法接收到消息,PushConsumer和SimpleConsumer都不行,去掉acl2.0鉴权就没问题。 你现在问题解决了吗?
   
   可以参考一下的你的测试用的proxy配置吗,我之前也不行,就加了个这个"enableAclRpcHookForClusterMode": true选项就可以正常调用了,其实我大多是参考这篇文章里写的https://blog.zcw159357.com/article/1/2025-03-15-0048.html,官方的文档太多标的不详细了,acl2.0除了这篇文章以外其他都没有说明到https://rocketmq-learning.com/learning/rocketmq_learning-acl/,都得debug源码进去看


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

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


Re: [I] [Bug] rocketmq5.3.x, 开启 acl 2.0,消费者接收不到消息 [rocketmq]

Posted by "TingFeng-Git (via GitHub)" <gi...@apache.org>.
TingFeng-Git commented on issue #9518:
URL: https://github.com/apache/rocketmq/issues/9518#issuecomment-3116442566

   应该是mq自身问题,初步定位到原因了,broker判断请求超时,返回timeout
   
   ---原始邮件---
   发件人: ***@***.***&gt;
   发送时间: 2025年7月25日(周五) 中午1:14
   收件人: ***@***.***&gt;;
   抄送: ***@***.******@***.***&gt;;
   主题: Re: [apache/rocketmq] [Bug] rocketmq5.3.x, 开启 acl 2.0,消费者接收不到消息 (Issue #9518)
   
   
   ZongZihao left a comment (apache/rocketmq#9518)
         
   rocketmqOnly.zip
    emmmm我这里也是,有点抽象了,后面发现是没有给挂在的容器设置访问权限,然后我就出现了能发送消息但是没有可以消费的情况,不知道你是不是这种情况 容器内部是只允许rocketmq的用户有访问权限,但是我用容器映射进行绑定挂在的话,容器的权限就变成root了,然后rockemq用户就没有权限写入commitlog的文件取存储消息数据,这时候启动容器后还要给store目录下的允许rockemq用户进行操作 chmod 777 /home/rocketmq/ -R &amp;&amp; chown -R rocketmq:rocketmq /home/rocketmq/logs/ &amp;&amp; chown -R rocketmq:rocketmq /home/rocketmq/store/ &amp;&amp; ls -ld /home/rocketmq/store/ 
    也可能是rmq-proxy需要加这个"enableAclRpcHookForClusterMode": true,选项
    或许这个大佬的文章详细的可以给你一点参考https://blog.zcw159357.com/article/1/2025-03-15-0048.html
    我的配置文件参考,或许可以帮助到你
     
   我没有用容器部署也是出现了这种情况(5.3.x),我用tools.sh测试跑了一下是可以正常发送和消费的(应该是使用remoting协议的客户端)。我用java的Grpc协议sdk,消费者可以正常连接上但是就无法接收到消息,PushConsumer和SimpleConsumer都不行,去掉acl2.0鉴权就没问题。 你现在问题解决了吗?
     
   可以参考一下的你的测试用的proxy配置吗,我之前也不行,就加了个这个"enableAclRpcHookForClusterMode": true选项就可以正常调用了,其实我大多是参考这篇文章里写的https://blog.zcw159357.com/article/1/2025-03-15-0048.html,官方的文档太多标的不详细了,acl2.0除了这篇文章以外其他都没有说明到https://rocketmq-learning.com/learning/rocketmq_learning-acl/,都得debug源码进去看
    我的配置在我第一个回复的zip压缩包里,测试的时候正常能跑通,不过没有测过集群,这两天应该会重新用集群部署看看
     
   rmq-proxy.json
    我看了咱们两个的配置几乎是一样的,应该不是配置上的问题,这个大佬的文章我来参考来着,不过没有奏效。
    我这边服务器阿里云的centos6,JDK1.8.0,RMQ3.3.1,除了环境和非容器部署,咱们应该没有什么区别。
     
   我用集群部署的时候重新测试一遍,感觉还是acl2.0的问题,稳定的还是先用1.0吧😂
     
   我实际上也没有集群,也是1broker+1proxy分开部署,你现在是打开acl2.0的情况下可以正常消费了么?  我在服务器和macos系统都尝试部署但是都是无法正常消费。  auth-audit.log显示acl已经放行,rocketmq-client.log也能正常显示消费者已经注册并且有正常的心跳记录,可是消息就是接收不到。
    
   —
   Reply to this email directly, view it on GitHub, or unsubscribe.
   You are receiving this because you commented.Message ID: ***@***.***&gt;


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

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


Re: [I] [Bug] rocketmq5.3.x, 开启 acl 2.0,消费者接收不到消息 [rocketmq]

Posted by "TingFeng-Git (via GitHub)" <gi...@apache.org>.
TingFeng-Git commented on issue #9518:
URL: https://github.com/apache/rocketmq/issues/9518#issuecomment-3083080529

   你好,我在开启了ACL2.0,通过代码连接proxy的grpc端口,代码中使用的用户是Super权限用户,同样遇到了无法消费的情况,当我关闭授权后,则可以正常消费,使用的依赖是rocketmq-client 5.3.0请问这个问题是否有解决
   
   


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

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


Re: [I] [Bug] rocketmq5.3.x, 开启 acl 2.0,消费者接收不到消息 [rocketmq]

Posted by "ZongZihao (via GitHub)" <gi...@apache.org>.
ZongZihao commented on issue #9518:
URL: https://github.com/apache/rocketmq/issues/9518#issuecomment-3555393461

   > 根因:
   > 
   > 1. pop接口要求传递bornTime, 在存算分离架构里面,这个bornTime为了防止proxy和broker的机器出现时钟偏差,所以没有传,让broker自己设置,但是broker上设置的是RemotingCommand#extFields这个值。
   > 2. 当开启ACL2.0的时候,为了能够获取到POP请求的参数,会提前进行一次deocde,这会导致RemotingCommand#cachedHeader已经缓存了旧值,因此上面的设置是无效的
   > 3. 消费消息的时候,由于这个bornTime没有正确设置,服务端在计算`System.currentTimeMillis() - bornTime - pollTime > 500`的永远返回true, 就报"the broker[%s] pop message is timeout too much"这个异常,一直拉不到消息
   > 
   > 修复方法: bornTime的设置基于decode之后的对象进行设置
   
   
   
   > ,你们是怎么访问的,客户端访问的proxy吗,还是broker, 然后用的是remoting客户端还
   
   proxy和broker分离部署,使用gRPC访问proxy, 可以正常发送消息,消息时无法获取消息(POP方式),客户端和服务端proxy,broker均无异常日志。   还有个前提是开启ACL2.0,使用ACL1.0就没有这个问题。    我看到你提的修复了,应该就是bronTime的问题,我纳闷的是这应该是一个影响极大的BUG,尤其是5.3.3只能使用acl2.0的版本,结果反映的人却寥寥无几,官方也没有回应。


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

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


Re: [I] [Bug] rocketmq5.3.x, 开启 acl 2.0,消费者接收不到消息 [rocketmq]

Posted by "dingshuangxi888 (via GitHub)" <gi...@apache.org>.
dingshuangxi888 commented on issue #9518:
URL: https://github.com/apache/rocketmq/issues/9518#issuecomment-3556085788

   > > > > 根因:
   > > > > 
   > > > > 1. pop接口要求传递bornTime, 在存算分离架构里面,这个bornTime为了防止proxy和broker的机器出现时钟偏差,所以没有传,让broker自己设置,但是broker上设置的是RemotingCommand#extFields这个值。
   > > > > 2. 当开启ACL2.0的时候,为了能够获取到POP请求的参数,会提前进行一次deocde,这会导致RemotingCommand#cachedHeader已经缓存了旧值,因此上面的设置是无效的
   > > > > 3. 消费消息的时候,由于这个bornTime没有正确设置,服务端在计算`System.currentTimeMillis() - bornTime - pollTime > 500`的永远返回true, 就报"the broker[%s] pop message is timeout too much"这个异常,一直拉不到消息
   > > > > 
   > > > > 修复方法: bornTime的设置基于decode之后的对象进行设置
   > > > 
   > > > 
   > > > > ,你们是怎么访问的,客户端访问的proxy吗,还是broker, 然后用的是remoting客户端还
   > > > 
   > > > 
   > > > proxy和broker分离部署,使用gRPC访问proxy, 可以正常发送消息,消息时无法获取消息(POP方式),客户端和服务端proxy,broker均无异常日志。 还有个前提是开启ACL2.0,使用ACL1.0就没有这个问题。 我看到你提的修复了,应该就是bronTime的问题,我纳闷的是这应该是一个影响极大的BUG,尤其是5.3.3只能使用acl2.0的版本,结果反映的人却寥寥无几,官方也没有回应。
   > > 
   > > 
   > > 
   > > 1. 大部分的用户,在部署proxy之后,broker不会开启ACL,所以不会有这个问题。
   > > 2. 最开始发布ACL2.0的时候的版本都是没问题的,后面他们改pop相关逻辑没考虑这个场景
   > 
   > 可能大部分人都是内网自己的服务在使用,所以不需要权限控制了。 关键这个acl2.0到现在官方都没有给一个详细的可用文档出来。 还有同问一下proxy开启acl之后, broker就不用开启了么? 这个我好像没有尝试过
   
   只要broker不直接对外提供服务,就不需要开启,只需要作为User和ACL元数据存储即可。


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

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


Re: [I] [Bug] rocketmq5.3.x, 开启 acl 2.0,消费者接收不到消息 [rocketmq]

Posted by "dingshuangxi888 (via GitHub)" <gi...@apache.org>.
dingshuangxi888 commented on issue #9518:
URL: https://github.com/apache/rocketmq/issues/9518#issuecomment-3552377797

   根因:
   1. pop接口要求传递bornTime, 在存算分离架构里面,这个bornTime为了防止proxy和broker的机器出现时钟偏差,所以没有传,让broker自己设置,但是broker上设置的是RemotingCommand#extFields这个值。
   2. 当开启ACL2.0的时候,为了能够获取到POP请求的参数,会提前进行一次deocde,这会导致RemotingCommand#cachedHeader已经缓存了旧值,因此上面的设置是无效的
   
   修复方法:
   bornTime的设置基于decode之后的对象进行设置


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

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


Re: [I] [Bug] rocketmq5.3.x, 开启 acl 2.0,消费者接收不到消息 [rocketmq]

Posted by "TingFeng-Git (via GitHub)" <gi...@apache.org>.
TingFeng-Git commented on issue #9518:
URL: https://github.com/apache/rocketmq/issues/9518#issuecomment-3555610945

   所以若想使用acl2.0,其实只用在proxy中设置认证授权即可?broker不用开启是嘛
   
   
   
   ---原始邮件---
   发件人: ***@***.***&gt;
   发送时间: 2025年11月20日(周四) 上午10:21
   收件人: ***@***.***&gt;;
   抄送: ***@***.******@***.***&gt;;
   主题: Re: [apache/rocketmq] [Bug] rocketmq5.3.x, 开启 acl 2.0,消费者接收不到消息 (Issue #9518)
   
   
   dingshuangxi888 left a comment (apache/rocketmq#9518)
      
   根因:
     
   pop接口要求传递bornTime, 在存算分离架构里面,这个bornTime为了防止proxy和broker的机器出现时钟偏差,所以没有传,让broker自己设置,但是broker上设置的是RemotingCommand#extFields这个值。
    
   当开启ACL2.0的时候,为了能够获取到POP请求的参数,会提前进行一次deocde,这会导致RemotingCommand#cachedHeader已经缓存了旧值,因此上面的设置是无效的
    
   消费消息的时候,由于这个bornTime没有正确设置,服务端在计算System.currentTimeMillis() - bornTime - pollTime &gt; 500的永远返回true, 就报"the broker[%s] pop message is timeout too much"这个异常,一直拉不到消息
     
   修复方法: bornTime的设置基于decode之后的对象进行设置
      
   ,你们是怎么访问的,客户端访问的proxy吗,还是broker, 然后用的是remoting客户端还
     
   proxy和broker分离部署,使用gRPC访问proxy, 可以正常发送消息,消息时无法获取消息(POP方式),客户端和服务端proxy,broker均无异常日志。 还有个前提是开启ACL2.0,使用ACL1.0就没有这个问题。 我看到你提的修复了,应该就是bronTime的问题,我纳闷的是这应该是一个影响极大的BUG,尤其是5.3.3只能使用acl2.0的版本,结果反映的人却寥寥无几,官方也没有回应。
     
   大部分的用户,在部署proxy之后,broker不会开启ACL,所以不会有这个问题。
    
   —
   Reply to this email directly, view it on GitHub, or unsubscribe.
   You are receiving this because you commented.Message ID: ***@***.***&gt;


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

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