yiisoft / yiisoft/yii2-queue

How to retrieve info about Job object from queue?

Open
#418 0 comments 4 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

help wanted type:enhancement
Dominant language
PHP
Stars
1.1k
Forks
285
Avg merge
5d 3h
Merged PRs (30d)
2

Description

How to get complete info about job in queue by it's ID?

What steps will reproduce the problem?

something like Yii::$app->queue->getJob(123);

What's expected?

It would be nice to get the object of job with it's status in queue and all properties.

What do you get instead?

Now I can only get general information in console, for exampla php yii queue/info shows only number of jobs. But how to get what exactly job objects are there in queue? I tried to use queue-monitor extension, but there were some problems with it.

Additional info
Q A
Yii version
PHP version
Operating system

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by reviewing the existing queue API and the php yii queue/info command; the issue does not name implementation files or tests. Compare the requested job ID lookup, status, and properties with the queue-monitor extension, then define an approach and tests showing that complete job information can be retrieved.

Written by the indexing model from the issue text.

Assessment

Tech stack
php
Domain
backend, distributed-systems
Issue type
Feature
Difficulty
5/5
Estimated time
Over a week
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.