Hopefully this is not too dumb a question, apologies if it is.
I have a server with requests of different types arriving in various bursts in no order:
I can process each event concurrently, but each event of the same time must be processed sequentially, FIFO. In other words the processing of events, per worker, must be:
A1 A2 A3 A6
B4 B5 B9
C7 C8 C10 C11
I was looking at goque‘s Prefix Queue implementation, which states:
PrefixQueue is a FIFO (first in, first out) data structure that separates each given prefix into its own queue.
That sounds good on the queueing side, but I am having a very hard time finding modules or blog posts which implement the work pool side. Everything I see assumes that a pool should just grab whatever work is available, but I do not see an implementation of a pool where workers only process a task after the one right before it has finished.
Does what I am looking for make sense, and does such an implementation exist? TIA