Multi pipeline logging identification

Michael Gruner michael.gruner at ridgerun.com
Fri Dec 10 23:29:50 UTC 2021


Hey Vinod

The only way I can think of achieving something similar is to implement your own custom log handlers. Check:

https://gstreamer.freedesktop.org/documentation/gstreamer/gstinfo.html?gi-language=c#gst_debug_add_log_function

Note that the callback handler receives the GstObject that generated the entry (may be null though). Having the element you can recursively find the topmost parent which will be the pipeline, if the element has been added to one already. 

Michael
www.ridgerun.com 

> On 10 Dec 2021, at 12:28, vinod kesti via gstreamer-devel <gstreamer-devel at lists.freedesktop.org> wrote:
> 
> 
> Hi all,
> 
> I am running multiple Gstreamer pipelines in single linux process. All the pipelines are similar and only udp input and output ports are chanig. 
> Log function is Registered using gst_debug_add_log_function(),  after the gst_init(). I am not able to identify the which pipeline dumping the error.
> 
> One way I found is if GObject is an GstElement/GstPad I am able to find the parent pipeline and dump the pipeline name. But I have facing problem when GObject in the callback is null. Is there any way to differentiate from which Pipeline we are getting warning.
> 
> 
> 
> 
> Sent from Yahoo Mail. Get the app
> 
> 
> On Thursday, 9 December, 2021, 06:56:44 pm GMT-6, Dwight Kulkarni via gstreamer-devel <gstreamer-devel at lists.freedesktop.org> wrote:
> 
> 
> Hi Vinod,
> 
> I don't know enough about the debug log to help you with that, but it doesn't appear to be the right architecture to have multiple pipelines that are similar or same with udp different ports.
> 
> I did use multiple pipelines and had to put all the similar elements into a single pipeline and then pull out data to multiple app sinks. Some source elements like v4l2src did not allow two pipelines to access them simultaneously (if memory serves).
> 
> Best regards.
> 
> 
> On Thu., Dec. 9, 2021, 4:16 p.m. vinod kesti, <vinodkesti at yahoo.com> wrote:
> Hi  Dwight Kulkarni,
> 
> Thanks for responding. gst_bus_add_watch() handles messages. GST_ELEMENT_ERROR/WARNINGS are reported on the bus but not the GST_ERROR() and GST_WARNING().
> Any help is appreciated thanks in advance.
> 
> 
> 
> 
> Sent from Yahoo Mail. Get the app
> 
> 
> On Thursday, 9 December, 2021, 02:22:29 pm GMT-6, Dwight Kulkarni via gstreamer-devel <gstreamer-devel at lists.freedesktop.org> wrote:
> 
> 
> Hi Vinod,
> 
> You can try registering for the Bus messages with: gst_bus_add_watch(..)
> 
> The GstMessage object returned can be queried for it's source object name.
> 
> 
> On Thu, Dec 9, 2021 at 11:54 AM vinod kesti via gstreamer-devel <gstreamer-devel at lists.freedesktop.org> wrote:
> Hi all,
> 
> I am running multiple Gstreamer pipelines in single linux process. All the pipelines are similar and only udp input and output ports are chanig. 
> Log function is Registered using gst_debug_add_log_function(),  after the gst_init(). I am not able to identify the which pipeline dumping the error.
> 
> One way I found is if GObject is an GstElement/GstPad I am able to find the parent pipeline and dump the pipeline name. But I have facing problem when GObject in the callback is null. Is there any way to differentiate from which Pipeline we are getting warning.
> 
> 
> 
> Sent from Yahoo Mail. Get the app
> 
> 
> -- 
> Sincerely,
> 
> Dwight Kulkarni                
> 
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.freedesktop.org/archives/gstreamer-devel/attachments/20211210/20bea73e/attachment.htm>


More information about the gstreamer-devel mailing list