Granted QOS different to Requested QOS

EMQ重新安装后,项目开启的时候报错:

Granted QOS different to Requested QOS; topics: [$SYS/brokers/+/clients/+/connected, $SYS/brokers/+/clients/+/disconnected] requested: [1, 1] granted: [128, 128]

原因大概就是要允许客户端订阅"$SYS/brokers/+/clients/#"主题

此bug困扰两天终于解决!

修改acl.conf文件如下:

{allow, {user, "dashboard"}, subscribe, ["$SYS/#"]}.

{allow, {ipaddr, "127.0.0.1"}, pubsub, ["$SYS/#", "#"]}.

{allow, all, subscribe, ["$SYS/brokers/+/clients/#"]}.

{deny, all, subscribe, ["$SYS/#", {eq, "#"}]}.

{allow, all}.
 

结果心跳主题再次出现,good!

Granted QOS different to Requested QOS