Able to Send Messages More Than the Configured Quota - JMS QuotaException is Not Thrown When Limit is Reached (Doc ID 2144513.1)

Last updated on MARCH 29, 2017

Applies to:

Oracle WebLogic Server - Version 10.3.6 to 12.2.1.0.0
Information in this document applies to any platform.

Symptoms

On a 10.3.6 WLS Managed Server, a JMS client (Message Producer ) is able to send the messages more than the configured Quota limit.

(When TTL (TimeTo live) is configured to a value and Error Queue is configured to receive the messages when TTL is reached and Expiration policy is set to Error Destination redirect).

 

Actual Behavior

- JMS Server targeted on a managed server weblogic.

- On the JMS Server place a quota to 10 messages for example (a low value to go fast)

- A JMS module create Queue and ErrorQueue

- Put a message in the Queue a TimeTo live of 1sec after that messages are moved to the ErrorQueue

- On Queue it is necessary adjust Time-to-Live Override in 1000 for example and  Expiration Policy: Error Destination redirect.

Now if  send messages in the Queue more than the quota and you will never have the exception of quota,Since other messages are moving to the error queue Hence message count from error queue is considered as part of quota limit. So Message producer/sender is able to send the messages more than the quota limit configured.

 

Expected Behavior

Even when messages were moving to the Error queue once TTL is reached,Configured Quota value should work.On sending the messages more than the configured  quota value,The below exception should come.

Exception in thread "main" weblogic.jms.common.ResourceAllocationException: webl
ogic.messaging.kernel.QuotaException: Quota TestJMSServer.Quota.1459317088407 exceeded: Request: 7 bytes. Quota: bytes = 93 / 9223372036854775807 messages = 15/ 10 policy = FIFO outstanding blocking request false
at weblogic.jms.dispatcher.DispatcherAdapter.convertToJMSExceptionAndThrow(DispatcherAdapter.java:110)
at weblogic.jms.dispatcher.DispatcherAdapter.dispatchSyncTran(DispatcherAdapter.java:53)
at weblogic.jms.client.JMSProducer.toFEProducer(JMSProducer.java:1289)
at weblogic.jms.client.JMSProducer.deliveryInternal(JMSProducer.java:796)
at weblogic.jms.client.JMSProducer.sendInternal(JMSProducer.java:541)
at weblogic.jms.client.JMSProducer.sendWithListener(JMSProducer.java:394)
at weblogic.jms.client.JMSProducer.send(JMSProducer.java:384)
at weblogic.jms.client.WLProducerImpl.send(WLProducerImpl.java:970)
at examples.jms.queue.QueueSend.send(QueueSend.java:67)
at examples.jms.queue.QueueSend.readAndSend(QueueSend.java:106)
at examples.jms.queue.QueueSend.main(QueueSend.java:92)
Caused by: weblogic.jms.common.ResourceAllocationException: weblogic.messaging.kernel.QuotaException: Quota TestJMSServer.Quota.1459317088407 exceeded: Request: 7 bytes. Quota: bytes = 93 / 9223372036854775807 messages = 15 / 10 policy = FIFO outstanding blocking request false
at weblogic.jms.dispatcher.Request.handleThrowable(Request.java:87)
at weblogic.jms.dispatcher.Request.getResult(Request.java:52)

 

 

Cause

Sign In with your My Oracle Support account

Don't have a My Oracle Support account? Click to get started

My Oracle Support provides customers with access to over a
Million Knowledge Articles and hundreds of Community platforms