Skip to content

Commit

Permalink
Maintenance/update composer (#70)
Browse files Browse the repository at this point in the history
* - Updates composer
- Fixes queue config
- Throws an exception if frontend file not found

* Fixes error Undefined constant Spiral\RoadRunner\Tcp\TcpWorkerInterface::XXX
  • Loading branch information
butschster committed Sep 6, 2023
1 parent 7148d8e commit 281ee31
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 8 deletions.
4 changes: 2 additions & 2 deletions app/modules/Monolog/Interfaces/TCP/Service.php
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
use App\Application\Commands\HandleReceivedEvent;
use Spiral\Cqrs\CommandBusInterface;
use Spiral\RoadRunner\Tcp\Request;
use Spiral\RoadRunner\Tcp\TcpWorkerInterface;
use Spiral\RoadRunner\Tcp\TcpEvent;
use Spiral\RoadRunnerBridge\Tcp\Response\CloseConnection;
use Spiral\RoadRunnerBridge\Tcp\Response\ContinueRead;
use Spiral\RoadRunnerBridge\Tcp\Response\ResponseInterface;
Expand All @@ -22,7 +22,7 @@ public function __construct(

public function handle(Request $request): ResponseInterface
{
if ($request->event === TcpWorkerInterface::EVENT_CONNECTED) {
if ($request->event === TcpEvent::Connected) {
return new ContinueRead();
}

Expand Down
6 changes: 3 additions & 3 deletions app/modules/Smtp/Interfaces/TCP/Service.php
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
use Spiral\Cache\CacheStorageProviderInterface;
use Spiral\Cqrs\CommandBusInterface;
use Spiral\RoadRunner\Tcp\Request;
use Spiral\RoadRunner\Tcp\TcpWorkerInterface;
use Spiral\RoadRunner\Tcp\TcpEvent;
use Spiral\RoadRunnerBridge\Tcp\Response\CloseConnection;
use Spiral\RoadRunnerBridge\Tcp\Response\RespondMessage;
use Spiral\RoadRunnerBridge\Tcp\Response\ResponseInterface;
Expand All @@ -37,7 +37,7 @@ public function __construct(

public function handle(Request $request): ResponseInterface
{
if ($request->event === TcpWorkerInterface::EVENT_CONNECTED) {
if ($request->event === TcpEvent::Connected) {
return $this->send(self::READY, 'mailamie');
}

Expand All @@ -46,7 +46,7 @@ public function handle(Request $request): ResponseInterface

$response = new CloseConnection();

if ($request->event === TcpWorkerInterface::EVENT_CLOSED) {
if ($request->event === TcpEvent::Close) {
$this->cache->delete($cacheKey);

return new CloseConnection();
Expand Down
5 changes: 2 additions & 3 deletions app/modules/VarDumper/Interfaces/TCP/Service.php
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
use Modules\VarDumper\Application\Dump\MessageParser;
use Spiral\Cqrs\CommandBusInterface;
use Spiral\RoadRunner\Tcp\Request;
use Spiral\RoadRunner\Tcp\TcpWorkerInterface;
use Spiral\RoadRunner\Tcp\TcpEvent;
use Spiral\RoadRunnerBridge\Tcp\Response\ContinueRead;
use Spiral\RoadRunnerBridge\Tcp\Response\ResponseInterface;
use Spiral\RoadRunnerBridge\Tcp\Service\ServiceInterface;
Expand All @@ -24,8 +24,7 @@ public function __construct(

public function handle(Request $request): ResponseInterface
{
dump($request);
if ($request->event === TcpWorkerInterface::EVENT_CONNECTED) {
if ($request->event === TcpEvent::Connected) {
return new ContinueRead();
}

Expand Down

0 comments on commit 281ee31

Please sign in to comment.