activemq-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Justin Bertram <jbert...@apache.org>
Subject Re: ActiveMQ prevent consumer handling specific message
Date Mon, 02 Jul 2018 16:30:15 GMT
I provided an answer on your Stack Overflow question [1].


Justin

[1]
https://stackoverflow.com/questions/51124070/activemq-prevent-consumer-handling-specific-message

On Mon, Jul 2, 2018 at 4:07 AM, itaym <imasarano@gmail.com> wrote:

> We have a design challenge where the situation is as follow:
>
> There are multiple producers and multiple consumers (on same queue).
>
> Each message represent a task with parameters that consumer needs to
> handle.
>
> The problem is that there are certain tasks that take lots of memory (and
> cpu power) which we know the consumer have no capacity to handle this. the
> good thing is that we know how much memory (and cpu power) it approximately
> can take in advance, so we could prevent a consumer taking that task and
> giving a change to other consumer with enough memory to handle.
>
> There is the prefetch setting but i can't see how it can configure to meet
> this requirement
>
> Finally I found an option to rollback a transaction, so the consumer can
> basically check if it has enough hardware resources to handle the task and
> if not rollback which retrieves the message back to queue allowing next
> consumer take it and so forth.
>
> Not sure if that's the right approach or there is a better way?
>
>
>
> --
> Sent from: http://activemq.2283324.n4.nabble.com/ActiveMQ-Dev-
> f2368404.html
>

Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message