Skip to content

Commit

Permalink
add silent option to RoadRunner reset to remove info output which lea…
Browse files Browse the repository at this point in the history
…ds to non error (#525)
ResuBaka authored May 20, 2022

Verified

This commit was created on GitHub.com and signed with GitHub’s verified signature.
1 parent 5efb83d commit f0cb7b8
Showing 2 changed files with 2 additions and 1 deletion.
1 change: 1 addition & 0 deletions src/RoadRunner/ServerProcessInspector.php
Original file line number Diff line number Diff line change
@@ -51,6 +51,7 @@ public function reloadServer(): void
$this->findRoadRunnerBinary(),
'reset',
'-o', "rpc.listen=tcp://$host:$rpcPort",
'-s',
], base_path()))->start()->waitUntil(function ($type, $buffer) {
if ($type === Process::ERR) {
throw new RuntimeException('Cannot reload RoadRunner: '.$buffer);
2 changes: 1 addition & 1 deletion tests/RoadRunnerServerProcessInspectorTest.php
Original file line number Diff line number Diff line change
@@ -62,7 +62,7 @@ public function test_roadrunner_server_process_can_be_reloaded()
]);

$processFactory->shouldReceive('createProcess')->with(
[$this->findRoadRunnerBinary(), 'reset', '-o', 'rpc.listen=tcp://127.0.0.1:6002'],
[$this->findRoadRunnerBinary(), 'reset', '-o', 'rpc.listen=tcp://127.0.0.1:6002', '-s'],
base_path(),
)->andReturn($process = Mockery::mock('stdClass'));

0 comments on commit f0cb7b8

Please sign in to comment.