[openamq-dev] Multiple consumers per session

Martin Sustrik sustrik at imatix.com
Fri Sep 28 16:46:03 CEST 2007


Birju,

I've tried and I can open several consumers from single session with no 
problem.

Can you send us your test program that exhibits the behaviour?

Thanks.
Martin

Birju Prajapati wrote:
> Hi,
> Am I only allowed one consumer per session? From one thread I'm trying
> to consume from 4 queues, starting 4 consumers from the same session,
> and it hangs on the call to start the second consumer.
> 
> The server warns of:
> cannot create consumer - too many consumers?
> 
> The only statement in the spec that I can see bearing any resemblance to
> my problem is in section 3.1.6, but this does not make it explicit that
> I cannot have more than one consumer per session - it just states that a
> consumer cannot be shared between channels (which the WireAPI doesn't
> let you do anyway).
> I also see in the spec (section 2.2.5) that it is 'encouraged' to use a
> channel per thread. However in OpenAMQ, this means that it is encouraged
> to use a connection per thread (as you can only have one channel per
> connection).
> Do I have to start a new session for each new consumer, and hence have a
> different connection/thread/process for each?
> 
> If that is the case, then I think it should be made explicit in the
> spec.
> 
> Thanks for your help,
> Birju
>  
> 
>  
> Schneider Trading
> 4th Floor,
> 25 Copthall Avenue
> London EC2R 7BP
> 
> --------------------------------------------------------
> 
> 
> 
> Message from: Birju.Prajapati at schneidertrading.com
> Message to: openamq-dev at lists.openamq.org
> Attached files: 0
> This e-mail and any files transmitted with it are confidential, may be legally privileged, and are for the sole use of the intended recipient. Copyright in this e-mail and any accompanying document created by us is owned by us. If you are not the intended recipient of this e-mail or any part of it please telephone our IT Department at the number shown above or by e-mail at info at schneidertrading.com. 
> You should not use or disclose to any other person the contents of this e-mail or its attachments (if any), nor take copies. This e-mail is not a representation or warranty and is not intended nor should it be taken to create any legal relations, contractual or otherwise.
> Schneider Trading Associates Ltd (Registration No. 3692131) is incorporated in England and Wales and the registered office is at 25 Copthall Avenue, London EC2R 7BP. The company is authorised and regulated by the Financial Services Authority
> _______________________________________________
> openamq-dev mailing list
> openamq-dev at lists.openamq.org
> http://lists.openamq.org/mailman/listinfo/openamq-dev



More information about the openamq-dev mailing list