Interface AbsoluteStatLimiterMBean
-
- All Superinterfaces:
LimiterMBean,StatLimiterMBean
public interface AbsoluteStatLimiterMBean extends StatLimiterMBean
Defines the JMX interface for controlling a single absolute stat limiter.
When a node is configured to use the pool clustering mode, operations in this interface that include an argument to specify an array of node IDs can only be used to manage state on the node the management client directs the method call at, as determined by
RhinoHousekeepingMBean.getNodeID(). Including the node ID of any other node in the array argument will result in anInvalidArgumentExceptionbeing thrown. To manage state for another node in pool mode, a client must connect directly with that node.Limiter Information
A
CompositeDataobject containing detailed Limiter information for specified nodes is returned by the methodsLimiterMBean.getInfoSummary(int[])andLimiterMBean.getConfigSummary().Field Open Type Description limiter-name
String
The name of this limiter. Always
nullfor per-node values returned byLimiterMBean.getConfigSummary().type
String
The type of this limiter. Always
nullfor per-node values returned byLimiterMBean.getConfigSummary().node-id
Integer
The node ID that this row applies to.
-1for the cluster-wide values row returned byLimiterMBean.getConfigSummary().parent
String
The name of the parent of this limiter or null if it has no parent. Always
nullfor per-node values returned byLimiterMBean.getConfigSummary().parameter-set
String
The parameter set for the statistic to monitor.
statistic
String
The statistic to monitor.
bypassed
Boolean
The bypassed setting for this limiter.
tiers
TabularData
The rate limit percentage tiers, as a
TabularDataof Tier InformationCompositeDataobjects (see below).Tier Information
A
CompositeDataobject containing Tier information as returned in thetiersfield of the Limiter InformationCompositeDataobject (see above).Field Open Type Description value
Long
The absolute threshold value of this limiter tier.
limit-percentage
Double
The percentage of calls to limit when this tier is active. Between 0 and 100 inclusive.
- Since:
- Rhino 2.7.0
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description voidclearTier(long value)Clear (remove) the given tier if it exists.voidclearTierForNode(long[] values, int[] nodeIDs)Clear (remove) the given per-node tiers if they exist.long[]getTierValues()Get the values representing the limiting tiers.long[][]getTierValuesForNodes(int[] nodeIDs)Get the per-node values representing the limiting tiers.voidsetTier(long value, double limitPercentage)Create or update the given tier with the specified limit percentage.voidsetTierForNode(long[] values, double[] limitPercentages, int[] nodeIDs)Create or update the given per-node value tiers with the specified limit percentages.-
Methods inherited from interface com.opencloud.rhino.limiting.LimiterMBean
getChildLimiters, getConfigSummary, getConnectedEndPoints, getInfoSummary, getName, getParent, getType, isBypassedDefault, isBypassedForNode, setBypassedDefault, setBypassedForNode, setBypassedForNode, setParent, useDefaultConfig
-
Methods inherited from interface com.opencloud.rhino.limiting.StatLimiterMBean
getLimitPercentages, getLimitPercentagesForNodes, getParameterSet, getStatistic, setParameterSetStatistic
-
-
-
-
Method Detail
-
getTierValues
long[] getTierValues() throws ConfigurationExceptionGet the values representing the limiting tiers.
- Returns:
- an array of the values or an empty array if values not configured
- Throws:
ConfigurationException- if an error occurred reading the limiter configuration.- Since:
- Rhino 2.7.0
-
getTierValuesForNodes
long[][] getTierValuesForNodes(int[] nodeIDs) throws ConfigurationException, InvalidArgumentExceptionGet the per-node values representing the limiting tiers.
- Parameters:
nodeIDs- the IDs of the nodes- Returns:
- a two-dimensional array of the values for each node or an empty array if not configured
- Throws:
ConfigurationException- if an error occurred reading the limiter configuration.InvalidArgumentException- if nodeIDs is a zero-length array.- Since:
- Rhino 2.7.0
-
setTier
void setTier(long value, double limitPercentage) throws ConfigurationException, com.opencloud.util.exception.ValidationExceptionCreate or update the given tier with the specified limit percentage.
- Parameters:
value- the value of the monitored statistic at which this limiter tier will begin to be in effectlimitPercentage- the percentage of requested units to reject while this tier is in effect (must be between 0 to 100 inclusive)- Throws:
ConfigurationException- if an error occurred updating the limiter configuration.com.opencloud.util.exception.ValidationException- if the new limiter configuration is invalid.- Since:
- Rhino 2.7.0
-
setTierForNode
void setTierForNode(long[] values, double[] limitPercentages, int[] nodeIDs) throws ConfigurationException, InvalidArgumentException, com.opencloud.util.exception.ValidationExceptionCreate or update the given per-node value tiers with the specified limit percentages.
- Parameters:
values- the values of the monitored statistic at which each limiter tier will begin to be in effectlimitPercentages- the corresponding percentages of requested units to reject while each tier is in effect (must be between 0 to 100 inclusive)nodeIDs- the IDs of the nodes- Throws:
ConfigurationException- if an error occurred updating the limiter configuration.InvalidArgumentException- if nodeIDs is a zero-length array, or if values, limitPercentages, and nodeIDs differ in length.com.opencloud.util.exception.ValidationException- if the new limiter configuration is invalid.- Since:
- Rhino 2.7.0
-
clearTier
void clearTier(long value) throws ConfigurationException, com.opencloud.util.exception.ValidationExceptionClear (remove) the given tier if it exists.
- Parameters:
value- the value of the tier to remove- Throws:
ConfigurationException- if an error occurred updating the limiter configuration.com.opencloud.util.exception.ValidationException- if the new limiter configuration is invalid.- Since:
- Rhino 2.7.0
-
clearTierForNode
void clearTierForNode(long[] values, int[] nodeIDs) throws ConfigurationException, InvalidArgumentException, com.opencloud.util.exception.ValidationExceptionClear (remove) the given per-node tiers if they exist.
- Parameters:
values- the values of the max value tiers to removenodeIDs- the IDs of the nodes- Throws:
ConfigurationException- if an error occurred updating the limiter configuration.InvalidArgumentException- if nodeIDs is a zero-length array, or if values and nodeIDs differ in length.com.opencloud.util.exception.ValidationException- if the new limiter configuration is invalid.- Since:
- Rhino 2.7.0
-
-