-
-
Notifications
You must be signed in to change notification settings - Fork 18
Open
Description
Actually, the producer is also the consumer
You should spread this to the producer and consumer.
class Producer extends ProducerService
{
public function __construct(private int $user_id)
{}
}class Consumer
{
public function __construct(private UserService $userService){}
public function process(ProducerService $producer)
{
$user_id = $producer->getUser();
$userService->sendEmail($user_id);
}
}