You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: docs/proxy/failover.md
+34Lines changed: 34 additions & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -141,6 +141,40 @@ When [Sticky Sessions](./sticky-sessions.md) are enabled, the proxy locks to a s
141
141
3. If the original URL also fails, trigger failover to the next failover URL
142
142
4. The sticky session locks to the new provider's backend
143
143
144
+
## Advanced Failover (M3U Editor)
145
+
146
+
The M3U Editor adds a higher-level **failover resolver** on top of the proxy's built-in URL cycling. When enabled, the proxy calls back to the editor to determine which playlist to use next, taking into account playlist stream limits and health state.
147
+
148
+
Configure this under **Settings → Preferences → Proxy** in the editor.
149
+
150
+
### Failover Resolver
151
+
152
+
| Setting | Description |
153
+
|---------|-------------|
154
+
|**Enable advanced failover logic**| Proxy calls the editor to resolve the next failover source based on playlist capacity |
155
+
|**Resolver URL**| The URL the proxy uses to reach the editor (e.g. `http://m3u-editor:36400`). Must be reachable from the proxy container |
156
+
157
+
When enabled, the proxy sends a request to the editor's resolver endpoint during failover, and the editor returns the best available backup source — respecting stream limits, marked-invalid playlists, and provider health.
158
+
159
+
### Fail Conditions
160
+
161
+
| Setting | Description |
162
+
|---------|-------------|
163
+
|**Enable playlist fail conditions**| Mark playlists as temporarily unavailable when specific HTTP errors are returned by the provider |
164
+
|**HTTP status codes**| Codes that trigger an invalid state (e.g. `403`, `404`, `502`, `503`) |
165
+
|**Invalid timeout (minutes)**| How long a playlist stays invalid before being retried. Default: 5 minutes |
166
+
|**Clear failed playlists**| Immediately un-marks all playlists currently flagged as invalid |
167
+
168
+
This is particularly useful when providers return `403` or `503` errors under load — the editor will temporarily route traffic away from that source without requiring a manual fix.
169
+
170
+
### Stream Limit Handling
171
+
172
+
| Setting | Description |
173
+
|---------|-------------|
174
+
|**Stop oldest stream when limit reached**| When a playlist's stream limit is hit, automatically stops the oldest active stream to free capacity for the new request. Enables instant channel switching on single-connection providers |
Copy file name to clipboardExpand all lines: docs/proxy/sticky-sessions.md
+18-8Lines changed: 18 additions & 8 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -34,17 +34,19 @@ Player: stream jumped, must reload
34
34
35
35
With sticky sessions enabled, after the first redirect the proxy locks to that backend for all subsequent requests, ensuring monotonic sequence progression.
36
36
37
-
## Configuration
37
+
## Enabling Sticky Sessions
38
38
39
-
### Global setting
39
+
There are three ways to enable sticky sessions, from most specific to most broad:
40
40
41
-
```bash
42
-
USE_STICKY_SESSION=true
43
-
```
41
+
### Per-Playlist (M3U Editor UI)
44
42
45
-
Default is `false`.
43
+
Open a playlist in the editor and go to the **Proxy Settings** section. Toggle **Enable Sticky Session Handler** on.
46
44
47
-
### Per-stream override
45
+
This applies to all channels from that playlist. It is the recommended approach — you can target only the providers that need it without affecting others.
46
+
47
+
### Per-Stream (Proxy API)
48
+
49
+
When calling the proxy API directly, pass `use_sticky_session: true` on the stream creation request:
48
50
49
51
```bash
50
52
curl -X POST "http://localhost:8085/streams" \
@@ -56,7 +58,15 @@ curl -X POST "http://localhost:8085/streams" \
56
58
}'
57
59
```
58
60
59
-
Per-stream settings override the global configuration.
61
+
### Globally (Environment Variable)
62
+
63
+
Enable for all streams:
64
+
65
+
```bash
66
+
USE_STICKY_SESSION=true
67
+
```
68
+
69
+
Default is `false`. Per-stream and per-playlist settings override the global configuration.
Copy file name to clipboardExpand all lines: docs/proxy/strict-live-ts.md
+24-8Lines changed: 24 additions & 8 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -54,16 +54,23 @@ Monitors upstream data flow. If no data arrives for more than 2 seconds (configu
54
54
55
55
HEAD requests for live TS streams return immediately without hitting the upstream provider. This avoids redundant connections that can interfere with live stream state.
56
56
57
-
## Quick Start
57
+
## Enabling Strict Live TS
58
58
59
-
### Enable globally (all live TS streams)
59
+
There are three ways to enable this feature, from most specific to most broad:
60
60
61
-
```bash
62
-
# .env or docker-compose environment
63
-
STRICT_LIVE_TS=true
64
-
```
61
+
### Per-Playlist (M3U Editor UI)
62
+
63
+
Open a playlist in the editor and go to the **Proxy Settings** section. Toggle **Enable Strict Live TS Handling** on.
64
+
65
+
This applies to all channels from that playlist. It is the recommended approach for most users — you can target specific providers without affecting others.
66
+
67
+
:::note
68
+
The **Enable Strict Live TS Handling** option is only relevant when the playlist is **not** using a transcoding profile. If a stream profile is assigned to the playlist, transcoding takes over and strict TS handling is bypassed.
69
+
:::
70
+
71
+
### Per-Stream (Proxy API)
65
72
66
-
### Enable per stream (via API)
73
+
When calling the proxy API directly, pass `strict_live_ts: true` on the stream creation request:
67
74
68
75
```bash
69
76
curl -X POST "http://localhost:8085/streams" \
@@ -76,7 +83,16 @@ curl -X POST "http://localhost:8085/streams" \
76
83
}'
77
84
```
78
85
79
-
Per-stream configuration overrides the global setting for that stream.
86
+
### Globally (Environment Variable)
87
+
88
+
Enable for all live TS streams across every playlist:
89
+
90
+
```bash
91
+
# .env or docker-compose environment
92
+
STRICT_LIVE_TS=true
93
+
```
94
+
95
+
Per-stream and per-playlist settings override the global setting for that specific stream.
0 commit comments