enum MqttQualityOfService
Language | Type name |
---|---|
![]() | Amazon.CDK.AWS.IoT.Actions.MqttQualityOfService |
![]() | software.amazon.awscdk.services.iot.actions.MqttQualityOfService |
![]() | aws_cdk.aws_iot_actions.MqttQualityOfService |
![]() | @aws-cdk/aws-iot-actions » MqttQualityOfService |
MQTT Quality of Service (QoS) indicates the level of assurance for delivery of an MQTT Message.
See also: https://docs.aws.amazon.com/iot/latest/developerguide/mqtt.html#mqtt-qos
Example
new iot.TopicRule(this, 'TopicRule', {
sql: iot.IotSql.fromStringAsVer20160323("SELECT topic(2) as device_id, timestamp() as timestamp, temperature FROM 'device/+/data'"),
actions: [
new actions.IotRepublishMqttAction('${topic()}/republish', {
qualityOfService: actions.MqttQualityOfService.AT_LEAST_ONCE, // optional property, default is MqttQualityOfService.ZERO_OR_MORE_TIMES
}),
],
});
Members
Name | Description |
---|---|
ZERO_OR_MORE_TIMES | QoS level 0. |
AT_LEAST_ONCE | QoS level 1. |
ZERO_OR_MORE_TIMES
QoS level 0.
Sent zero or more times. This level should be used for messages that are sent over reliable communication links or that can be missed without a problem.
AT_LEAST_ONCE
QoS level 1.
Sent at least one time, and then repeatedly until a PUBACK response is received. The message is not considered complete until the sender receives a PUBACK response to indicate successful delivery.