Keepalive in App, doc fix

This commit is contained in:
Chris Boden 2016-02-11 09:49:46 -05:00
parent 7f532e1747
commit e986a76cbb
3 changed files with 6 additions and 2 deletions

View File

@ -113,6 +113,10 @@ class App {
$decorated = $controller; $decorated = $controller;
} }
if ($decorated instanceof WsServer) {
$decorated->enableKeepAlive($this->_server->loop, 30);
}
if ($httpHost === null) { if ($httpHost === null) {
$httpHost = $this->httpHost; $httpHost = $this->httpHost;
} }

View File

@ -25,7 +25,7 @@ class WsConnection extends AbstractConnectionDecorator {
} }
/** /**
* @param int|\Ratchet\RFC6455\Messaging\Protocol\DataInterface * @param int|\Ratchet\RFC6455\Messaging\DataInterface
*/ */
public function close($code = 1000) { public function close($code = 1000) {
if ($this->WebSocket->closing) { if ($this->WebSocket->closing) {

View File

@ -38,7 +38,7 @@ class WsServer implements HttpServerInterface {
private $closeFrameChecker; private $closeFrameChecker;
/** /**
* @var \Ratchet\RFC6455\Handshake\Negotiator * @var \Ratchet\RFC6455\Handshake\ServerNegotiator
*/ */
private $handshakeNegotiator; private $handshakeNegotiator;