Swoole Server heartbeat

public mixed Swoole\Server::heartbeat ( boolean $if_close_connection )

Check status of all the connections of the server. Optionally close the idle and timeout connections.

Parameter

  • $if_close_connection the option which decides if close the connections which exceeds the time

Return

The array of connections

Example