• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

Message Driven Bean is unable to connect to the JMS Destination

 
Author
Posts: 6055
8
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
The title pretty much says it all. Right now I have a client sending to a queue and an EJB which should listen to the queue and print a message upon receipt.
We know the client is correct, because I print out the queue name after sending the message, and it has the name (not jndi name, but just the "human usable" name) returning from the queue's getName() method--so it's clearly finding the right queue on the server.
We also know that the EJB has the correct queue, because I first tried to deploy the EJB with the wrong queue name and got an error at deployment time.
This seems to be a problem with some server settings. The client sends the message ok, and then I get the error notice in the server log.
Server: WebLogic 7.0, Win2000 SP2
Client/IDE: JBuilder 8.0 Enterprise, Win2000 SP3

--Mark
[ December 19, 2002: Message edited by: Mark Herschberg ]
 
Ranch Hand
Posts: 2713
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
The first thing I would do is check the console to see if the Queue has even received any messages and if any of those messages have been consumed.
In the Admin Console (this from memory so don't flame):
Goto to Services->JMS->Servers->Your JMS Server->Monitoring->Monitor all Active JMS Destinations
The two values you are concerned with are:
Messages - current number of messages in the queue.
Messages Received - total number of messages received (consumed or not) since server startup.
If both of these values are zero then you aren't getting anything into the queue. If Messages is greater than zero then your MDB isn't picking up the messages.
Let me know what you find.
 
Chris Mathews
Ranch Hand
Posts: 2713
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Also look at the Consumers column. The number should be at least 1 (your MDB), if it is not then you know your MDB is never registering as a listener.
 
Mark Herschberg
Author
Posts: 6055
8
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Originally posted by Chris Mathews:
The first thing I would do is check the console to see if the Queue has even received any messages and if any of those messages have been consumed.
In the Admin Console (this from memory so don't flame):
Goto to Services->JMS->Servers->Your JMS Server->Monitoring->Monitor all Active JMS Destinations
The two values you are concerned with are:
Messages - current number of messages in the queue.
Messages Received - total number of messages received (consumed or not) since server startup./QB]



When I go to
SimTradeDomain> Servers> myserver> Active JMS Connections
and click through to
SimTradeDomain> Servers> myserver> Active JMS Services> myserver.jms> Active JMS Conne...> connection225> Active JMS Sessions> session226> Active JMS Consumers
The "Order Placement Queue" is listed as in active, i.e. under active it reads false.
However, under
SimTradeDomain> JMS Servers> SimTrade JMS Server> JMS Destinations> Order Placement Queue> Active JMS Destinations
This shows that one message was received (and 0 pending). This is correct.

Can an inactive queue still receive messages? Is it just that I need to activate it?

--Mark

Originally posted by Chris Mathews:
[QB]The first thing I would do is check the console to see if the Queue has even received any messages and if any of those messages have been consumed.
In the Admin Console (this from memory so don't flame):
Goto to Services->JMS->Servers->Your JMS Server->Monitoring->Monitor all Active JMS Destinations
The two values you are concerned with are:
Messages - current number of messages in the queue.
Messages Received - total number of messages received (consumed or not) since server startup.
If both of these values are zero then you aren't getting anything into the queue. If Messages is greater than zero then your MDB isn't picking up the messages.
Let me know what you find.


Originally posted by Chris Mathews:
The first thing I would do is check the console to see if the Queue has even received any messages and if any of those messages have been consumed.
In the Admin Console (this from memory so don't flame):
Goto to Services->JMS->Servers->Your JMS Server->Monitoring->Monitor all Active JMS Destinations
The two values you are concerned with are:
Messages - current number of messages in the queue.
Messages Received - total number of messages received (consumed or not) since server startup.
If both of these values are zero then you aren't getting anything into the queue. If Messages is greater than zero then your MDB isn't picking up the messages.
Let me know what you find.

 
Mark Herschberg
Author
Posts: 6055
8
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I finally got back into the office today (after discovering that you can only remotely shut down the server, not remotely restart it :-p ) and played around with it some more. I don't think I changed any settings, but ultimately started getting more useful error messages in the log. Specifically, it complained that the Message Driven EJB supported transactions, but the queue did not. So I went to the QueueFactory and checked XAConnection Factory Enabled and Server Side XA Enabled (User Transactions Enabled was already checked). Now it works! Thanks for your help, Chris.
--Mark
[ December 26, 2002: Message edited by: Mark Herschberg ]
 
Chris Mathews
Ranch Hand
Posts: 2713
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Originally posted by Mark Herschberg:
I finally got back into the office today (after discovering that you can only remotely shut down the server, not remotely restart it :-p)...


You can use a Node Manager to allow for remote startup of WebLogic Servers (among other things). Here is a link to the documentation: Managing Server Availability with Node Manager.
 
Don't get me started about those stupid light bulbs.
reply
    Bookmark Topic Watch Topic
  • New Topic