Process

Introduction

Swoole Process can be attached and managed by Swoole Server with addProcess API.

Swoole Process can be used to replace PHP pcntl extension. Compare with PHP pcntl, Swoole Process provides more features:

  • IPC based on unixsock, with read/write or push/pop API.
  • Redirect standard I\O
  • The child processes are able to use Swoole\Event.
  • Exec API allows the child process execute native Linux command and communicate with the parent process

Methods

  • Swoole\Process::__construct
  • Swoole\Process->start
  • Swoole\Process->name
  • Swoole\Process->exec
  • Swoole\Process->write
  • Swoole\Process->useQueue
  • Swoole\Process->statQueue
  • Swoole\Process->freeQueue
  • Swoole\Process->push
  • Swoole\Process->pop
  • Swoole\Process->close
  • Swoole\Process->exit
  • Swoole\Process->kill
  • Swoole\Process->wait
  • Swoole\Process->daemon
  • Swoole\Process->signal
  • Swoole\Process->alarm
  • Swoole\Process->setAffinity