ltm rule command MQTT length
iRule(1) BIG-IP TMSH Manual iRule(1)
MQTT::length
Get length of MQTT message
SYNOPSIS
MQTT::length
DESCRIPTION
This command can be used to get length of MQTT message. This command is valid for all MQTT message types:
CONNECT, CONNACK,
PUBLISH, PUBACK, PUBREC, PUBREL, PUBCOMP,
SUBSCRIBE, SUBACK,
UNSUBSCRIBE, UNSUBACK,
PINGREQ, PINGRESP,
DISCONNECT
Syntax
MQTT::length
RETURN VALUE
This command returns the length of MQTT message.
VALID DURING
MQTT_CLIENT_INGRESS MQTT_SERVER_INGRESS MQTT_CLIENT_EGRESS MQTT_SERVER_EGRESS
EXAMPLES
# Drop connections with messages that exceed an administrative max
#
when MQTT_CLIENT_INGRESS {
set length [MQTT::length]
if { $length > 65536 } {
MQTT::disconnect
}
}
HINTS
SEE ALSO
CHANGE LOG
@BIGIP-13.0.0 --First introduced the command.
BIG-IP 2022-04-12 iRule(1)