[
https://issues.apache.org/jira/browse/AMQ-7107?focusedWorklogId=241539&page=com.atlassian.jira.plugin.system.issuetabpanels:worklog-tabpanel#worklog-241539
]
ASF GitHub Bot logged work on AMQ-7107:
---------------------------------------
Author: ASF GitHub Bot
Created on: 14/May/19 05:39
Start Date: 14/May/19 05:39
Worklog Time Spent: 10m
Work Description: jbonofre commented on pull request #318: AMQ-7107 -
Make QueueBrowsingTest and UsageBlockedDispatchTest succee…
URL: https://github.com/apache/activemq/pull/318
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
[email protected]
Issue Time Tracking
-------------------
Worklog Id: (was: 241539)
Time Spent: 10m
Remaining Estimate: 0h
> QueueBrowsingTest and UsageBlockedDispatchTest are failing with
> ConcurrentStoreAndDispachQueues=false
> -----------------------------------------------------------------------------------------------------
>
> Key: AMQ-7107
> URL: https://issues.apache.org/jira/browse/AMQ-7107
> Project: ActiveMQ
> Issue Type: Test
> Components: Test Cases
> Reporter: Alan Protasio
> Priority: Minor
> Fix For: 5.15.10
>
> Time Spent: 10m
> Remaining Estimate: 0h
>
> Hi,
> I was working towards https://issues.apache.org/jira/browse/AMQ-7028 and
> after my change QueueBrowsingTest and UsageBlockedDispatchTest were failing.
> QueueBrowsingTest was changed by
> https://issues.apache.org/jira/browse/AMQ-4495 and it is testing if a full
> page was pagedIn by the cursor.
> The problem is because this test was only succeeding due how
> ConcurrentStoreAndDispachQueues=true is implemented. When this flag is set to
> True, we increase the memory usage when start the async task and when
> decrease it when the task is done:
> https://github.com/alanprot/activemq/blob/master/activemq-broker/src/main/java/org/apache/activemq/broker/region/Queue.java#L897
> So, imagine this timeline:
> 1 . Send message 1
> 2. The cursor get full and the cache is disabled
> 3. Message1 finish and the memory is freed
> 4. messages 2 to 100 are sent and the cache is skipped
> 5. We call browser queue and the cursor can pageIn messages because the
> cursorMemory is not full
> Now with ConcurrentStoreAndDispachQueues=false
> 1 . Send message 1
> 2 . Send message 2
> 3. The cursor get full and the cache is disabled
> 4. messages 3 to 100 are sent and the cache is skipped (memory still full)
> 5. We call browser queue and the cursor cannot pageIn messages because the
> cursorMemory is full
> So, in order to make this test work with
> ConcurrentStoreAndDispachQueues=false i did a simple change on it... After
> sending all the messages, consume one of them and make sure that the cursor
> has memory to pageIn messages.
> Similar thing is happening with UsageBlockedDispatchTest.
> I create 2 more test to do the same test with
> ConcurrentStoreAndDispachQueues=false and changed it a little bit to make
> them works with this flag false.
--
This message was sent by Atlassian JIRA
(v7.6.3#76005)