I added the System.out statements inside my onMessage method 
as below:

public void onMessage(Message message) {
  |         String name = null;
  |         try {
  |             if (message instanceof ObjectMessage) {
  |                 ObjectMessage objMessage = (ObjectMessage) message;
  |                 Object obj = objMessage.getObject();
  |                 if (obj instanceof ProcessDTO) {
  |                     name = ((ProcessDTO)obj).getName();
  |                     
System.out.println("****************************************************");
  |                     System.out.println("LongProcessMessageBean.onMessage(): 
Received message. NAME: "+name);
  |                     
System.out.println("****************************************************");
  |                     System.out.println("Now calling 
LongProcessService.doLongProcess");
  | 
  |                     ProcessResult result = 
LongProcessService.doLongProcess((ProcessDTO)obj);
  |                  } else {
  |                     System.err.println("Expecting ProcessDTO in Message");
  |                 }
  |             } else {
  |                 System.err.println("Expecting Object Message");
  |             }
  |             
System.out.println("*******************************************");
  |             System.out.println("Leaving LongProcessMessageBean.onMessage(). 
NAME: "+name );
  |             
System.out.println("*******************************************");
  |         } catch (Throwable t) {
  |             t.printStackTrace();
  |             context.setRollbackOnly();
  |         }
  |     }
------------

I expected to see them in my jboss startup console, but I could not find any. 
What could I be doing wrong?

Am I not posting messages on my queue in the right manner? Please help!!

thanks


View the original post : 
http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4189689#4189689

Reply to the post : 
http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4189689
_______________________________________________
jboss-user mailing list
jboss-user@lists.jboss.org
https://lists.jboss.org/mailman/listinfo/jboss-user

Reply via email to