Mantis - Resin
|
|||||
Viewing Issue Advanced Details | |||||
|
|||||
ID: | Category: | Severity: | Reproducibility: | Date Submitted: | Last Update: |
150 | minor | always | 05-09-05 00:00 | 11-30-05 14:44 | |
|
|||||
Reporter: | ferg | Platform: | |||
Assigned To: | OS: | ||||
Priority: | urgent | OS Version: | |||
Status: | closed | Product Version: | 3.0.13 | ||
Product Build: | 3.0.13 | Resolution: | fixed | ||
Projection: | none | ||||
ETA: | none | Fixed in Version: | 3.0.14 | ||
|
|||||
Summary: | 0000150: JMS queue browser | ||||
Description: |
RSN-144 (rep by Thomas Gennaro) Are there any known problems with the javax.jms.QueueBrowser implementation in Resin 3.0.9? We have the code below in one of our servlets and the Queue count always shows 0 or 1 when we know that the # of items in the queue is well above that number because we are putting more items on the queue than are being removed with a MDB. We are trying to add logic to a servlet so that it stops handling requests when the queue grows too large in order to prevent the server from running out of memory. We are using MemoryQueue instead of JDBC right now b/c we haven't been able to get the JMS JDBC queueing to work with Oracle. Any suggestions are greatly appreciated. Regards, Tom QueueBrowser queueBrowser = queueSession.createBrowser(queue); // throws JMSException Enumeration enum = queueBrowser.getEnumeration(); int i = 0; while (enum.hasMoreElements()) { i++; logger.debug("Queue Count: " + i); enum.nextElement(); if (i <= 20) { // Moved to a point after the queuing of the message logger.debug("Queue at : " + i + " , which is under the limit: " + 20); jmsObjectMessage = queueSession.createObjectMessage(req); retVal = buildResponseMessage(tanum, timestamp, errorList); queueSender.send(jmsObjectMessage); incrementSuccessCount(); } else { logger.info("Queue is at: " + i + " and the queueLimit is set to " + 20); logger.info("Not sending an immediate response"); } |
||||
Steps To Reproduce: | |||||
Additional Information: | |||||
Relationships | |||||
Attached Files: |
Notes | |||||
|
|||||
|
|