You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@activemq.apache.org by "Sergey Ermakov (JIRA)" <ji...@apache.org> on 2012/07/10 16:29:34 UTC

[jira] [Created] (AMQ-3920) Performance issue with delay policy in DestinationBridge.onMessage

Sergey Ermakov created AMQ-3920:
-----------------------------------

             Summary: Performance issue with delay policy in DestinationBridge.onMessage
                 Key: AMQ-3920
                 URL: https://issues.apache.org/jira/browse/AMQ-3920
             Project: ActiveMQ
          Issue Type: Bug
          Components: Broker
    Affects Versions: 5.6.0
            Reporter: Sergey Ermakov
            Priority: Critical


Incorrect sleep implementation in org.apache.activemq.network.jms.DestinationBridge.onMessage

In the current implementation the condition 'attempt > 0' is true during the first iteration. It causes critical performance problems in high load environment.

Code example from DestinationBridge.onMessage:
...
while (started.get() && message != null && ++attempt <= maxRetries) {

            try {

                if (attempt > 0) {//IT'S TRUE DURING FIRST ITERATION
                    try {                       Thread.sleep(jmsConnector.getReconnectionPolicy().getNextDelay(attempt));
                    } catch(InterruptedException e) {
                        break;
                    }
                }
...

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Resolved] (AMQ-3920) Performance issue with delay policy in DestinationBridge.onMessage

Posted by "Timothy Bish (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/AMQ-3920?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Timothy Bish resolved AMQ-3920.
-------------------------------

       Resolution: Fixed
    Fix Version/s: 5.7.0
         Assignee: Timothy Bish

Fixed in trunk
                
> Performance issue with delay policy in DestinationBridge.onMessage
> ------------------------------------------------------------------
>
>                 Key: AMQ-3920
>                 URL: https://issues.apache.org/jira/browse/AMQ-3920
>             Project: ActiveMQ
>          Issue Type: Bug
>          Components: Broker
>    Affects Versions: 5.6.0
>            Reporter: Sergey Ermakov
>            Assignee: Timothy Bish
>            Priority: Critical
>             Fix For: 5.7.0
>
>
> Incorrect sleep implementation in org.apache.activemq.network.jms.DestinationBridge.onMessage
> In the current implementation the condition 'attempt > 0' is true during the first iteration. It causes critical performance problems in high load environment.
> Code example from DestinationBridge.onMessage:
> ...
> while (started.get() && message != null && ++attempt <= maxRetries) {
>             try {
>                 if (attempt > 0) {//IT'S TRUE DURING FIRST ITERATION
>                     try {                       Thread.sleep(jmsConnector.getReconnectionPolicy().getNextDelay(attempt));
>                     } catch(InterruptedException e) {
>                         break;
>                     }
>                 }
> ...

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira