Author: pferraro
Date: 2008-11-18 21:00:59 -0500 (Tue, 18 Nov 2008)
New Revision: 2064
Added:
trunk/mod_cluster/src/main/java/org/jboss/modcluster/config/LoadBalanceFactorProviderConfiguration.java
Modified:
trunk/mod_cluster/src/main/java/org/jboss/modcluster/load/impl/DynamicLoadBalanceFactorProviderMBean.java
Log:
Extract configuration interface
Added:
trunk/mod_cluster/src/main/java/org/jboss/modcluster/config/LoadBalanceFactorProviderConfiguration.java
===================================================================
---
trunk/mod_cluster/src/main/java/org/jboss/modcluster/config/LoadBalanceFactorProviderConfiguration.java
(rev 0)
+++
trunk/mod_cluster/src/main/java/org/jboss/modcluster/config/LoadBalanceFactorProviderConfiguration.java 2008-11-19
02:00:59 UTC (rev 2064)
@@ -0,0 +1,41 @@
+/*
+ * JBoss, Home of Professional Open Source.
+ * Copyright 2008, Red Hat Middleware LLC, and individual contributors
+ * as indicated by the @author tags. See the copyright.txt file 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.modcluster.config;
+
+/**
+ * @author Paul Ferraro
+ *
+ */
+public interface LoadBalanceFactorProviderConfiguration
+{
+ /**
+ * Returns the history count.
+ * @return a positive integer
+ */
+ int getHistory();
+
+ /**
+ * Returns the exponential decay factor.
+ * @return a positive integer
+ */
+ int getDecayFactor();
+}
Modified:
trunk/mod_cluster/src/main/java/org/jboss/modcluster/load/impl/DynamicLoadBalanceFactorProviderMBean.java
===================================================================
---
trunk/mod_cluster/src/main/java/org/jboss/modcluster/load/impl/DynamicLoadBalanceFactorProviderMBean.java 2008-11-19
01:59:17 UTC (rev 2063)
+++
trunk/mod_cluster/src/main/java/org/jboss/modcluster/load/impl/DynamicLoadBalanceFactorProviderMBean.java 2008-11-19
02:00:59 UTC (rev 2064)
@@ -21,31 +21,21 @@
*/
package org.jboss.modcluster.load.impl;
+import org.jboss.modcluster.config.LoadBalanceFactorProviderConfiguration;
+
/**
* @author Paul Ferraro
*
*/
-public interface DynamicLoadBalanceFactorProviderMBean
+public interface DynamicLoadBalanceFactorProviderMBean extends
LoadBalanceFactorProviderConfiguration
{
/**
- * Returns the history count.
- * @return a positive integer
- */
- int getHistory();
-
- /**
* Sets the number of historical load values to consider when calculating the load
balance factor.
* @param history
*/
void setHistory(int history);
/**
- * Returns the exponential decay factor.
- * @return a positive integer
- */
- int getDecayFactor();
-
- /**
* Sets the exponential decay factor to be applied to historical load values.
* @param decayFactor the new decay factor
*/