I have the deepstream-test5-app deployed on a Jetson Orin developer kit. Currently I am running into an issue when deploying multiple deepstream pipelines which use the MQTT msg broker plugin. It seems that connecting to the MQTT broker the client ID is hard coded in deepstream to “uniqueID”. When both modelA and modelB connect to the broker with the same clientID, it causes conflict because the MQTT broker needs a unique client ID which results in one of the models connections to be lost. Also, when a model is connected to the broker, if no predictions are being sent, the connection eventually times out.
JetPack version:
R35 (release), REVISION: 4.1, GCID: 33958178, BOARD: t186ref, EABI: aarch64, DATE: Tue Aug 1 19:57:35 UTC 2023
Deepstream version:
nvcr.io/nvidia/deepstream-l4t:6.3-samples
Below is an example of the mqtt msg-broker block in the deepstream config:
#modelA config.txt
[sink1]
enable=1
#Type - 1=FakeSink 2=EglSink 3=File 4=UDPSink 5=nvoverlaysink 6=MsgConvBroker
type=6
msg-broker-conn-str=mqtt;1883;object1
msg-broker-proto-lib=/opt/nvidia/deepstream/deepstream/lib/libnvds_mqtt_proto.so
topic=object1
msg-conv-payload-type=1
msg-conv-config=/projects/object1/msgconv_config.txt
newapi=0
msg-conv-frame-interval=1
disable-msgconv=0 # set to 0 to enable msgconv, which convert the NVEVENT metadata from primary/secondary GIE into mqtt message
#modelB config.txt
[sink1]
enable=1
#Type - 1=FakeSink 2=EglSink 3=File 4=UDPSink 5=nvoverlaysink 6=MsgConvBroker
type=6
msg-broker-conn-str=mqtt;1883;object2
msg-broker-proto-lib=/opt/nvidia/deepstream/deepstream/lib/libnvds_mqtt_proto.so
topic=object2
msg-conv-payload-type=1
msg-conv-config=/projects/object2/msgconv_config.txt
newapi=0
msg-conv-frame-interval=1
disable-msgconv=0 # set to 0 to enable msgconv, which convert the NVEVENT metadata from primary/secondary GIE into mqtt message
And here are the MQTT broker logs:
#Model A connects
1695861452: New client connected from 172.25.0.4:52582 as uniqueID (p2, c1, k60).
#Model B connects
1695861481: New connection from 172.25.0.3:58684 on port 1883.
#Model A connection gets closed because model B connected with same ID
1695861499: Client uniqueID already connected, closing old connection.
Is there a way to set the mqtt client ID inside the deepstream_config.txt? Is there a way to set the keep alive value to the broker as well?