[rabbitmq-discuss] Persistent connections with Amqphp
majek04 at gmail.com
Thu Jul 7 13:46:54 BST 2011
On Wed, Jul 6, 2011 at 19:24, Robin Harvey <harvey.robin at gmail.com> wrote:
> A couple of people recently asked about support for persistent connections,
> after a bit of hacking around I've uploaded an update which has basic
> persistent connection support: https://github.com/BraveSirRobin/amqphp
> (check the 0.9.1 tag)
> I'd be interested to hear what the RabbitMQ people think about the likely
> behavior of PHP "persistent connections", which may include:
> * If the web server is restarted, all open client connections are dropped
> without going through the amqp shutdown sequence, so you get lots of "closed
> abruptly" errors in the log.
I don't think there is a workaround. Maybe there is a atexit(3)
equivalent in php?
> * If a web server has no web requests to process then the persistent client
> can't respond to any messages the broker sends; the client will "go quiet".
It should be fine as far as the TCP/IP connection is intact. But don't use
AMQP heartbeats :)
More information about the rabbitmq-discuss