tracer: rename the envvar to GST_TRACER_PLUGINS
authorStefan Sauer <ensonic@users.sf.net>
Mon, 19 Oct 2015 19:39:19 +0000 (21:39 +0200)
committerStefan Sauer <ensonic@users.sf.net>
Mon, 19 Oct 2015 19:41:13 +0000 (21:41 +0200)
The subsystem reused the GST_TRACE var that is allready in use by the alloc tracer.
Fixes #756760

docs/design/draft-tracing.txt
docs/plugins/gstreamer-plugins-docs.sgml
gst/gsttracerutils.c

index 3a6f692..98f75e6 100644 (file)
@@ -36,8 +36,8 @@ condition to check if active.
 Certain GStreamer core function (such as gst_pad_push or gst_element_add_pad)
 will call into the tracer subsystem to dispatch into active tracing modules.
 Developers will be able to select a list of plugins by setting an environment
-variable, such as GST_TRACE="meminfo;dbus". One can also pass parameters to
-plugins:  GST_TRACE="log(events,buffers);stats(all)".
+variable, such as GST_TRACER_PLUGINS="meminfo;dbus". One can also pass parameters to
+plugins:  GST_TRACER_PLUGINS="log(events,buffers);stats(all)".
 When then plugins are loaded, we'll add them to certain hooks according to which
 they are interested in.
 
@@ -83,7 +83,7 @@ In addition to api hooks we should also provide timer hooks. Interval timers are
 useful to get e.g. resource usage snapshots. Also absolute timers might make
 sense. All this could be implemented with a clock thread. We can use another
 env-var GST_TRACE_TIMERS="100ms,75ms" to configure timers and then pass them to
-the tracers like, GST_TRACE="rusage(timer=100ms);meminfo(timer=75ms)". Maybe
+the tracers like, GST_TRACER_PLUGINS="rusage(timer=100ms);meminfo(timer=75ms)". Maybe
 we can create them ad-hoc and avoid the GST_TRACE_TIMERS var.
 
 Hooks (* already implemented)
@@ -332,19 +332,19 @@ Problems / Open items
 
 Try it
 ======
-GST_DEBUG="GST_TRACER:7,GST_BUFFER*:7,GST_EVENT:7,GST_MESSAGE:7" GST_TRACE=log gst-launch-1.0 fakesrc num-buffers=10 ! fakesink
+GST_DEBUG="GST_TRACER:7,GST_BUFFER*:7,GST_EVENT:7,GST_MESSAGE:7" GST_TRACER_PLUGINS=log gst-launch-1.0 fakesrc num-buffers=10 ! fakesink
 - traces for buffer flow in TRACE level
 
-GST_DEBUG="GST_TRACER:7" GST_TRACE="stats;rusage" GST_DEBUG_FILE=trace.log gst-launch-1.0 fakesrc num-buffers=10 sizetype=fixed ! queue ! fakesink
+GST_DEBUG="GST_TRACER:7" GST_TRACER_PLUGINS="stats;rusage" GST_DEBUG_FILE=trace.log gst-launch-1.0 fakesrc num-buffers=10 sizetype=fixed ! queue ! fakesink
 gst-stats-1.0 trace.log
 - print some pipeline stats on exit
 
-GST_DEBUG="GST_TRACER:7" GST_TRACE="stats;rusage" GST_DEBUG_FILE=trace.log /usr/bin/gst-play-1.0 --interactive $HOME/Videos/movie.mp4
+GST_DEBUG="GST_TRACER:7" GST_TRACER_PLUGINS="stats;rusage" GST_DEBUG_FILE=trace.log /usr/bin/gst-play-1.0 --interactive $HOME/Videos/movie.mp4
 ./scripts/gst-plot-traces.sh --format=png | gnuplot
 eog trace.log.*.png
 - get ts, average-cpuload, current-cpuload, time and plot
 
-GST_DEBUG="GST_TRACER:7" GST_TRACE=latency gst-launch-1.0 audiotestsrc num-buffers=10 ! audioconvert ! volume volume=0.7 ! autoaudiosink
+GST_DEBUG="GST_TRACER:7" GST_TRACER_PLUGINS=latency gst-launch-1.0 audiotestsrc num-buffers=10 ! audioconvert ! volume volume=0.7 ! autoaudiosink
 - print processing latencies
 
 Performance
index c97ddc4..89edb0c 100644 (file)
     <xi:include href="xml/element-capsfilter.xml" />
     <xi:include href="xml/element-concat.xml" />
     <xi:include href="xml/element-downloadbuffer.xml" />
-    <xi:include href="xml/element-fakesrc.xml" />
     <xi:include href="xml/element-fakesink.xml" />
+    <xi:include href="xml/element-fakesrc.xml" />
     <xi:include href="xml/element-fdsink.xml" />
     <xi:include href="xml/element-fdsrc.xml" />
-    <xi:include href="xml/element-filesrc.xml" />
     <xi:include href="xml/element-filesink.xml" />
+    <xi:include href="xml/element-filesrc.xml" />
     <xi:include href="xml/element-funnel.xml" />
     <xi:include href="xml/element-identity.xml" />
     <xi:include href="xml/element-input-selector.xml" />
     <xi:include href="xml/element-multiqueue.xml" />
     <xi:include href="xml/element-output-selector.xml" />
-    <xi:include href="xml/element-queue.xml" />
     <xi:include href="xml/element-queue2.xml" />
+    <xi:include href="xml/element-queue.xml" />
     <xi:include href="xml/element-streamiddemux.xml" />
     <xi:include href="xml/element-tee.xml" />
     <xi:include href="xml/element-typefind.xml" />
index e7afa49..a5a82df 100644 (file)
@@ -65,7 +65,7 @@ GHashTable *_priv_tracers = NULL;
 void
 _priv_gst_tracing_init (void)
 {
-  const gchar *env = g_getenv ("GST_TRACE");
+  const gchar *env = g_getenv ("GST_TRACER_PLUGINS");
 
   if (env != NULL && *env != '\0') {
     GstRegistry *registry = gst_registry_get ();