cybozu/php-yrmcds — pull request #2 by nojima (2013-10-18 01:09:50+00:00)
Title: Add option to constructor of \yrmcds\Client for detecting stale connection

In order to detect stale persistent connections, the new argument `detect_stale_connection` is added to the constructor of `\yrmcds\Client`. When `detect_stale_connection` is true, the constructor sends "noop" command though an existing persistent connection. If the response is correctly received, we can use the persistent connection. Otherwise, we discards the (broken) connection and establish a new persistent connection.

As the side effect, the constructor discards all unreceived responses and the results of all "quiet" commands.