55 days ago · 5 min read1068 words · Tech · hide · Fediverse post

Lots of our software needs queue-like behavior. So, for example: Suppose every new user needs to be registered in four subsystems. You might do the registration synchronously in one subsystem, enqueue the information necessary to do the rest, and let asynchronous workers process those events. More generally, suppose you process user requests that don't need to be handled synchronously. Those requests tend to come in bursts, so you might enqueue those requests and let workers handle them. Your workers will usually be provisioned so that processing is near-synchronous except after a burst, when the queue will take a while to drain. Suppose you'd like to offer a non-essential feature that requires expensive processing (e.g., if you're running a video hosting side and offering AI analysis of the videos). Queues are a popular solution: candidates for the expensive process are enqueued, and as you have time or budget, you pick candidates off the queue. So I, like many of us, have spent a…

Commenting on Bubbles has been removed. Why? If you want to talk about this post, write to the author, use the comments on their blog if it has them, or reply with a "RE:" post on your own blog. Suggestions? feedback@bubbles.town