benonymus

benonymus

Fairness in message queue system

Hey there,

We are currently using Oban in a multi-tenant application with shared queues.

We are running into a problem with noisy-neighbors. When one user can flood the queue and take up all the available resources making others wait.

Problems described here in more detail:

https://medium.com/thron-tech/multi-tenancy-and-fairness-in-the-context-of-microservices-sharded-queues-e32ee89723fc

We tried out global partitioning: Oban.Pro.Engines.Smart — Oban Pro v1.5.2
While this works as advertised, it locks in the big user to their limit when there is no other jobs in the queue leaving capacity on the table.

Changing priority during inserting the jobs is not going to work. We want to process the big user’s jobs just as the small ones. We are looking for fairness but also full capacity utilization (as far as local limits go on a queue).

I was looking at some options that the links mention, to have separate queues per customer and some load balancer load the jobs into the actual queue but we would end up with a lot of queues and that seems to be a bad thing.

Has anyone implemented something like this or have some ideas?

I am open to other message queues or systems if they address the concern.

Thank you

Most Liked

sorenone

sorenone

Oban Core Team

Hi @benonymus,

We’ve heard of this issue before. We’re currently slating a “burst” option, (For Pro v1.6),
that will help keep the queue saturated.
For now, you could rescale the queue manually with Oban.scale_queue/1 if you have certain periods of lower activity.

Where Next?

Popular in Questions Top

Qqwy
Original source of discussion: This topic on the Pragmatic Programmers’ Functional Web Development with Elixir, OTP, and Phoenix forum. ...
New
Brian
What is the proper way to load a module from a file in to IEX? In the python world, doing something like this pretty standard: from ....
New
Darmani72
If I have a post route which an argument: post /my_post_route/:my_param1, MyController.my_post_handler How would get the post params ...
New
fireproofsocks
Forgive me if this is obvious, but how does one delete a database record WITHOUT selecting it first? Ecto.Repo — Ecto v3.14.0 has exampl...
New
komlanvi
Hi everyone, I was playing with phoenix liveView but I run into an issue. I have a form and want to validate each input text when the te...
New
bsollish-terakeet
Credo is smart enough to check for (something like) this: assert length(the_list) == 0 with this response: Checking if an enum is empt...
New
albydarned
Hello all! I am typing this post from my new MacBook Pro with the M1 chip. I’m loving it so far, and will probably use it as my daily dr...
New

Other popular topics Top

KronicDeth
Elixir plugin for JetBrain’s IntelliJ Platform (including Rubymine) This is a plugin that adds support for Elixir to JetBrains IntelliJ...
289 36689 110
New
hariharasudhan94
I would like to know what is the best IDE for elixir development?
New
jononomo
For some reason my phoenix channels are working for me in my local dev environment, but as soon as I deploy via Docker, I get a 403 error...
New
joeerl
Hello again - after a longish gap I’ve decided I really must dig into Elixir and see what’s been happening here - so I have a few questio...
New
romenigld
I am trying to run a deploy with docker and I successfully runned with this command: docker build -t romenigld/blog-prod . but when I t...
New
AstonJ
Posting this to see if we can make things easier for people to get into Neovim. If you use Neovim and have a favourite distro please let ...
New

We're in Beta

About us Mission Statement