0
我加了MQTT攔截到我的ARTEMIS經紀人爲了攔截MQTT客戶機連接:阿蒂米斯經紀人攔截MQTT客戶機連接
public class SimpleMQTTInterceptor implements MQTTInterceptor
{
@Override
public boolean intercept(final MqttMessage mqttMessage, RemotingConnection connection) throws ActiveMQException
{
System.out.println("MQTT Interceptor gets called ");
if (mqttMessage instanceof MqttConnectMessage)
{
System.out.println("MQTT connection intercepted ");
}
return true;
}
我的客戶阿帕奇泛美衛生組織連接,通過這個接口「WS經紀人://0.0 .0.0:61614" 。
我的問題是,只有發佈到主題的消息被攔截。
爲什麼這不攔截CONNECT消息?