Class CoresVariable
- java.lang.Object
-
- org.apache.solr.client.solrj.cloud.autoscaling.VariableBase
-
- org.apache.solr.client.solrj.cloud.autoscaling.CoresVariable
-
- All Implemented Interfaces:
Variable
public class CoresVariable extends VariableBase
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from class org.apache.solr.client.solrj.cloud.autoscaling.VariableBase
VariableBase.CoreIndexSizeVariable, VariableBase.DiskTypeVariable, VariableBase.LazyVariable, VariableBase.TotalDiskVariable
-
Nested classes/interfaces inherited from interface org.apache.solr.client.solrj.cloud.autoscaling.Variable
Variable.Meta, Variable.Type
-
-
Field Summary
-
Fields inherited from interface org.apache.solr.client.solrj.cloud.autoscaling.Variable
coreidxsize, NULL
-
-
Constructor Summary
Constructors Constructor Description CoresVariable(Variable.Type type)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description boolean
addViolatingReplicas(org.apache.solr.client.solrj.cloud.autoscaling.Violation.Ctx ctx)
Object
computeValue(Policy.Session session, Condition condition, String collection, String shard, String node)
When a non constant value is used in a variable, the actual value needs to be computed at the runtimeOperand
getOperand(Operand expected, Object strVal, ComputedType computedType)
void
getSuggestions(org.apache.solr.client.solrj.cloud.autoscaling.Suggestion.Ctx ctx)
String
postValidate(Condition condition)
void
projectAddReplica(Cell cell, ReplicaInfo ri, Consumer<org.apache.solr.client.solrj.cloud.autoscaling.Row.OperationInfo> ops, boolean strictMode)
void
projectRemoveReplica(Cell cell, ReplicaInfo ri, Consumer<org.apache.solr.client.solrj.cloud.autoscaling.Row.OperationInfo> opCollector)
Object
validate(String name, Object val, boolean isRuleVal)
-
Methods inherited from class org.apache.solr.client.solrj.cloud.autoscaling.VariableBase
compareViolation, getTagType
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface org.apache.solr.client.solrj.cloud.autoscaling.Variable
computeDeviation, convertVal, match
-
-
-
-
Constructor Detail
-
CoresVariable
public CoresVariable(Variable.Type type)
-
-
Method Detail
-
validate
public Object validate(String name, Object val, boolean isRuleVal)
- Specified by:
validate
in interfaceVariable
- Overrides:
validate
in classVariableBase
-
addViolatingReplicas
public boolean addViolatingReplicas(org.apache.solr.client.solrj.cloud.autoscaling.Violation.Ctx ctx)
-
getSuggestions
public void getSuggestions(org.apache.solr.client.solrj.cloud.autoscaling.Suggestion.Ctx ctx)
- Specified by:
getSuggestions
in interfaceVariable
- Overrides:
getSuggestions
in classVariableBase
-
projectAddReplica
public void projectAddReplica(Cell cell, ReplicaInfo ri, Consumer<org.apache.solr.client.solrj.cloud.autoscaling.Row.OperationInfo> ops, boolean strictMode)
-
projectRemoveReplica
public void projectRemoveReplica(Cell cell, ReplicaInfo ri, Consumer<org.apache.solr.client.solrj.cloud.autoscaling.Row.OperationInfo> opCollector)
-
computeValue
public Object computeValue(Policy.Session session, Condition condition, String collection, String shard, String node)
Description copied from interface:Variable
When a non constant value is used in a variable, the actual value needs to be computed at the runtime
-
postValidate
public String postValidate(Condition condition)
- Specified by:
postValidate
in interfaceVariable
- Overrides:
postValidate
in classVariableBase
-
getOperand
public Operand getOperand(Operand expected, Object strVal, ComputedType computedType)
-
-