File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -37,3 +37,9 @@ yii queue/listen [delay]
3737Если добавляются новые задания, то они сразу же извлекаются и выполняются. ` delay ` - время ожидания
3838в секундах перед следующим опросом очереди. Способ наиболее эфективен если запускать команду через
3939демон-супервизор, например ` supervisord ` .
40+
41+ ``` bash
42+ yii queue/info
43+ ```
44+
45+ Команда ` info ` выводит информацию о состоянии очереди.
Original file line number Diff line number Diff line change @@ -42,4 +42,3 @@ yii queue/info
4242```
4343
4444Команда ` info ` выводит информацию о состоянии очереди.
45-
Original file line number Diff line number Diff line change @@ -65,7 +65,7 @@ Yii::$app->queue->later(new DownloadJob([
6565]), 5 * 60);
6666```
6767
68- ** Внимание:** Драйвера AMQP и Gearman не поддреживают отложенные задания. И синхронный драйвер,
68+ ** Внимание:** Драйвера RebbitMQ и Gearman не поддреживают отложенные задания. И синхронный драйвер,
6969в отладочных целях, обрабатывает ` later() ` как обычный ` push() ` .
7070
7171
@@ -82,13 +82,13 @@ $id = Yii::$app->queue->push(new SomeJob());
8282Yii::$app->queue->isWaiting($id);
8383
8484// Воркер взял задание из очереди, и выполняет его.
85- Yii::$app->queue->isStarted ($id);
85+ Yii::$app->queue->isReserved ($id);
8686
8787// Воркер уже выполнил задание.
88- Yii::$app->queue->isFinished ($id);
89- ```
88+ Yii::$app->queue->isDone ($id);
89+ ```
9090
91- ** Внимание:** Драйвера AMQP не поддерживает статусы.
91+ ** Внимание:** Драйвер для RebbitMQ не поддерживает статусы.
9292
9393
9494Сообщения для сторонних воркеров
Original file line number Diff line number Diff line change @@ -36,3 +36,9 @@ yii queue/listen [delay]
3636obtained and executed. ` delay ` is time in seconds to wait between querying a queue next time.
3737This method is most effificient when command is properly daemonized via supervisor such as
3838` supervisord ` .
39+
40+ ``` bash
41+ yii queue/info
42+ ```
43+
44+ ` info ` command prints out information about queue status.
Original file line number Diff line number Diff line change @@ -41,4 +41,3 @@ yii queue/info
4141```
4242
4343` info ` command prints out information about queue status.
44-
Original file line number Diff line number Diff line change @@ -82,13 +82,13 @@ $id = Yii::$app->queue->push(new SomeJob());
8282Yii::$app->queue->isWaiting($id);
8383
8484// Worker gets the job from queue, end executing it.
85- Yii::$app->queue->isStarted ($id);
85+ Yii::$app->queue->isReserved ($id);
8686
8787// Worker has executed the job.
88- Yii::$app->queue->isFinished ($id);
89- ```
88+ Yii::$app->queue->isDone ($id);
89+ ```
9090
91- ** Important:** AMQP driver doesn't support job statuses.
91+ ** Important:** RebbitMQ driver doesn't support job statuses.
9292
9393
9494Messaging third party workers
You can’t perform that action at this time.
0 commit comments