Tagged articles

Delayed Task

2 articles · Page 1 of 1
Architect's Guide
Architect's Guide
Jun 20, 2026 · Backend Development

How to Auto‑Cancel Unpaid Orders After 30 Minutes: Design and Implementation Options

The article explains the concept of delayed tasks versus scheduled tasks and evaluates several backend solutions—including database polling with Quartz, JDK DelayQueue, Netty's HashedWheelTimer, Redis ZSET, Redis key‑space notifications, and RabbitMQ delayed queues—detailing their implementations, code samples, advantages, and drawbacks for automatically cancelling orders that remain unpaid for a set period.

Delayed TaskJavaQuartz
0 likes · 17 min read
How to Auto‑Cancel Unpaid Orders After 30 Minutes: Design and Implementation Options
dbaplus Community
dbaplus Community
May 6, 2026 · Backend Development

Why Scheduled Tasks Fail for Million‑Scale Order Cancellation and How Redis Solves It

The article dissects a common interview question about automatically canceling unpaid orders after 30 minutes, explains why naïve cron‑based scans are unsuitable for tens of millions of rows, and presents three progressively robust solutions using Redis expiration, Redis ZSet polling, and message‑queue or time‑wheel architectures.

Delayed TaskMessage QueueOrder Cancellation
0 likes · 10 min read
Why Scheduled Tasks Fail for Million‑Scale Order Cancellation and How Redis Solves It