PHP code example of kcloze / multiprocess

1. Go to this page and download the library: Download kcloze/multiprocess library. Choose the download type require.

2. Extract the ZIP file and open the index.php.

3. Add this code to the index.php.
    
        
<?php
require_once('vendor/autoload.php');

/* Start to develop here. Best regards https://php-download.com/ */

    

kcloze / multiprocess example snippets


    'logPath'   => __DIR__ . '/log',
    'exec'      => [
        [
            'name'      => 'kcloze-test-1',
            'bin'       => '/usr/bin/php',
            'binArgs'   => [__DIR__ . '/test/test.php', 'oop', '123'],
            'workNum'   => 3,
        ],
        [
            'name'      => 'kcloze-test-2',
            'bin'       => '/usr/bin/php',
            'binArgs'   => [__DIR__ . '/test/test2.php', 'oop', '456'],
            'workNum'   => 5,
        ],
        [
            'name'      => 'kcloze-test-3',
            'bin'       => '/usr/bin/python',
            'binArgs'   => [__DIR__ . '/test/test3.py', 'oop', '369'],
            'workNum'   => 2,
        ],
    ],


./multiprocess.php start|stop|exit|restart