You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@activemq.apache.org by Dave_G <gg...@yahoo.com> on 2006/04/10 22:56:02 UTC

Executing on message arrival - something like runmqchi?

I wonder if a C or Java client has ever written that gives the equivalent of
the IBM MQSeries runmqchi - running a Unix command line when a message
arrives.

Dave
--
View this message in context: http://www.nabble.com/Executing-on-message-arrival---something-like-runmqchi--t1427679.html#a3850260
Sent from the ActiveMQ - User forum at Nabble.com.


Re: Executing on message arrival - something like runmqchi?

Posted by Hiram Chirino <hi...@hiramchirino.com>.
On 4/18/06, James Strachan <ja...@gmail.com> wrote:
> On 4/18/06, Hiram Chirino <hi...@hiramchirino.com> wrote:
> > I definitely think we need to implement a process pool type thing
> > where we can configure min/max
> > processes that we start up per destination etc.  Perhaps we do this in
> > the broker.  Since he is keeping track of how full the consumer
> > prefetch is, he's probably the best guy to know when a new  consumer
> > process needs to get spun up.
>
> We could just use Jencks which does the pooling of POJOs and threads;
> then make each onMessage() call wait until the process quits; then we
> can use the thread & POJO pooling to control how much concurrency we
> allow per thread etc?
>

That would be possible but then Jencks need to deliver the message to
the spawned process since it has consumed the message from activemq. 
So Jencks would end up being something like a CGI container almost
like an httpd server.  Which is cool but different from what
"runmqchi" does.  runmqchi monitors queue depths and launches
processes to consume those messages.  Those processes connect back to
the message broker to actually get the message.


> --
>
> James
> -------
> http://radio.weblogs.com/0112098/
>


--
Regards,
Hiram

Re: Executing on message arrival - something like runmqchi?

Posted by James Strachan <ja...@gmail.com>.
On 4/18/06, Hiram Chirino <hi...@hiramchirino.com> wrote:
> I definitely think we need to implement a process pool type thing
> where we can configure min/max
> processes that we start up per destination etc.  Perhaps we do this in
> the broker.  Since he is keeping track of how full the consumer
> prefetch is, he's probably the best guy to know when a new  consumer
> process needs to get spun up.

We could just use Jencks which does the pooling of POJOs and threads;
then make each onMessage() call wait until the process quits; then we
can use the thread & POJO pooling to control how much concurrency we
allow per thread etc?

--

James
-------
http://radio.weblogs.com/0112098/

Re: Executing on message arrival - something like runmqchi?

Posted by Hiram Chirino <hi...@hiramchirino.com>.
I definitely think we need to implement a process pool type thing
where we can configure min/max
processes that we start up per destination etc.  Perhaps we do this in
the broker.  Since he is keeping track of how full the consumer
prefetch is, he's probably the best guy to know when a new  consumer
process needs to get spun up.


On 4/18/06, James Strachan <ja...@gmail.com> wrote:
> FWIW it'd be pretty easy to write a single MessageListener which when
> a message arrives, it just runs some unix command line. I guess the
> tricky part is how do you map the JMS message to the command line
> arguments etc?
>
> On 4/10/06, Dave_G <gg...@yahoo.com> wrote:
> >
> > I wonder if a C or Java client has ever written that gives the equivalent of
> > the IBM MQSeries runmqchi - running a Unix command line when a message
> > arrives.
> >
> > Dave
> > --
> > View this message in context: http://www.nabble.com/Executing-on-message-arrival---something-like-runmqchi--t1427679.html#a3850260
> > Sent from the ActiveMQ - User forum at Nabble.com.
> >
> >
>
>
> --
>
> James
> -------
> http://radio.weblogs.com/0112098/
>


--
Regards,
Hiram

Re: Executing on message arrival - something like runmqchi?

Posted by James Strachan <ja...@gmail.com>.
FWIW it'd be pretty easy to write a single MessageListener which when
a message arrives, it just runs some unix command line. I guess the
tricky part is how do you map the JMS message to the command line
arguments etc?

On 4/10/06, Dave_G <gg...@yahoo.com> wrote:
>
> I wonder if a C or Java client has ever written that gives the equivalent of
> the IBM MQSeries runmqchi - running a Unix command line when a message
> arrives.
>
> Dave
> --
> View this message in context: http://www.nabble.com/Executing-on-message-arrival---something-like-runmqchi--t1427679.html#a3850260
> Sent from the ActiveMQ - User forum at Nabble.com.
>
>


--

James
-------
http://radio.weblogs.com/0112098/

Re: Executing on message arrival - something like runmqchi?

Posted by Hiram Chirino <hi...@hiramchirino.com>.
Hi Dave,

We don't have that yet, but contributions are welcomed!

Regards,
Hiram

On 4/10/06, Dave_G <gg...@yahoo.com> wrote:
>
> I wonder if a C or Java client has ever written that gives the equivalent of
> the IBM MQSeries runmqchi - running a Unix command line when a message
> arrives.
>
> Dave
> --
> View this message in context: http://www.nabble.com/Executing-on-message-arrival---something-like-runmqchi--t1427679.html#a3850260
> Sent from the ActiveMQ - User forum at Nabble.com.
>
>


--
Regards,
Hiram