[jboss-cvs] JBoss Messaging SVN: r5681 - in trunk: tests/src/org/jboss/messaging/tests/integration/cluster/failover and 2 other directories.

jboss-cvs-commits at lists.jboss.org jboss-cvs-commits at lists.jboss.org
Wed Jan 21 21:46:20 EST 2009


Author: clebert.suconic at jboss.com
Date: 2009-01-21 21:46:20 -0500 (Wed, 21 Jan 2009)
New Revision: 5681

Added:
   trunk/tests/src/org/jboss/messaging/tests/stress/failover/
   trunk/tests/src/org/jboss/messaging/tests/stress/failover/LargeMessageMultiThreadFailoverStressTest.java
   trunk/tests/src/org/jboss/messaging/tests/stress/failover/MultiThreadRandomFailoverStressTest.java
Modified:
   trunk/src/main/org/jboss/messaging/core/server/impl/ServerConsumerImpl.java
   trunk/tests/src/org/jboss/messaging/tests/integration/cluster/failover/LargeMessageMuliThreadFailoverTest.java
   trunk/tests/src/org/jboss/messaging/tests/integration/cluster/failover/MultiThreadRandomFailoverTest.java
   trunk/tests/src/org/jboss/messaging/tests/integration/cluster/failover/MultiThreadRandomFailoverTestBase.java
Log:
Separating MultiThreadFailoverStressTest to stress tests

Modified: trunk/src/main/org/jboss/messaging/core/server/impl/ServerConsumerImpl.java
===================================================================
--- trunk/src/main/org/jboss/messaging/core/server/impl/ServerConsumerImpl.java	2009-01-22 00:24:44 UTC (rev 5680)
+++ trunk/src/main/org/jboss/messaging/core/server/impl/ServerConsumerImpl.java	2009-01-22 02:46:20 UTC (rev 5681)
@@ -760,6 +760,7 @@
 
             if (availableCredits != null)
             {
+               // Flow control needs to be done in advance.
                creditsUsed = preCalculateFlowControl();
             }
             else

Modified: trunk/tests/src/org/jboss/messaging/tests/integration/cluster/failover/LargeMessageMuliThreadFailoverTest.java
===================================================================
--- trunk/tests/src/org/jboss/messaging/tests/integration/cluster/failover/LargeMessageMuliThreadFailoverTest.java	2009-01-22 00:24:44 UTC (rev 5680)
+++ trunk/tests/src/org/jboss/messaging/tests/integration/cluster/failover/LargeMessageMuliThreadFailoverTest.java	2009-01-22 02:46:20 UTC (rev 5681)
@@ -125,12 +125,6 @@
 
    }
    
-   protected int getNumIterations()
-   {
-      return 10;
-   }
-
-
    @Override
    protected void setBody(final ClientMessage message) throws Exception
    {

Modified: trunk/tests/src/org/jboss/messaging/tests/integration/cluster/failover/MultiThreadRandomFailoverTest.java
===================================================================
--- trunk/tests/src/org/jboss/messaging/tests/integration/cluster/failover/MultiThreadRandomFailoverTest.java	2009-01-22 00:24:44 UTC (rev 5680)
+++ trunk/tests/src/org/jboss/messaging/tests/integration/cluster/failover/MultiThreadRandomFailoverTest.java	2009-01-22 02:46:20 UTC (rev 5681)
@@ -23,7 +23,7 @@
 import org.jboss.messaging.core.server.impl.MessagingServiceImpl;
 
 /**
- * A MultiThreadRandomFailoverTest
+ * A MultiThreadRandomFailoverStressTest
  * 
  * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
  * @author <a href="mailto:clebert.suconic at jboss.org">Clebert Suconic</a>
@@ -66,7 +66,7 @@
     * @see org.jboss.messaging.tests.integration.cluster.failover.MultiThreadRandomFailoverTestBase#setBody(org.jboss.messaging.core.client.ClientMessage)
     */
    @Override
-   protected void setBody(ClientMessage message) throws Exception
+   protected void setBody(final ClientMessage message) throws Exception
    {
       message.getBody().flip();
    }
@@ -75,7 +75,7 @@
     * @see org.jboss.messaging.tests.integration.cluster.failover.MultiThreadRandomFailoverTestBase#checkSize(org.jboss.messaging.core.client.ClientMessage)
     */
    @Override
-   protected boolean checkSize(ClientMessage message)
+   protected boolean checkSize(final ClientMessage message)
    {
       return 0 == message.getBody().limit();
    }

Modified: trunk/tests/src/org/jboss/messaging/tests/integration/cluster/failover/MultiThreadRandomFailoverTestBase.java
===================================================================
--- trunk/tests/src/org/jboss/messaging/tests/integration/cluster/failover/MultiThreadRandomFailoverTestBase.java	2009-01-22 00:24:44 UTC (rev 5680)
+++ trunk/tests/src/org/jboss/messaging/tests/integration/cluster/failover/MultiThreadRandomFailoverTestBase.java	2009-01-22 02:46:20 UTC (rev 5681)
@@ -1243,7 +1243,7 @@
 
    protected int getNumIterations()
    {
-      return 20;
+      return 1;
    }
 
    @Override

Added: trunk/tests/src/org/jboss/messaging/tests/stress/failover/LargeMessageMultiThreadFailoverStressTest.java
===================================================================
--- trunk/tests/src/org/jboss/messaging/tests/stress/failover/LargeMessageMultiThreadFailoverStressTest.java	                        (rev 0)
+++ trunk/tests/src/org/jboss/messaging/tests/stress/failover/LargeMessageMultiThreadFailoverStressTest.java	2009-01-22 02:46:20 UTC (rev 5681)
@@ -0,0 +1,65 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005-2009, Red Hat Middleware LLC, and individual contributors
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */
+
+
+package org.jboss.messaging.tests.stress.failover;
+
+import org.jboss.messaging.tests.integration.cluster.failover.LargeMessageMuliThreadFailoverTest;
+
+/**
+ * A LargeMessageMultiThreadFailoverStressTest
+ *
+ * @author <a href="mailto:clebert.suconic at jboss.org">Clebert Suconic</a>
+ * 
+ * Created Jan 21, 2009 8:38:28 PM
+ *
+ *
+ */
+public class LargeMessageMultiThreadFailoverStressTest extends LargeMessageMuliThreadFailoverTest
+{
+
+   // Constants -----------------------------------------------------
+
+   // Attributes ----------------------------------------------------
+
+   // Static --------------------------------------------------------
+
+   // Constructors --------------------------------------------------
+
+   // Public --------------------------------------------------------
+   
+   
+   protected int getNumIterations()
+   {
+      return 20;
+   }
+
+
+   // Package protected ---------------------------------------------
+
+   // Protected -----------------------------------------------------
+
+   // Private -------------------------------------------------------
+
+   // Inner classes -------------------------------------------------
+
+}

Added: trunk/tests/src/org/jboss/messaging/tests/stress/failover/MultiThreadRandomFailoverStressTest.java
===================================================================
--- trunk/tests/src/org/jboss/messaging/tests/stress/failover/MultiThreadRandomFailoverStressTest.java	                        (rev 0)
+++ trunk/tests/src/org/jboss/messaging/tests/stress/failover/MultiThreadRandomFailoverStressTest.java	2009-01-22 02:46:20 UTC (rev 5681)
@@ -0,0 +1,30 @@
+/*
+ * JBoss, Home of Professional Open Source Copyright 2005-2008, Red Hat Middleware LLC, and individual contributors by
+ * the @authors tag. See the copyright.txt in the distribution for a full listing of individual contributors. This is
+ * free software; you can redistribute it and/or modify it under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of the License, or (at your option) any later version.
+ * This software is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied
+ * warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more
+ * details. You should have received a copy of the GNU Lesser General Public License along with this software; if not,
+ * write to the Free Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA, or see the FSF
+ * site: http://www.fsf.org.
+ */
+
+package org.jboss.messaging.tests.stress.failover;
+
+import org.jboss.messaging.tests.integration.cluster.failover.MultiThreadRandomFailoverTest;
+
+/**
+ * A MultiThreadRandomFailoverStressTest
+ * 
+ * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
+ * @author <a href="mailto:clebert.suconic at jboss.org">Clebert Suconic</a>
+ */
+public class MultiThreadRandomFailoverStressTest extends MultiThreadRandomFailoverTest
+{
+   protected int getNumIterations()
+   {
+      return 20;
+   }
+
+}




More information about the jboss-cvs-commits mailing list