ender.an27
ender.an27

Reputation: 723

Paho client Timed out as no activity

I'm having the following error message my application using paho client. After this error the client stop receiving messages. Not sure though, but I think I'm still able to publish messages.

o.e.p.c.mqttv3.internal.ClientState      : 106ed26f-74f8-4048-9035-cb9146e35c7c:67c62857-af3c-4aa0-9f28-3f4db6baf811: Timed out as no activity, keepAlive=60,000 lastOutboundActivity=1,446,124,817,035 lastInboundActivity=1,446,124,826,676 time=1,446,124,936,865 lastPing=1,446,124,784,576

I have found some other discussion with this problem, but mostly they are not using paho client instead they are using libs that are using the paho client. All discussions I have found agreed that the problem is related to paho, but no solution is given. It seems that the error happens when the machine is getting out of resources. It seems to be a deadlock.

I'm using paho 1.0.0. Anyhow, this errors had been reported in paho 0.4.0 too.

any idea?

References: Spring Integration MQTT Subscriber (paho) stops processing messages https://github.com/openhab/openhab/issues/980

Upvotes: 5

Views: 4513

Answers (1)

user76720
user76720

Reputation: 26

I find some information from this page https://www.eclipse.org/forums/index.php/t/1069297/ publish code like this:

        MqttTopic mqttTopic =  client.getTopic(topic);
        mqttTopic.publish(message.getBytes(), 0, false);

Upvotes: 1

Related Questions