[PR #1904] [MERGED] Switch ffmpeg to hls muxer (from segment) to fix premature stop on non-patched ffmpeg #8764

Closed
opened 2025-12-22 07:06:27 +01:00 by backuprepo · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/jellyfin/jellyfin/pull/1904
Author: @JustAMan
Created: 10/16/2019
Status: Merged
Merged: 11/3/2019
Merged by: @joshuaboniface

Base: masterHead: hls-move-2


📝 Commits (10+)

  • 6746f70 Revert "Revert "Fix premature stop when streaming""
  • c1f9107 Add more logging
  • 7aea926 Stop waiting for a segment to become ready if there's no alive transcode
  • 3740228 Don't start waiting for a segment which doesn't exist if transcoding is not running
  • 986ea5c Fix log message - log args were swapped
  • 2f6879e Add limiting max keyframe interval when full transcoding
  • 82f8345 Log to debug all HTTP 500 response urls
  • 1bd1208 Respect non-inversed setting of "enable break on non-keyframes"
  • 3132280 * Make sure force_key_frames expression arguments are properly converted to strings
  • adccc18 Revert "yarn build" as it is fixed in master, fix typo

📊 Changes

4 files changed (+84 additions, -42 deletions)

View changed files

📝 Emby.Server.Implementations/HttpServer/HttpListenerHost.cs (+5 -0)
📝 MediaBrowser.Api/Playback/BaseStreamingService.cs (+7 -1)
📝 MediaBrowser.Api/Playback/Hls/DynamicHlsService.cs (+70 -40)
📝 MediaBrowser.Controller/MediaEncoding/EncodingHelper.cs (+2 -1)

📄 Description

Changes

  • Change ffmpeg muxer used in HLS streaming from segment to hls (segment muxer has a bug patch for which is not yet accepted upstream)
  • Add more options to enforce keyframes in full transcoding (it should help having segment lengths to be much closer to requested "segment length")
  • Add even more debug logging - used for making this happen, but won't hurt to keep it there IMHO
  • Fix the condition on "enable break on non-keyframes" - this might be a potentially breaking change, but its previous state (before my fix) didn't make any sense to me whatsoever.

Issues
It should really fix https://github.com/jellyfin/jellyfin/issues/1694 without relying to use a patched ffmpeg


🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/jellyfin/jellyfin/pull/1904 **Author:** [@JustAMan](https://github.com/JustAMan) **Created:** 10/16/2019 **Status:** ✅ Merged **Merged:** 11/3/2019 **Merged by:** [@joshuaboniface](https://github.com/joshuaboniface) **Base:** `master` ← **Head:** `hls-move-2` --- ### 📝 Commits (10+) - [`6746f70`](https://github.com/jellyfin/jellyfin/commit/6746f708f2c2f306ea04270b93cfed2e28eb36c9) Revert "Revert "Fix premature stop when streaming"" - [`c1f9107`](https://github.com/jellyfin/jellyfin/commit/c1f9107b8be9b3cbd26e15773998c7ac6598e7f9) Add more logging - [`7aea926`](https://github.com/jellyfin/jellyfin/commit/7aea9266d05ddd0673c390e102833c154b3ff9f6) Stop waiting for a segment to become ready if there's no alive transcode - [`3740228`](https://github.com/jellyfin/jellyfin/commit/3740228100b15c9feae1864f5652674af69e582c) Don't start waiting for a segment which doesn't exist if transcoding is not running - [`986ea5c`](https://github.com/jellyfin/jellyfin/commit/986ea5c636ead098446cca31ea737d2f361a05d8) Fix log message - log args were swapped - [`2f6879e`](https://github.com/jellyfin/jellyfin/commit/2f6879e8699e53c3d140dacd9af8c207bdf8cb74) Add limiting max keyframe interval when full transcoding - [`82f8345`](https://github.com/jellyfin/jellyfin/commit/82f8345aa5ae65a8a934a4f2d29afdbc3836d875) Log to debug all HTTP 500 response urls - [`1bd1208`](https://github.com/jellyfin/jellyfin/commit/1bd12083c3d7eda02bd7e3b785f4853620dc6cc9) Respect non-inversed setting of "enable break on non-keyframes" - [`3132280`](https://github.com/jellyfin/jellyfin/commit/3132280b0748efd6ded7d8c9d8795506ef8c30ed) * Make sure force_key_frames expression arguments are properly converted to strings - [`adccc18`](https://github.com/jellyfin/jellyfin/commit/adccc18298f4ebba511b68d5af9e72f78de5e5e8) Revert "yarn build" as it is fixed in master, fix typo ### 📊 Changes **4 files changed** (+84 additions, -42 deletions) <details> <summary>View changed files</summary> 📝 `Emby.Server.Implementations/HttpServer/HttpListenerHost.cs` (+5 -0) 📝 `MediaBrowser.Api/Playback/BaseStreamingService.cs` (+7 -1) 📝 `MediaBrowser.Api/Playback/Hls/DynamicHlsService.cs` (+70 -40) 📝 `MediaBrowser.Controller/MediaEncoding/EncodingHelper.cs` (+2 -1) </details> ### 📄 Description <!-- Ensure your title is short, descriptive, and in the imperative mood (Fix X, Change Y, instead of Fixed X, Changed Y). For a good inspiration of what to write in commit messages and PRs please review https://chris.beams.io/posts/git-commit/ and our documentation. --> **Changes** * Change ffmpeg muxer used in HLS streaming from `segment` to `hls` (`segment` muxer has a bug patch for which is not yet accepted upstream) * Add more options to enforce keyframes in full transcoding (it should help having segment lengths to be much closer to requested "segment length") * Add even more debug logging - used for making this happen, but won't hurt to keep it there IMHO * Fix the condition on "enable break on non-keyframes" - this might be a potentially breaking change, but its previous state (before my fix) didn't make _any sense_ to me whatsoever. **Issues** It should really fix https://github.com/jellyfin/jellyfin/issues/1694 without relying to use a patched ffmpeg --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
backuprepo 2025-12-22 07:06:27 +01:00
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference: starred/jellyfin#8764
No description provided.