You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@activemq.apache.org by "Gary Tully (JIRA)" <ji...@apache.org> on 2016/04/18 13:04:25 UTC

[jira] [Comment Edited] (AMQ-6222) Message content can be cleared by mistake when isReduceMemoryFootprint is enabled

    [ https://issues.apache.org/jira/browse/AMQ-6222?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15245465#comment-15245465 ] 

Gary Tully edited comment on AMQ-6222 at 4/18/16 11:03 AM:
-----------------------------------------------------------

[~cshannon] I think this is another candidate for revert following
https://git-wip-us.apache.org/repos/asf?p=activemq.git;a=blobdiff;f=activemq-broker/src/main/java/org/apache/activemq/broker/region/Queue.java;h=9540a9336da22f0a63f01d21404e49cec69db32c;hp=786640e8b7723b08c8f9074bbdf1d58a3d11bcca;hb=3291340;hpb=dc3c5a719b47fc40b5affce8412390ead67ce8ef

the beforeMarshal is now always called before the async call.

https://issues.apache.org/jira/browse/AMQ-6256


was (Author: gtully):
[~cshannon] I think this is another candidate for revert following
https://git-wip-us.apache.org/repos/asf?p=activemq.git;a=blobdiff;f=activemq-broker/src/main/java/org/apache/activemq/broker/region/Queue.java;h=9540a9336da22f0a63f01d21404e49cec69db32c;hp=786640e8b7723b08c8f9074bbdf1d58a3d11bcca;hb=3291340;hpb=dc3c5a719b47fc40b5affce8412390ead67ce8ef

the beforeMarshal is now always called before the async call.

> Message content can be cleared by mistake when isReduceMemoryFootprint is enabled
> ---------------------------------------------------------------------------------
>
>                 Key: AMQ-6222
>                 URL: https://issues.apache.org/jira/browse/AMQ-6222
>             Project: ActiveMQ
>          Issue Type: Bug
>          Components: Broker
>    Affects Versions: 5.13.2
>            Reporter: Christopher L. Shannon
>            Assignee: Christopher L. Shannon
>             Fix For: 5.14.0, 5.13.3
>
>
> In a Queue when isReduceMemoryFootprint is enabled the message state should be cleared after persisting to the store.  The idea is that once the data is marshalled into its byte content we can clear out the properties, text, etc to free up memory.
> The problem is that when concurrent dispatch is enabled, messages are added to the store asynchronously and queued up.  There is a race condition because it's possible for the state to be cleared before the store has a chance to process the message so that when it gets to it, it will be null.  This is most notable when using the VM transport as messages with null content will get dispatched.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)