E
E
e-hot2016-12-21 10:29:40
symfony
e-hot, 2016-12-21 10:29:40

How to deal with error in php-amqplib in Symfony2?

Welcome all.
Need help who faced a similar situation:
1. There is a project on the local machine Ubuntu 14.04+nginx+mariadb+php5-fpm+rabbitmq.
2. Project on Symfony2. To work with rabbitmq in SF2, php-amqplib is installed - everything works fine, no complaints or errors.
3. Exactly the same (1v1) configuration of the working server on VPS and everything is exactly the same with Symfony2 with php-amqplib - up to php versions, SF2 libraries, rights and owners on folders and files, etc., but an error is generated:
2016/12/21 09:35:34 [error] 893#0: *292 FastCGI sent in stderr: "PHP message: PHP Fatal error: Class 'PhpAmqpLib\Connection\AMQPConnection' not found in
4. I searched on the Internet on this topic - the main reference to the lack of mention of extension=amqp.so in php.ini, but initially everything works for me on the local version of the project without extension=amqp.so. Anyone in the know, please explain what the real problem is. I encounter RabbitMQ in practice for the first time, I have not yet matured to understand some of the nuances.
Thanks in advance.

Answer the question

In order to leave comments, you need to log in

3 answer(s)
D
Denis, 2016-12-21
@prototype_denis

Connect lib in php.ini. Maybe you are looking at php.ini for "fpm", but there is also "cli" PHP_SAPI

I
ivankirshin, 2017-05-15
@ivankirshin

Solved a problem

SELECT w.name_worker,
       w.surname_worker,
       w.midname_worker,
       w.id_worker,
       SUM(number) numb
FROM workers w
LEFT JOIN exhours e ON (w.id_worker = e.id_worker)
LEFT JOIN orders o ON (e.id_order = o.id_order
                       AND o.datetime_order >= $date_start
                       AND o.datetime_order <= $date_end)
GROUP BY w.id_worker

M
mletov, 2017-05-14
@mletov

Instead of , and WHERE use LEFT JOIN and ON
in WHERE leave only date condition

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question