GStreamer RTSP error detection for pipelines

I’ve set up a GStreamer RTSP server on my TX2 and gotten it working to stream both audio and video the way I’d like. I’m looking for a way to keep track of the health of the pipelines doing the streaming, e.g. an issue happens with the live stream camera, the mic has problems. I’ve been poking around the rtsp server’s source and I haven’t found a great place/way to set up call backs to monitor if the pipeline errors. Has anybody done something similar? Found a place to start?

Hi,
The question is about gstreamer native plugins such as rtspsrc. We may not have enough experience on the advanced functions. Suggest you go to gstreamer forum to get help.

Hi,

You could listen to the pipeline bus for error messages, check this example:

https://gstreamer.freedesktop.org/documentation/application-development/basics/helloworld.html?gi-language=c

An easier to achieve this would be to use GStreamer_Daemon and listen to the bus for errors, checkout the following wiki:

Receiving_Messages_from_the_Bus

Hope this helps.
https://www.ridgerun.com/

1 Like

Response to this question (reposted) on the GStreamer forums:

As you may have found, gst-rtsp-server uses the pipeline’s bus and a bus can only have one watcher. One way around this is to make your own subclass of RTSPMedia that overrides the “do_handle_message” method. Then, you can use “set_media_gtype” on your RTSPMediaFactory to make it use your custom RTSPMedia type.

1 Like