Disabled RabbitMQ

This commit is contained in:
Netkas 2023-02-09 17:27:24 -05:00
parent f82f1ca26a
commit 8cb6c2d65b

View file

@ -1,5 +1,7 @@
<?php
/** @noinspection PhpMissingFieldTypeInspection */
namespace TamerLib\Classes;
use Exception;
@ -61,7 +63,7 @@
return match (strtolower($protocol))
{
ProtocolType::Gearman => new \TamerLib\Protocols\Gearman\Client($username, $password),
ProtocolType::RabbitMQ => new \TamerLib\Protocols\RabbitMq\Client($username, $password),
ProtocolType::RabbitMQ => throw new InvalidArgumentException('RabbitMQ is not fully implemented yet'),
default => throw new InvalidArgumentException('Invalid protocol type'),
};
}
@ -78,7 +80,7 @@
return match (strtolower($protocol))
{
ProtocolType::Gearman => new \TamerLib\Protocols\Gearman\Worker($username, $password),
ProtocolType::RabbitMQ => new \TamerLib\Protocols\RabbitMq\Worker($username, $password),
ProtocolType::RabbitMQ => throw new InvalidArgumentException('RabbitMQ is not fully implemented yet'),
default => throw new InvalidArgumentException('Invalid protocol type'),
};
}