You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@qpid.apache.org by "Douglas Pew (JIRA)" <qp...@incubator.apache.org> on 2009/02/10 21:07:59 UTC
[jira] Created: (QPID-1658) JMS client OutOfMemoryError when
sending 4k messages in rapid succession
JMS client OutOfMemoryError when sending 4k messages in rapid succession
------------------------------------------------------------------------
Key: QPID-1658
URL: https://issues.apache.org/jira/browse/QPID-1658
Project: Qpid
Issue Type: Bug
Components: Java Client
Affects Versions: M4
Environment: Ubuntu 8.04 Hardy
Reporter: Douglas Pew
The JMS bindings will throw an OutOfMemoryError when sending 4k or larger messages in rapid succession. The message producer's heap will continue to fill up until exhausted.
To repeat this error edit the class org.apache.qpid.example.jmsexample.direct.Producer to produce 100000 messages and 4k message sizes. I will submit source code.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
---------------------------------------------------------------------
Apache Qpid - AMQP Messaging Implementation
Project: http://qpid.apache.org
Use/Interact: mailto:dev-subscribe@qpid.apache.org
[jira] Assigned: (QPID-1658) JMS client OutOfMemoryError when
sending 4k messages in rapid succession
Posted by "Rafael H. Schloming (JIRA)" <qp...@incubator.apache.org>.
[ https://issues.apache.org/jira/browse/QPID-1658?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Rafael H. Schloming reassigned QPID-1658:
-----------------------------------------
Assignee: Rafael H. Schloming
> JMS client OutOfMemoryError when sending 4k messages in rapid succession
> ------------------------------------------------------------------------
>
> Key: QPID-1658
> URL: https://issues.apache.org/jira/browse/QPID-1658
> Project: Qpid
> Issue Type: Bug
> Components: Java Client
> Affects Versions: M4
> Environment: Ubuntu 8.04 Hardy
> Reporter: Douglas Pew
> Assignee: Rafael H. Schloming
> Attachments: Consumer.java, Producer.java
>
>
> The JMS bindings will throw an OutOfMemoryError when sending 4k or larger messages in rapid succession. The message producer's heap will continue to fill up until exhausted.
> To repeat this error edit the class org.apache.qpid.example.jmsexample.direct.Producer to produce 100000 messages and 4k message sizes. I will submit source code.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
---------------------------------------------------------------------
Apache Qpid - AMQP Messaging Implementation
Project: http://qpid.apache.org
Use/Interact: mailto:dev-subscribe@qpid.apache.org
[jira] Commented: (QPID-1658) JMS client OutOfMemoryError when
sending 4k messages in rapid succession
Posted by "Aidan Skinner (JIRA)" <qp...@incubator.apache.org>.
[ https://issues.apache.org/jira/browse/QPID-1658?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12672600#action_12672600 ]
Aidan Skinner commented on QPID-1658:
-------------------------------------
This may be due to the fact that send() is asynchronous. Does the issue occur if the sends are wrapped in a transaction and comitted every few hundred or thousand?
> JMS client OutOfMemoryError when sending 4k messages in rapid succession
> ------------------------------------------------------------------------
>
> Key: QPID-1658
> URL: https://issues.apache.org/jira/browse/QPID-1658
> Project: Qpid
> Issue Type: Bug
> Components: Java Client
> Affects Versions: M4
> Environment: Ubuntu 8.04 Hardy
> Reporter: Douglas Pew
> Attachments: Consumer.java, Producer.java
>
>
> The JMS bindings will throw an OutOfMemoryError when sending 4k or larger messages in rapid succession. The message producer's heap will continue to fill up until exhausted.
> To repeat this error edit the class org.apache.qpid.example.jmsexample.direct.Producer to produce 100000 messages and 4k message sizes. I will submit source code.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
---------------------------------------------------------------------
Apache Qpid - AMQP Messaging Implementation
Project: http://qpid.apache.org
Use/Interact: mailto:dev-subscribe@qpid.apache.org
[jira] Commented: (QPID-1658) JMS client OutOfMemoryError when
sending 4k messages in rapid succession
Posted by "Rajith Attapattu (JIRA)" <qp...@incubator.apache.org>.
[ https://issues.apache.org/jira/browse/QPID-1658?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12672395#action_12672395 ]
Rajith Attapattu commented on QPID-1658:
----------------------------------------
Douglas,
Are you using the c++ broker or the java broker?
Depending on which broker the JMS clients takes a different code path.
For the java broker the 0-8/0-9 code path is activated and uses MINA as the transport.
For the c++ broker the 0-10 code path is activated and uses a plain java.io based transport.
If it's the java broker you could then try to set -Dprotectio=true when starting the JMS client to ensure that the underlying MINA buffers don't grow unbounded.
> JMS client OutOfMemoryError when sending 4k messages in rapid succession
> ------------------------------------------------------------------------
>
> Key: QPID-1658
> URL: https://issues.apache.org/jira/browse/QPID-1658
> Project: Qpid
> Issue Type: Bug
> Components: Java Client
> Affects Versions: M4
> Environment: Ubuntu 8.04 Hardy
> Reporter: Douglas Pew
> Attachments: Consumer.java, Producer.java
>
>
> The JMS bindings will throw an OutOfMemoryError when sending 4k or larger messages in rapid succession. The message producer's heap will continue to fill up until exhausted.
> To repeat this error edit the class org.apache.qpid.example.jmsexample.direct.Producer to produce 100000 messages and 4k message sizes. I will submit source code.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
---------------------------------------------------------------------
Apache Qpid - AMQP Messaging Implementation
Project: http://qpid.apache.org
Use/Interact: mailto:dev-subscribe@qpid.apache.org
[jira] Updated: (QPID-1658) JMS client OutOfMemoryError when
sending 4k messages in rapid succession
Posted by "Douglas Pew (JIRA)" <qp...@incubator.apache.org>.
[ https://issues.apache.org/jira/browse/QPID-1658?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Douglas Pew updated QPID-1658:
------------------------------
Attachment: Producer.java
Modified jms producer example that creates 100000 4k messages with System.out.println's deactivated.
> JMS client OutOfMemoryError when sending 4k messages in rapid succession
> ------------------------------------------------------------------------
>
> Key: QPID-1658
> URL: https://issues.apache.org/jira/browse/QPID-1658
> Project: Qpid
> Issue Type: Bug
> Components: Java Client
> Affects Versions: M4
> Environment: Ubuntu 8.04 Hardy
> Reporter: Douglas Pew
> Attachments: Consumer.java, Producer.java
>
>
> The JMS bindings will throw an OutOfMemoryError when sending 4k or larger messages in rapid succession. The message producer's heap will continue to fill up until exhausted.
> To repeat this error edit the class org.apache.qpid.example.jmsexample.direct.Producer to produce 100000 messages and 4k message sizes. I will submit source code.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
---------------------------------------------------------------------
Apache Qpid - AMQP Messaging Implementation
Project: http://qpid.apache.org
Use/Interact: mailto:dev-subscribe@qpid.apache.org
[jira] Commented: (QPID-1658) JMS client OutOfMemoryError when
sending 4k messages in rapid succession
Posted by "Rafael H. Schloming (JIRA)" <qp...@incubator.apache.org>.
[ https://issues.apache.org/jira/browse/QPID-1658?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12672665#action_12672665 ]
Rafael H. Schloming commented on QPID-1658:
-------------------------------------------
This is my fault. I added a Session level command buffer that is only bounded by the number of commands rather than the cumulative size of the commands. It should be a straightforward fix to bound it by size as well. I'll submit a fix shortly.
> JMS client OutOfMemoryError when sending 4k messages in rapid succession
> ------------------------------------------------------------------------
>
> Key: QPID-1658
> URL: https://issues.apache.org/jira/browse/QPID-1658
> Project: Qpid
> Issue Type: Bug
> Components: Java Client
> Affects Versions: M4
> Environment: Ubuntu 8.04 Hardy
> Reporter: Douglas Pew
> Attachments: Consumer.java, Producer.java
>
>
> The JMS bindings will throw an OutOfMemoryError when sending 4k or larger messages in rapid succession. The message producer's heap will continue to fill up until exhausted.
> To repeat this error edit the class org.apache.qpid.example.jmsexample.direct.Producer to produce 100000 messages and 4k message sizes. I will submit source code.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
---------------------------------------------------------------------
Apache Qpid - AMQP Messaging Implementation
Project: http://qpid.apache.org
Use/Interact: mailto:dev-subscribe@qpid.apache.org
[jira] Commented: (QPID-1658) JMS client OutOfMemoryError when
sending 4k messages in rapid succession
Posted by "Douglas Pew (JIRA)" <qp...@incubator.apache.org>.
[ https://issues.apache.org/jira/browse/QPID-1658?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12672641#action_12672641 ]
Douglas Pew commented on QPID-1658:
-----------------------------------
FYI: This test is using the M4 C++ broker.
I set the heap size to be very large on the client -mx512m, but that only delays the issue a bit. The heap fills up quite linearly, and memory is not being released.
The VisualVM profiler shows that the memory is being used by byte[] (54MB) - 3,338 instances. There are also 3,362 instances of MessageTransport. This seems to indicate that the MessageTransport.body (of class ByteBuffer) is the culprit.
> JMS client OutOfMemoryError when sending 4k messages in rapid succession
> ------------------------------------------------------------------------
>
> Key: QPID-1658
> URL: https://issues.apache.org/jira/browse/QPID-1658
> Project: Qpid
> Issue Type: Bug
> Components: Java Client
> Affects Versions: M4
> Environment: Ubuntu 8.04 Hardy
> Reporter: Douglas Pew
> Attachments: Consumer.java, Producer.java
>
>
> The JMS bindings will throw an OutOfMemoryError when sending 4k or larger messages in rapid succession. The message producer's heap will continue to fill up until exhausted.
> To repeat this error edit the class org.apache.qpid.example.jmsexample.direct.Producer to produce 100000 messages and 4k message sizes. I will submit source code.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
---------------------------------------------------------------------
Apache Qpid - AMQP Messaging Implementation
Project: http://qpid.apache.org
Use/Interact: mailto:dev-subscribe@qpid.apache.org
[jira] Commented: (QPID-1658) JMS client OutOfMemoryError when
sending 4k messages in rapid succession
Posted by "Rafael H. Schloming (JIRA)" <qp...@incubator.apache.org>.
[ https://issues.apache.org/jira/browse/QPID-1658?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12672735#action_12672735 ]
Rafael H. Schloming commented on QPID-1658:
-------------------------------------------
This should be fixed on trunk now. By default the session replay buffer is limited to either 65536 commands or 1Mb worth of commands whichever comes first. You can control the policy via the two system properties qpid.session.byte_limit and qpid.session.command_limit.
> JMS client OutOfMemoryError when sending 4k messages in rapid succession
> ------------------------------------------------------------------------
>
> Key: QPID-1658
> URL: https://issues.apache.org/jira/browse/QPID-1658
> Project: Qpid
> Issue Type: Bug
> Components: Java Client
> Affects Versions: M4
> Environment: Ubuntu 8.04 Hardy
> Reporter: Douglas Pew
> Assignee: Rafael H. Schloming
> Attachments: Consumer.java, Producer.java
>
>
> The JMS bindings will throw an OutOfMemoryError when sending 4k or larger messages in rapid succession. The message producer's heap will continue to fill up until exhausted.
> To repeat this error edit the class org.apache.qpid.example.jmsexample.direct.Producer to produce 100000 messages and 4k message sizes. I will submit source code.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
---------------------------------------------------------------------
Apache Qpid - AMQP Messaging Implementation
Project: http://qpid.apache.org
Use/Interact: mailto:dev-subscribe@qpid.apache.org
[jira] Updated: (QPID-1658) JMS client OutOfMemoryError when
sending 4k messages in rapid succession
Posted by "Douglas Pew (JIRA)" <qp...@incubator.apache.org>.
[ https://issues.apache.org/jira/browse/QPID-1658?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Douglas Pew updated QPID-1658:
------------------------------
Attachment: Consumer.java
Example JMS Client with System.out.println's disabled.
> JMS client OutOfMemoryError when sending 4k messages in rapid succession
> ------------------------------------------------------------------------
>
> Key: QPID-1658
> URL: https://issues.apache.org/jira/browse/QPID-1658
> Project: Qpid
> Issue Type: Bug
> Components: Java Client
> Affects Versions: M4
> Environment: Ubuntu 8.04 Hardy
> Reporter: Douglas Pew
> Attachments: Consumer.java, Producer.java
>
>
> The JMS bindings will throw an OutOfMemoryError when sending 4k or larger messages in rapid succession. The message producer's heap will continue to fill up until exhausted.
> To repeat this error edit the class org.apache.qpid.example.jmsexample.direct.Producer to produce 100000 messages and 4k message sizes. I will submit source code.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
---------------------------------------------------------------------
Apache Qpid - AMQP Messaging Implementation
Project: http://qpid.apache.org
Use/Interact: mailto:dev-subscribe@qpid.apache.org