Skip to content

Recover appsrc from stranded flushing state instead of failing the egress - #1312

Merged
milos-lk merged 2 commits into
mainfrom
flow-flushing-light-recovery
Jul 27, 2026
Merged

Recover appsrc from stranded flushing state instead of failing the egress#1312
milos-lk merged 2 commits into
mainfrom
flow-flushing-light-recovery

Conversation

@milos-lk

Copy link
Copy Markdown
Contributor

We still see persistent FlowFlushing failures after #1293/#1305, including on file-only egress, which rules out the RTMP sink path as the only trigger. The pipeline dump from that failure shows the exact stranded state: the appsrc reports PLAYING with clean pad flags, but its streaming task is paused and its internal flushing flag is stuck, so every PushBuffer returns FlowFlushing from the very first packet until the writer gives up.

Trying to fix the persistent flow flushing with significantly lighter logic than before - basically by sending flush start / stop events which should clear the flushing state and restart task allowing data to flow

…ress

We still see persistent FlowFlushing failures after #1293/#1305, including on file-only egress, which rules out the RTMP sink path as the only trigger. The pipeline dump from that failure shows the exact stranded state: the appsrc reports PLAYING with clean pad flags, but its streaming task is paused and its internal flushing flag is stuck, so every PushBuffer returns FlowFlushing from the very first packet until the writer gives up.

Trying to fix the persistent flow flushing with significantly lighter logic than before - basically by sending flush start / stop events which should clear the flushing state and restart task allowing data to flow
@github-actions

github-actions Bot commented Jul 27, 2026

Copy link
Copy Markdown
Contributor

AV-sync stats summary: view in run #30280614030

if !w.src.SendEvent(gst.NewFlushStopEvent(false)) {
w.logger.Warnw("failed to send recovery flush stop event", nil)
}
w.logger.Infow("FlowFlushing recovery successful")

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

is this successful even if flush stop send fails?

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ugh - no - it could be misleading - will update it - good catch - thanks!

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

updated

@milos-lk
milos-lk merged commit 1956613 into main Jul 27, 2026
17 checks passed
@milos-lk
milos-lk deleted the flow-flushing-light-recovery branch July 27, 2026 15:49
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants