activemq-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Gary Tully <gary.tu...@gmail.com>
Subject Re: Activemq 5.4.2 hangs when the temp disk usage is used
Date Tue, 18 Dec 2012 11:25:50 GMT
I peeked at that hang or a similar case recently w.r.t to flow control on a
temp queue... I came to the conclusion that blocking on cursor add was
problematic and that the blocking should be implemented in send, in the
same way that store limits are enforced.
Apart from the deadlock, multiple adds can proceed and %usage can be easily
exceeded.

Currently non persistent messages don't have a cursor temp usage check
before a send, adding that would avoid lots of pain I think.
In any event, please open a jira issue to track your problem and fix and we
will work to get this resolved asap.





On 17 December 2012 20:23, Tom Martinec <martinec@d3s.mff.cuni.cz> wrote:

> ceposta wrote
> > There's been a lot of re-work on the FilePendingMessageCursor (and other
> > areas that you touched here) since release 5.4.2 (which is about 2 yrs
> > old). Do you have the possibility to check with a later version of the
> > code
> > to see if that's been fixed for you?
>
> I have checked activemq 5.7.0 in tags directory.
>
> Ad 1)
> The messagesLock in Queue class is used in much the same way (in iterate()
> and sendMessage() methods). The FilePendingCursor still waits for the
> available space in tryAddMessageLast() and the waiting seems to be
> implemented in the same way in the waitForSpace() method of the Usage
> class.
>
> Ad 2)
> The FilePendingCursor still uses synchronized methods - at least the
> tryAddMessageLast() for writers and next() for readers.
>
> Ad 3)
> The TempUsage.retrieveUsage() uses PListStore.size() and that is still
> implemented as:
> return journal.getDiskSize() + pageFile.getDiskSize();
>
> I have not investigated further, but it will probably always return the
> same
> value as in 5.4.2.
>
> Therefore, all the three issues are likely present in the 5.7.0 too. I can
> spare some time to check whether 5.7.0 hangs too if you wish. I may also
> provide you an access to our private repository for cherrypicking the
> changes.
>
> Relevant source files:
>
> https://svn.apache.org/repos/asf/activemq/tags/activemq-5.7.0/activemq-core/src/main/java/org/apache/activemq/broker/region/Queue.java
>
> https://svn.apache.org/repos/asf/activemq/tags/activemq-5.7.0/activemq-core/src/main/java/org/apache/activemq/broker/region/cursors/FilePendingMessageCursor.java
>
> https://svn.apache.org/repos/asf/activemq/tags/activemq-5.7.0/activemq-core/src/main/java/org/apache/activemq/usage/Usage.java
>
> https://svn.apache.org/repos/asf/activemq/tags/activemq-5.7.0/activemq-core/src/main/java/org/apache/activemq/usage/TempUsage.java
>
> https://svn.apache.org/repos/asf/activemq/tags/activemq-5.7.0/activemq-core/src/main/java/org/apache/activemq/store/kahadb/plist/PListStore.java
>
>
>
>
> --
> View this message in context:
> http://activemq.2283324.n4.nabble.com/Activemq-5-4-2-hangs-when-the-temp-disk-usage-is-used-tp4660202p4660789.html
> Sent from the ActiveMQ - User mailing list archive at Nabble.com.
>



-- 
http://redhat.com
http://blog.garytully.com

Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message