mirror of
https://github.com/Vateron-Media/XC_VM.git
synced 2026-10-04 04:02:30 +02:00
Revert PR #1 (feat/daemon-monitor): panel-side encoder supervision
Reverts the five commits PR #1 brought in and the two test follow-ups made after it merged:a1d454feEnhance assertions in FanoutConfigTest19607a91Update StreamProcessBuildLiveTest.phpb3714269fix(fanout): stop, force and rogue-kill must account for the daemoncea545fefeat(fanout): reconcile supervised streams back into the panel8e24a242feat(fanout): make encoder supervision a real, settable option8244ece1feat(fanout): health policy, source forcing and supervision reconcile56c0619efeat(fanout): hand live encoders to the daemon to supervise Only those. The upstream commits that reached main through the same merge (the GeoIP refactor, release 2.5.0, the update guard, the mass-page fix) stay: reverting the merge commit itself would have taken them out too. The panel side of supervision is re-done in the commits that follow, together with the xc_fanout native remuxer (xc_fanout 0.13.0): every live stream handed to the daemon's monitor, copy-only streams run on `xc_fanout remux` instead of ffmpeg, the ffmpeg command as an explicit fallback. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_012QL93N6dzGkmKoQgA4oh16
This commit is contained in:
@@ -116,35 +116,6 @@ final class StreamProcessBuildLiveTest extends TestCase {
|
||||
$this->assertStringContainsString('-progress "' . STREAMS_PATH . '42_.progress"', $out);
|
||||
$this->assertStringContainsString("-i 'http://src.example/live.ts'", $out);
|
||||
$this->assertStringContainsString(STREAMS_PATH . '42_%d.ts', $out, 'hls segments');
|
||||
}
|
||||
|
||||
// ── the redirect tail is no longer buildLive's ─────────────
|
||||
|
||||
/**
|
||||
* buildLive returns the BARE command. It used to append
|
||||
* `>/dev/null 2>>…errors & echo $! > …pid` itself; that tail moved to
|
||||
* liveRedirectTail() so the same command can either be run here or handed to
|
||||
* the fanout daemon, which supervises the process and therefore has to be its
|
||||
* parent — a backgrounded command leaves it nothing to supervise and no pid
|
||||
* to signal.
|
||||
*
|
||||
* Asserting the ABSENCE is the point. If the tail ever creeps back into
|
||||
* buildLive, every supervised stream silently stops being supervised, and the
|
||||
* only symptom is channels that will not restart.
|
||||
*/
|
||||
public function testBareCommandCarriesNoRedirectOrBackgroundTail(): void {
|
||||
$out = $this->build();
|
||||
$this->assertStringNotContainsString('>/dev/null', $out, 'buildLive must not redirect; its caller decides');
|
||||
$this->assertStringNotContainsString('echo $! >', $out, 'buildLive must not background the process');
|
||||
$this->assertStringNotContainsString('2>>' . STREAMS_PATH . '42.errors', $out);
|
||||
}
|
||||
|
||||
/**
|
||||
* And the legacy composition still yields exactly what buildLive used to, so
|
||||
* the path that runs the encoder itself is byte-for-byte unchanged.
|
||||
*/
|
||||
public function testLegacyTailRestoresThePreviousCommand(): void {
|
||||
$out = $this->build() . StreamProcess::liveRedirectTail(42);
|
||||
$this->assertStringContainsString('>/dev/null 2>>' . STREAMS_PATH . '42.errors', $out);
|
||||
$this->assertStringContainsString('echo $! > ' . STREAMS_PATH . '42_.pid', $out);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user