Discussion:
[Bug 778763] New: adaptivedemux: Add pad probe for upstream event/query
Add Reply
"GStreamer" (GNOME Bugzilla)
2017-02-16 14:41:56 UTC
Reply
Permalink
Raw Message
https://bugzilla.gnome.org/show_bug.cgi?id=778763

Bug ID: 778763
Summary: adaptivedemux: Add pad probe for upstream event/query
Classification: Platform
Product: GStreamer
Version: git master
OS: Linux
Status: NEW
Severity: normal
Priority: Normal
Component: gst-plugins-bad
Assignee: gstreamer-***@lists.freedesktop.org
Reporter: ***@lge.com
QA Contact: gstreamer-***@lists.freedesktop.org
GNOME version: ---

Add probe to fix deadlock and bug on seeking.

* About deadlock
Assume that seek event was forwarded from a srcpad, and demux is handling it
now.
At the same time, any queries/event which take manifest lock might be forwarded
from the other pads. Since _handle_seek_event() takes manifest lock,
the queries/event can never be handled until _handle_seek_event() is finished.
Also, demux cannot push flush event since the pads are stream locked by
the queries/event.

* Delay handle seek until preroll done
Because subclass handles seeking only for existing stream (not preparing
stream),
wait on preroll.
--
You are receiving this mail because:
You are the QA Contact for the bug.
You are the assignee for the bug.
"GStreamer" (GNOME Bugzilla)
2017-02-16 14:45:50 UTC
Reply
Permalink
Raw Message
https://bugzilla.gnome.org/show_bug.cgi?id=778763

--- Comment #1 from Seungha Yang <***@lge.com> ---
Created attachment 345944
--> https://bugzilla.gnome.org/attachment.cgi?id=345944&action=edit
adaptivedemux: Add pad probe for upstream event/query
--
You are receiving this mail because:
You are the QA Contact for the bug.
You are the assignee for the bug.
"GStreamer" (GNOME Bugzilla)
2017-02-16 14:46:07 UTC
Reply
Permalink
Raw Message
https://bugzilla.gnome.org/show_bug.cgi?id=778763

--- Comment #2 from Seungha Yang <***@lge.com> ---
Created attachment 345945
--> https://bugzilla.gnome.org/attachment.cgi?id=345945&action=edit
adaptivedemux: Print preroll lock/unlock log
--
You are receiving this mail because:
You are the QA Contact for the bug.
You are the assignee for the bug.
"GStreamer" (GNOME Bugzilla)
2017-02-16 14:46:41 UTC
Reply
Permalink
Raw Message
https://bugzilla.gnome.org/show_bug.cgi?id=778763

--- Comment #3 from Seungha Yang <***@lge.com> ---
Created attachment 345946
--> https://bugzilla.gnome.org/attachment.cgi?id=345946&action=edit
adaptivedemux: Stop prepare stream's task if needed

When demux chagnes state from PAUSED to READY, there can be prepared
but not yet exposed streams. To unload pipeline, the tasks of those streams
and corresponding source elements should be stopped.
--
You are receiving this mail because:
You are the QA Contact for the bug.
You are the assignee for the bug.
"GStreamer" (GNOME Bugzilla)
2017-02-17 02:16:32 UTC
Reply
Permalink
Raw Message
https://bugzilla.gnome.org/show_bug.cgi?id=778763

--- Comment #4 from Nicolas Dufresne (stormer) <***@ndufresne.ca> ---
*** Bug 776606 has been marked as a duplicate of this bug. ***
--
You are receiving this mail because:
You are the QA Contact for the bug.
You are the assignee for the bug.
"GStreamer" (GNOME Bugzilla)
2017-02-21 03:15:30 UTC
Reply
Permalink
Raw Message
https://bugzilla.gnome.org/show_bug.cgi?id=778763

Seungha Yang <***@lge.com> changed:

What |Removed |Added
----------------------------------------------------------------------------
Attachment #345944|0 |1
is obsolete| |

--- Comment #5 from Seungha Yang <***@lge.com> ---
Created attachment 346297
--> https://bugzilla.gnome.org/attachment.cgi?id=346297&action=edit
adaptivedemux: Release manifest lock before pushing flush event
--
You are receiving this mail because:
You are the QA Contact for the bug.
You are the assignee for the bug.
"GStreamer" (GNOME Bugzilla)
2017-02-21 04:40:35 UTC
Reply
Permalink
Raw Message
https://bugzilla.gnome.org/show_bug.cgi?id=778763

--- Comment #6 from Seungha Yang <***@lge.com> ---
Created attachment 346298
--> https://bugzilla.gnome.org/attachment.cgi?id=346298&action=edit
adaptivedemux: Reset "cancelled" to FALSE whatever target stream is

No reason to restrict only non prepared stream.
--
You are receiving this mail because:
You are the QA Contact for the bug.
You are the assignee for the bug.
"GStreamer" (GNOME Bugzilla)
2017-02-21 04:40:56 UTC
Reply
Permalink
Raw Message
https://bugzilla.gnome.org/show_bug.cgi?id=778763

--- Comment #7 from Seungha Yang <***@lge.com> ---
Created attachment 346299
--> https://bugzilla.gnome.org/attachment.cgi?id=346299&action=edit
adaptivedemux: Handle seek event during prerolling
--
You are receiving this mail because:
You are the QA Contact for the bug.
You are the assignee for the bug.
"GStreamer" (GNOME Bugzilla)
2017-02-21 04:41:43 UTC
Reply
Permalink
Raw Message
https://bugzilla.gnome.org/show_bug.cgi?id=778763

--- Comment #8 from Seungha Yang <***@lge.com> ---
Created attachment 346300
--> https://bugzilla.gnome.org/attachment.cgi?id=346300&action=edit
hlsdemux: Select target seeking stream depending on demux's preroll state

Although demux is doing preroll (not yet finished), demux can get seek event.
In this case, demux needs to do seek only for prepared streams, since existing
streams will be removed after preroll done.
--
You are receiving this mail because:
You are the QA Contact for the bug.
You are the assignee for the bug.
"GStreamer" (GNOME Bugzilla)
2017-02-21 05:36:00 UTC
Reply
Permalink
Raw Message
https://bugzilla.gnome.org/show_bug.cgi?id=778763

--- Comment #9 from Seungha Yang <***@lge.com> ---
Created attachment 346302
--> https://bugzilla.gnome.org/attachment.cgi?id=346302&action=edit
adaptivedemux: Move preroll count to _start_tasks () function

To reset preroll pending count whenever start new tasks
--
You are receiving this mail because:
You are the QA Contact for the bug.
You are the assignee for the bug.
"GStreamer" (GNOME Bugzilla)
2017-04-16 02:37:23 UTC
Reply
Permalink
Raw Message
https://bugzilla.gnome.org/show_bug.cgi?id=778763

Seungha Yang <***@lge.com> changed:

What |Removed |Added
----------------------------------------------------------------------------
Attachment #346297|0 |1
is obsolete| |

--- Comment #10 from Seungha Yang <***@lge.com> ---
Comment on attachment 346297
--> https://bugzilla.gnome.org/attachment.cgi?id=346297
adaptivedemux: Release manifest lock before pushing flush event

Fixed in bug #781320
--
You are receiving this mail because:
You are the QA Contact for the bug.
You are the assignee for the bug.
"GStreamer" (GNOME Bugzilla)
2017-04-16 07:41:02 UTC
Reply
Permalink
Raw Message
https://bugzilla.gnome.org/show_bug.cgi?id=778763

Edward Hervey <***@bilboed.com> changed:

What |Removed |Added
----------------------------------------------------------------------------
Status|NEW |NEEDINFO
CC| |***@bilboed.com

--- Comment #11 from Edward Hervey <***@bilboed.com> ---
Seungha, is the issue still present with that commit from #781320 ?
--
You are receiving this mail because:
You are the QA Contact for the bug.
You are the assignee for the bug.
"GStreamer" (GNOME Bugzilla)
2017-04-16 08:19:17 UTC
Reply
Permalink
Raw Message
https://bugzilla.gnome.org/show_bug.cgi?id=778763

--- Comment #12 from Seungha Yang <***@lge.com> ---
(In reply to Edward Hervey from comment #11)
Post by "GStreamer" (GNOME Bugzilla)
Seungha, is the issue still present with that commit from #781320 ?
I guess issue still be there but I'll test again on top of master and let you
know :) Note that it was hard to reproduce since seek and preroll should be
happen at the same time.
--
You are receiving this mail because:
You are the QA Contact for the bug.
You are the assignee for the bug.
"GStreamer" (GNOME Bugzilla)
2017-04-17 04:13:51 UTC
Reply
Permalink
Raw Message
https://bugzilla.gnome.org/show_bug.cgi?id=778763

--- Comment #13 from Seungha Yang <***@lge.com> ---
(In reply to Edward Hervey from comment #11)
Post by "GStreamer" (GNOME Bugzilla)
Seungha, is the issue still present with that commit from #781320 ?
Hello Edward

The issue is still there... I'll do re-work the previously reported patch and
update unit test code for prerolling soon.
--
You are receiving this mail because:
You are the QA Contact for the bug.
You are the assignee for the bug.
"GStreamer" (GNOME Bugzilla)
2017-04-23 15:05:06 UTC
Reply
Permalink
Raw Message
https://bugzilla.gnome.org/show_bug.cgi?id=778763

Seungha Yang <***@lge.com> changed:

What |Removed |Added
----------------------------------------------------------------------------
Summary|adaptivedemux: Add pad |adaptivedemux: Handle seek
|probe for upstream |during preroll
|event/query |
--
You are receiving this mail because:
You are the QA Contact for the bug.
You are the assignee for the bug.
"GStreamer" (GNOME Bugzilla)
2017-04-23 15:07:06 UTC
Reply
Permalink
Raw Message
https://bugzilla.gnome.org/show_bug.cgi?id=778763

Seungha Yang <***@lge.com> changed:

What |Removed |Added
----------------------------------------------------------------------------
Attachment #345945|0 |1
is obsolete| |
Attachment #345946|0 |1
is obsolete| |
Attachment #346298|0 |1
is obsolete| |
Attachment #346299|0 |1
is obsolete| |
Attachment #346300|0 |1
is obsolete| |
Attachment #346302|0 |1
is obsolete| |

--- Comment #14 from Seungha Yang <***@lge.com> ---
Created attachment 350261
--> https://bugzilla.gnome.org/attachment.cgi?id=350261&action=edit
adaptivedemux: Move preroll count to _start_tasks () function

To reset preroll pending count whenever start new tasks
--
You are receiving this mail because:
You are the QA Contact for the bug.
You are the assignee for the bug.
"GStreamer" (GNOME Bugzilla)
2017-04-23 15:08:17 UTC
Reply
Permalink
Raw Message
https://bugzilla.gnome.org/show_bug.cgi?id=778763

--- Comment #15 from Seungha Yang <***@lge.com> ---
Created attachment 350262
--> https://bugzilla.gnome.org/attachment.cgi?id=350262&action=edit
adaptivedemux: Stop tasks of preroll streams with gst_adaptive_demux_stop_tasks

When demux changes state from PAUSED to READY or does seek, there can be
prepared
but not yet exposed streams.
--
You are receiving this mail because:
You are the QA Contact for the bug.
You are the assignee for the bug.
"GStreamer" (GNOME Bugzilla)
2017-04-23 15:08:48 UTC
Reply
Permalink
Raw Message
https://bugzilla.gnome.org/show_bug.cgi?id=778763

--- Comment #16 from Seungha Yang <***@lge.com> ---
Created attachment 350263
--> https://bugzilla.gnome.org/attachment.cgi?id=350263&action=edit
adaptivedemux: Clear pending preroll streams during seek

Start preroll again if any pending preroll streams are there during seek
--
You are receiving this mail because:
You are the QA Contact for the bug.
You are the assignee for the bug.
"GStreamer" (GNOME Bugzilla)
2017-04-23 15:09:11 UTC
Reply
Permalink
Raw Message
https://bugzilla.gnome.org/show_bug.cgi?id=778763

--- Comment #17 from Seungha Yang <***@lge.com> ---
Created attachment 350264
--> https://bugzilla.gnome.org/attachment.cgi?id=350264&action=edit
dashdemux: Setup streams again if there are pending preroll streams

Handle the case that period change and seek happen at the same time
--
You are receiving this mail because:
You are the QA Contact for the bug.
You are the assignee for the bug.
"GStreamer" (GNOME Bugzilla)
2017-04-23 15:11:09 UTC
Reply
Permalink
Raw Message
https://bugzilla.gnome.org/show_bug.cgi?id=778763

--- Comment #18 from Seungha Yang <***@lge.com> ---
Created attachment 350265
--> https://bugzilla.gnome.org/attachment.cgi?id=350265&action=edit
[DO NOT MERGE] test for adaptivedemux seek during preroll

- Disable waiting async/buffering to do next action
- Add scenario of seek back/forward for specific multi-period DASH stream
--
You are receiving this mail because:
You are the QA Contact for the bug.
You are the assignee for the bug.
"GStreamer" (GNOME Bugzilla)
2017-04-23 15:12:49 UTC
Reply
Permalink
Raw Message
https://bugzilla.gnome.org/show_bug.cgi?id=778763

--- Comment #19 from Seungha Yang <***@lge.com> ---
The issue can be reproduced by

GST_VALIDATE_SCENARIO='seek_over_period' DISPLAY=':0'
GST_VALIDATE_OVERRIDE='.../medias/dash-if/DASHIF_TestCases_5c_nomor_4_1a.override'
GST_GL_XINITTHREADS='1' .../gst-validate-1.0 playbin
uri=http://dash.akamaized.net/dash264/TestCases/5c/nomor/4_1a.mpd
audio-sink=fakesink sync=true video-sink=fakesink sync=true qos=true
max-lateness=20000000 --set-media-info
.../gst-validate/gst-integration-testsuites/medias/dash-if/DASHIF_TestCases_5c_nomor_4_1a.stream_info
--
You are receiving this mail because:
You are the QA Contact for the bug.
You are the assignee for the bug.
Loading...