Hi @J-N-K. Thanks for replay
I think, it may be a cause. I publish commands via:
val GetCommandJSON = [ String command |
String::format("{\"command\":\"%s\",\"time\":%d,\"initiator\":\"localApp\"}", command, now.millis / 1000)
]
rule "RoombaCleanStartReceivedCommand"
when
Item RoombaCleanStart received command ON
then
val roomba = getActions("mqtt", "mqtt:broker:roomba")
if(roomba !== null) {
roomba.publishMQTT("cmd", GetCommandJSON.apply("start"))
} else {
logWarn("RoombaBroker", "Roomba broker returned no actions")
}
end
I will setup HiveMQ CLI next days to be more precise where the error may be.
EDIT: Hello @J-N-K,
small update: I’ve created an command channel as
Type string : command "Command" [ commandTopic = "cmd" ]
as well item
String RoombaSendCommand "Roomba Command [%s]" { channel="mqtt:topic:roomba:state:command" }
and modified a rule to
rule "RoombaCleanStartReceivedCommand"
when
Item RoombaCleanStart received command ON
then
val cmd = String::format("{\"command\":\"start\",\"time\":%d,\"initiator\":\"localApp\"}", now.millis / 1000);
RoombaSendCommand.sendCommand(cmd);
logInfo("RoombaCleanStartReceivedCommand", cmd);
end
Now the situation is a little bit different: It happen still nothing, but there is no error message in log anymore. Trying to send something with publishMQTT, leads immediatly in
com.hivemq.client.mqtt.exceptions.MqttSessionExpiredException
I think, we have a bug in actions.
Kind regards,
Alexander