public function handleRouterStop(RouterStopEvent $event) { if ($this->server) { $this->server->shutdown(); } foreach ($this->sessions as $k) { $this->sessions[$k]->shutdown(); } }