update : 2015.11.03
php.shukuma.com검색:
|
GearmanClient::addTaskStatus(PECL gearman >= 0.5.0) GearmanClient::addTaskStatus — Add a task to get status 설명Used to request status information from the Gearman server, which will call the specified status callback (set using GearmanClient::setStatusCallback()). 인수
반환값A GearmanTask object. 예제
Example #1 Monitor completion of multiple background tasks An artificial delay is introduced in the worker in this example to simulate a long running process. There is only one worker running for this example.
<?php 위 예제의 출력 예시: Done: 0 Done: 0 Done: 0 Done: 0 Done: 0 Done: 0 Done: 0 Done: 0 Done: 0 Done: 0 Done: 0 Done: 0 Done: 1 Done: 1 Done: 1 Done: 1 Done: 1 Done: 1 Done: 1 Done: 1 Done: 1 Done: 1 Done: 1 Done: 1 Done: 2 |