Re: Throttling per activemq consumer

2016-06-27 Thread hasikada
We have multiple consumers (workers) on activemq queue. The message groups secure that messages within one message group are delivered to one selected consumer. As we have multiple consumers the messages from different message groups can be processed in parallel. I expected the throttling is done p

Throttling per activemq consumer

2016-06-03 Thread hasikada
Let's say have I have multiple activemq consumers (jms.concurrentConsumers=20), I use message groups, so incomming messages has JMSXGroupID header set and I would like to enable throttling per message group in Camel. from("activemq:queue:test") .throttle(1).timePeriodMillis(3L)

Re: Producer-consumer problem in Camel

2015-12-08 Thread hasikada
And this one would be the final solution, sorry for distribution: from("activemq:queue:requests").to("direct:processRequest?exchangePattern=InOut"); from("direct:handleUserRequest") .to(ExchangePattern.InOnly, "activemq:queue:requests") .

Re: Producer-consumer problem in Camel

2015-12-08 Thread hasikada
Hello again, this is the solution what I found after playing with seda, load balancer, wiretap: ExecutorService execExecutorService = new ThreadPoolBuilder(getContext()) .poolSize(1).maxPoolSize(1).maxQueueSize(10).build("InvoiceExecutorService"); from("direct:handleUs

Re: Producer-consumer problem in Camel

2015-12-03 Thread hasikada
Hello, When setting option 'waitForTaskToComplete=Never' the 'handleUserRequest' route puts an exchange to seda queue and immediately responds to user 'Your request .'. I would expect the setting 'concurrentConsumers=1' makes that the exchanges from seda queue are processed one by one in 'dire

Producer-consumer problem

2015-12-01 Thread hasikada
Hello gentlemen, Please, how to implement *producer-consumer problem* (bounded-buffer) in Camel. One route puts exchanges to shared queue (e.g on user request). Second route processes exchanges from shared queue *one by one*. The first route doesn't wait for exchange processing completion. from(

Multiple Camel contexts and request to multiple replies communication pattern (multicast)

2015-06-29 Thread hasikada
Hello, I work on the ESB (entiprise service bus) project based on Apache Camel running on Apache Karaf. The ESB provides several different services, Each service provides REST API (e.g TestRest), service routes (e.g TestService) and service beans (e.g TestBean). The service classs contains one CXF