Certain media hang on generating thumbnail
|Reported by:||ayleph||Owned by:|
|Component:||programming||Keywords:||gstrreamer, video, thumbnail, ogg|
|Cc:||Boris Bobrov||Parent Tickets:|
A user is uploading a number of ogg video files to my instance (videos with .ogg extension). These files transcode fine, which makes me think I have the correct python bindings for ogg files, but they hang at the thumbnail stage. Once this happens, that celery worker becomes stuck waiting and cannot be used for anything else. When enough of these files get uploaded and processed, all of my celery workers become stuck and nothing else proceeds. I have to restart my celery service to kill the stuck workers and make them available for use again.
I added a bunch of debug logging statements and tracked it down to the following line in
sample = appsink.emit("pull-preroll")
Online gst documentation says that
pull-preroll may block until the preroll buffer or EOS signal is received, which appears to be happening on my instance with these video files.
The normal way of retrieving samples from appsink is by using
the gst_app_sink_pull_sample() and gst_app_sink_pull_preroll()
methods. These methods block until a sample becomes available
in the sink or when the sink is shut down or reaches EOS.
If a blocking behaviour is not desirable, setting the
"emit-signals" property to TRUE will make appsink emit the
"new-sample" and "new-preroll" signals when a sample can be
pulled without blocking.
The "caps" property on appsink can be used to control the
formats that appsink can receive. This property can contain
non-fixed caps, the format of the pulled samples can be
obtained by getting the sample caps.
If one of the pull-preroll or pull-sample methods return NULL,
the appsink is stopped or in the EOS state. You can check for
the EOS state with the "eos" property or with the