createProcess() public method

Flags might be one of: Runtime::CREATE_DEFAULT - creates a new process only if it does not already exist Runtime::CREATE_FORCE_SOFT - does the same as CREATE_DEFAULT, but in case of existing process tries to replace it. Replacement is done by destroying existing process by sending shutdown message. Runtime::CREATE_FORCE_HARD - does the same as CREATE_DEFAULT, but in case of existing process tries to replace it. Replacement is done by forcefully destroying existing process. Runtime::CREATE_FORCE - creates a new process if it does not exist or tries to replace existing firstly trying to destroy it gracefully, but it fails doing it forcefully.
public createProcess ( string $alias, string $name, integer $flags = Runtime::CREATE_DEFAULT, mixed[] $params = [] ) : Kraken\Promise\PromiseInterface
$alias string
$name string
$flags integer
$params mixed[]
return Kraken\Promise\PromiseInterface
Example #1
0
 /**
  * @override
  * @inheritDoc
  */
 public function createProcess($alias, $name, $flags = Runtime::CREATE_DEFAULT, $params = [])
 {
     return $this->processManager->createProcess($alias, $name, $flags, $params);
 }