statusengine / worker

PHP worker process that writes all event data to a storage backend
https://statusengine.org/worker/#overview
GNU General Public License v3.0
9 stars 8 forks source link

Add support for RabbitMQ #6

Closed nook24 closed 6 years ago

nook24 commented 6 years ago

Add support for RabbitMQ

nook24 commented 6 years ago

Basic RabbitMQ works. Strange behavior on SIGINT:

[23:13]root@statusengine16:/opt/statusengine/worker# bin/StatusengineWorker.php
statusengine-worker[9609]: Starting Statusengine-Worker Version 3.2.0
statusengine-worker[9609]: Fork new host status worker
statusengine-worker[9609]: Fork new service status worker
statusengine-worker[9609]: Fork new log entry worker
statusengine-worker[9609]: Fork new state change worker
statusengine-worker[9609]: Fork new host check worker
statusengine-worker[9609]: Fork new service check worker
statusengine-worker[9609]: Fork new misc worker
statusengine-worker[9609]: Fork new performance data worker
statusengine-worker[9609]: Finished daemonizing
^CPHP Warning:  stream_select(): unable to select [4]: Interrupted system call (max_fd=16) in /opt/statusengine/worker/src/RabbitMqWorker.php on line 172
PHP Warning:  stream_select(): unable to select [4]: Interrupted system call (max_fd=9) in /opt/statusengine/worker/src/RabbitMqWorker.php on line 172
PHP Warning:  stream_select(): unable to select [4]: Interrupted system call (max_fd=6) in /opt/statusengine/worker/src/RabbitMqWorker.php on line 172
PHP Warning:  stream_select(): unable to select [4]: Interrupted system call (max_fd=18) in /opt/statusengine/worker/src/RabbitMqWorker.php on line 172
PHP Warning:  stream_select(): unable to select [4]: Interrupted system call (max_fd=14) in /opt/statusengine/worker/src/RabbitMqWorker.php on line 172
PHP Warning:  stream_select(): unable to select [4]: Interrupted system call (max_fd=20) in /opt/statusengine/worker/src/RabbitMqWorker.php on line 172
PHP Warning:  stream_select(): unable to select [4]: Interrupted system call (max_fd=12) in /opt/statusengine/worker/src/RabbitMqWorker.php on line 172
PHP Warning:  stream_select(): unable to select [4]: Interrupted system call (max_fd=22) in /opt/statusengine/worker/src/RabbitMqWorker.php on line 172
PHP Warning:  stream_select(): unable to select [4]: Interrupted system call (max_fd=24) in /opt/statusengine/worker/src/RabbitMqWorker.php on line 172
The connection timed out after 3 sec while awaiting incoming dataStatusengine\Config\Hoststatus Object
(
    [queueName:Statusengine\Config\Hoststatus:private] => statusngin_hoststatus
)
statusengine-worker[9609]: Bye