Php swoole server message push

<?php
namespace app\index\controller;

class Pay {
  
    public function notice(){
        //websocket  $server
    }
} 

swoole can use $server- > push () ;

only if you get $server .

but how to solve this problem when you can"t get $server when you want to push messages to the client on the server?

is it necessary to use swoole websocket_client to connect websocket_server ;
use client to server send data before server wants to push to the client?

Apr.25,2022

you can get the server.
list as follows:

  

about swoole actively sending messages to the client client- > server, how to realize the websocket client asynchronism can only be used in cli mode, and how to implement fpm, ask the boss to tell me!!

MySQL Query : SELECT * FROM `codeshelper`.`v9_news` WHERE status=99 AND catid='6' ORDER BY rand() LIMIT 5
MySQL Error : Disk full (/tmp/#sql-temptable-64f5-1e84192-4e17c.MAI); waiting for someone to free some space... (errno: 28 "No space left on device")
MySQL Errno : 1021
Message : Disk full (/tmp/#sql-temptable-64f5-1e84192-4e17c.MAI); waiting for someone to free some space... (errno: 28 "No space left on device")
Need Help?