claimItem in the database and memory queues does not use expire correctly

Created on 11 July 2017, over 7 years ago
Updated 18 January 2023, almost 2 years ago

Problem/Motivation

Items in the queue cannot be reclaimed or get incorrect lease times leading to unexpected behaviour with expiration and claims.

There are three errors:

- The system cron only resets the expired items of the Database Queue. Memory queue items can never be reclaimed, because their expire value is never set to 0.
- The cron time and the lease time are incorrectly using the same value defined in the annotation of the queue worker.
- The lease time for items in cron-based queues are incorrectly set to 1 second.

Further details available in #25.

Proposed resolution

1. Let queues handle expiration of items themselves.
2. Fix the lease time for cron based queues.
3. Allow queueworkers to set specific lease times as well as cron times.

API changes

Added cron lease time in the QueueWorker annotation definition.

🐛 Bug report
Status

Needs work

Version

10.1

Component
Cron 

Last updated 25 days ago

No maintainer
Created by

🇺🇸United States kmoll

Live updates comments and jobs are added and updated live.
  • Needs subsystem maintainer review

    It is used to alert the maintainer(s) of a particular core subsystem that an issue significantly impacts their subsystem, and their signoff is needed (see the governance policy draft for more information). Also, if you use this tag, make sure the issue component is set to the correct subsystem. If an issue significantly impacts more than one subsystem, use needs framework manager review instead.

Sign in to follow issues

Comments & Activities

Not all content is available!

It's likely this issue predates Contrib.social: some issue and comment data are missing.

Production build 0.71.5 2024