RealtimeTrigger
Consume a message in real-time from MQTT topics and create one execution per message.
If you would like to consume multiple messages processed within a given time frame and process them in batch, you can use the io.kestra.plugin.mqtt.Trigger instead.
yaml
type: "io.kestra.plugin.mqtt.RealtimeTrigger"
Consume a message from MQTT topics in real-time.
yaml
id: mqtt_realtime_trigger
namespace: company.team
tasks:
- id: log
type: io.kestra.plugin.core.log.Log
message: "{{ trigger.payload }}"
triggers:
- id: realtime_trigger
type: io.kestra.plugin.mqtt.RealtimeTrigger
server: tcp://localhost:1883
clientId: kestraProducer
topic:
- kestra/sensors/cpu
- kestra/sensors/mem
serdeType: JSON
Dynamic YES
Default 1
Dynamic YES
Default JSON
Possible Values
STRINGJSONBYTES
Serializer / Deserializer used for the payload
Dynamic YES
Topic where to consume message
Can be a string or a List of string to consume from multiple topic
Dynamic YES
Default V5
Possible Values
V3V5
Dynamic YES
Dynamic YES
Dynamic YES
Format duration
Dynamic YES
Dynamic YES
Dynamic YES
Dynamic YES
SubType string
Dynamic NO
Possible Values
CREATEDRUNNINGPAUSEDRESTARTEDKILLINGSUCCESSWARNINGFAILEDKILLEDCANCELLEDQUEUEDRETRYINGRETRIEDSKIPPED
List of execution states after which a trigger should be stopped (a.k.a. disabled).
Dynamic YES
SubType string