Open
Description
Trying to publish messages with MQTT activity hangs after the first completion.
2020-01-28T16:54:20.010+0100 DEBUG [flogo.activity.mqtt] - Applying InputMapper
2020-01-28T16:54:20.010+0100 DEBUG [flogo.activity.mqtt] - Published Message: {"message":"Hello World"}
2020-01-28T16:54:20.010+0100 DEBUG [flogo.activity.mqtt] - Applying OutputMapper
2020-01-28T16:54:20.010+0100 DEBUG [flogo.flow] - Task 'mqtt_3' is done
2020-01-28T16:54:20.010+0100 DEBUG [flogo.flow] - Notifying flow that end task 'mqtt_3' is done
2020-01-28T16:54:20.010+0100 DEBUG [flogo.flow] - Checking if all tasks done or skipped
2020-01-28T16:54:20.010+0100 DEBUG [flogo.flow] - All tasks done or skipped
2020-01-28T16:54:20.010+0100 DEBUG [flogo.flow] - Flow Done
2020-01-28T16:54:20.010+0100 DEBUG [flogo.flow] - Done Executing flow instance [a008dc42525a066c4a0785dba93a6109] - Status: 500
2020-01-28T16:54:20.010+0100 INFO [flogo.flow] - Instance [a008dc42525a066c4a0785dba93a6109] Done
2020-01-28T16:54:20.010+0100 DEBUG [flogo] - Action-Worker-1: Received result: &runner.ActionResult{results:map[string]interface {}{}, err:error(nil)}
2020-01-28T16:54:20.010+0100 DEBUG [flogo] - Action-Worker-1: Completed Request
2020-01-28T16:54:20.010+0100 DEBUG [flogo] - Action 'github.com/project-flogo/flow' returned
Example Flow:
{
"name": "Edge",
"type": "flogo:app",
"version": "0.0.1",
"appModel": "1.1.0",
"description": "Edge Metrics MQTT",
"imports": [
"github.com/project-flogo/contrib/activity/log",
"github.com/project-flogo/edge-contrib/trigger/mqtt",
"github.com/project-flogo/flow",
"mqtt_1 github.com/project-flogo/edge-contrib/activity/mqtt"
],
"triggers": [
{
"id": "receive_mqtt_message",
"ref": "#mqtt",
"name": "Receive MQTT Message",
"description": "Simple MQTT Trigger",
"settings": {
"broker": "tcp://localhost:1883",
"id": "mqtt_subscribe",
"cleanSession": true
},
"handlers": [
{
"settings": {
"topic": "test",
"qos": 0
},
"action": {
"ref": "#flow",
"settings": {
"flowURI": "res://flow:mqtt"
},
"input": {
"message": "=$.message"
}
}
}
]
}
],
"resources": [
{
"id": "flow:mqtt",
"data": {
"name": "MQTT",
"description": "Reads MQTT device readings, and publishes to cloud VIA MQTT",
"metadata": {
"input": [
{
"name": "message",
"type": "string"
}
]
},
"tasks": [
{
"id": "log_2",
"name": "Log",
"description": "Logs a message",
"activity": {
"ref": "#log",
"input": {
"message": "=$flow.message",
"addDetails": true
}
}
},
{
"id": "mqtt_3",
"name": "MQTT Activity",
"description": "Send MQTT message",
"activity": {
"ref": "#mqtt_1",
"input": {
"message": "=$flow.message"
},
"settings": {
"broker": "tcp://localhost:1883",
"id": "flogo_publish",
"qos": 0,
"topic": "flogo",
"retain": false,
"cleanSession": true
}
}
}
],
"links": [
{
"from": "log_2",
"to": "mqtt_3"
}
]
}
}
]
}
Metadata
Metadata
Assignees
Labels
No labels