public function getRemoteAddress()
{
return $this->parseAddress(stream_socket_get_name($this->stream, true));
}
/** * Handle process on close transport * * @param \React\Socket\Connection $conn */ public function handleClose(Connection $conn) { Logger::debug($this, "Raw socket closed " . $conn->getRemoteAddress()); $session = $this->sessions[$conn]; $this->sessions->detach($conn); $this->router->getEventDispatcher()->dispatch('connection_close', new ConnectionCloseEvent($session)); }