activemq-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From chir...@apache.org
Subject svn commit: r630050 - /activemq/trunk/activemq-core/src/main/java/org/apache/activemq/transport/InactivityMonitor.java
Date Thu, 21 Feb 2008 23:42:01 GMT
Author: chirino
Date: Thu Feb 21 15:42:00 2008
New Revision: 630050

URL: http://svn.apache.org/viewvc?rev=630050&view=rev
Log:
Fixing bug with qdox.

Modified:
    activemq/trunk/activemq-core/src/main/java/org/apache/activemq/transport/InactivityMonitor.java

Modified: activemq/trunk/activemq-core/src/main/java/org/apache/activemq/transport/InactivityMonitor.java
URL: http://svn.apache.org/viewvc/activemq/trunk/activemq-core/src/main/java/org/apache/activemq/transport/InactivityMonitor.java?rev=630050&r1=630049&r2=630050&view=diff
==============================================================================
--- activemq/trunk/activemq-core/src/main/java/org/apache/activemq/transport/InactivityMonitor.java
(original)
+++ activemq/trunk/activemq-core/src/main/java/org/apache/activemq/transport/InactivityMonitor.java
Thu Feb 21 15:42:00 2008
@@ -75,7 +75,7 @@
             // read checks to be small..
             
             // If less than 90% of the read check Time elapsed then abort this readcheck.

-            if( elapsed < (readCheckTime * 9 / 10) ) {
+            if( !allowReadCheck(elapsed) ) { // FUNKY qdox bug does not allow me to inline
this expression.
                 LOG.debug("Aborting read check.. Not enough time elapsed since last read
check.");
                 return;
             }
@@ -84,6 +84,10 @@
             readCheck();
         }
     };
+    
+    private boolean allowReadCheck(long elapsed) {
+        return elapsed > (readCheckTime * 9 / 10);
+    }
 
     private final Runnable writeChecker = new Runnable() {
         long lastRunTime;



Mime
View raw message