You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@camel.apache.org by Claus Ibsen <cl...@gmail.com> on 2010/03/12 16:29:18 UTC

Re: Producer Template-CamelTemplate does not stop the DefaultMessageListener after reading the response from Weblogic JMS queue.

Hi

Read about Spring DMLC and JMS gothas and whatnot.

You need to use pooled connection factories and whatnot.
Spring DMLC has a background job that keeps connection to see if there
is any new messages.



On Fri, Mar 12, 2010 at 4:08 PM, Gayathri Ramaka <gr...@arccorp.com> wrote:
>
> I am trying to use the ProducerTemplate sendBodyAndHeader feature. I am able
> to send and reccieve the message. But, After receiving the mssage, the
> Default Message Listener is not stopping. As a result, I do see the
> consumers total count on the weblobgic queue is constatly increasing. Is
> this a normal behavior or is a bug in Camel?
>
> here are the details:
>
> Camel Version - 2.0
> JMS Env - Weblogic 9.2
> Application Mode - The Temaplte is a Standalone Java application running in
> a eclipse env. .
>
>
> Code Snippet:
>
> public String testProducerTemplate(String requestQueue,String responseQueue,
> int timeOut, ExchangePattern pattern, String message, String
> messageCorrelationId) {
>  ApplicationContext context = new ClassPathXmlApplicationContext(
>    "camel-context.xml");
>  org.apache.camel.ProducerTemplate camelTemplate =
> (org.apache.camel.ProducerTemplate) context
>    .getBean("camelTemplate");
>  CamelContext camel = (CamelContext) context.getBean("camel");
>  Endpoint endPoint = camel.getEndpoint(requestQueue
>    + "?preserveMessageQos=true&replyTo=" + responseQueue
>    + "&receiveTimeout=" + timeOut);
>  String response = (String) camelTemplate.sendBodyAndHeader(endPoint,
> pattern, message, "JMSCorrelationID", messageCorrelationId);
>  System.out.println("... the result is: " + response);
>  try {
>   camelTemplate.stop();
>  } catch (Exception e) {
>   e.printStackTrace();
>  }
>
> }
>
>
> Logs :
>
>
> [aultMessageListenerContainer-1] efaultMessageListenerContainer TRACE
> Consumer [weblogic.jms.client.WLConsumerImpl@3508c0] of session
> [weblogic.jms.client.WLSessionImpl@1d183b7] did not receive a message
>
> [aultMessageListenerContainer-1] efaultMessageListenerContainer DEBUG
> Received message of type [class weblogic.jms.common.TextMessageImpl] from
> consumer [weblogic.jms.client.WLConsumerImpl@165ab39] of session
> [weblogic.jms.client.WLSessionImpl@1d183b7]
>
> [aultMessageListenerContainer-1] Requestor DEBUG Message correlationID:
> 12345
>
> [ main] JmsProducer DEBUG Reply recieved. Setting reply as OUT message:
> <success>
>
> ... the result is: <success>
>
> Response in the main method: <success>
>
> [aultMessageListenerContainer-1] efaultMessageListenerContainer TRACE
> Consumer [weblogic.jms.client.WLConsumerImpl@14fa0ef] of session
> [weblogic.jms.client.WLSessionImpl@1d183b7] did not receive a message
>
> [aultMessageListenerContainer-1] efaultMessageListenerContainer TRACE
> Consumer [weblogic.jms.client.WLConsumerImpl@ceb6dd] of session
> [weblogic.jms.client.WLSessionImpl@1d183b7] did not receive a message
>
> [aultMessageListenerContainer-1] efaultMessageListenerContainer TRACE
> Consumer [weblogic.jms.client.WLConsumerImpl@1479ef9] of session
> [weblogic.jms.client.WLSessionImpl@1d183b7] did not receive a message
>
> [aultMessageListenerContainer-1] efaultMessageListenerContainer TRACE
> Consumer [weblogic.jms.client.WLConsumerImpl@1162a9c] of session
> [weblogic.jms.client.WLSessionImpl@1d183b7] did not receive a message
>
> [aultMessageListenerContainer-1] efaultMessageListenerContainer TRACE
> Consumer [weblogic.jms.client.WLConsumerImpl@47a8f3] of session
> [weblogic.jms.client.WLSessionImpl@1d183b7] did not receive a message
>
> [aultMessageListenerContainer-1] efaultMessageListenerContainer TRACE
> Consumer [weblogic.jms.client.WLConsumerImpl@a4edc4] of session
> [weblogic.jms.client.WLSessionImpl@1d183b7] did not receive a message
>
> [aultMessageListenerContainer-1] efaultMessageListenerContainer TRACE
> Consumer [weblogic.jms.client.WLConsumerImpl@1eb7d25] of session
> [weblogic.jms.client.WLSessionImpl@1d183b7] did not receive a message
>
> Any help is greatly appreciated.
> Thanks...
> --
> View this message in context: http://old.nabble.com/Producer-Template-CamelTemplate-does-not-stop-the-DefaultMessageListener-after-reading-the-response-from-Weblogic-JMS-queue.-tp27876324p27876324.html
> Sent from the Camel Development mailing list archive at Nabble.com.
>
>



-- 
Claus Ibsen
Apache Camel Committer

Author of Camel in Action: http://www.manning.com/ibsen/
Open Source Integration: http://fusesource.com
Blog: http://davsclaus.blogspot.com/
Twitter: http://twitter.com/davsclaus