ClusterHealthPolicy Class
- java.
lang. Object - com.
azure. resourcemanager. servicefabric. models. ClusterHealthPolicy
- com.
public final class ClusterHealthPolicy
Defines a health policy used to evaluate the health of the cluster or of a cluster node.
Constructor Summary
Constructor | Description |
---|---|
ClusterHealthPolicy() |
Creates an instance of Cluster |
Method Summary
Modifier and Type | Method and Description |
---|---|
Map<String,Application |
applicationHealthPolicies()
Get the application |
Integer |
maxPercentUnhealthyApplications()
Get the max |
Integer |
maxPercentUnhealthyNodes()
Get the max |
void |
validate()
Validates the instance. |
Cluster |
withApplicationHealthPolicies(Map<String,ApplicationHealthPolicy> applicationHealthPolicies)
Set the application |
Cluster |
withMaxPercentUnhealthyApplications(Integer maxPercentUnhealthyApplications)
Set the max |
Cluster |
withMaxPercentUnhealthyNodes(Integer maxPercentUnhealthyNodes)
Set the max |
Methods inherited from java.lang.Object
Constructor Details
ClusterHealthPolicy
public ClusterHealthPolicy()
Creates an instance of ClusterHealthPolicy class.
Method Details
applicationHealthPolicies
public Map
Get the applicationHealthPolicies property: Defines the application health policy map used to evaluate the health of an application or one of its children entities.
Returns:
maxPercentUnhealthyApplications
public Integer maxPercentUnhealthyApplications()
Get the maxPercentUnhealthyApplications property: The maximum allowed percentage of unhealthy applications before reporting an error. For example, to allow 10% of applications to be unhealthy, this value would be 10. The percentage represents the maximum tolerated percentage of applications that can be unhealthy before the cluster is considered in error. If the percentage is respected but there is at least one unhealthy application, the health is evaluated as Warning. This is calculated by dividing the number of unhealthy applications over the total number of application instances in the cluster, excluding applications of application types that are included in the ApplicationTypeHealthPolicyMap. The computation rounds up to tolerate one failure on small numbers of applications. Default percentage is zero.
Returns:
maxPercentUnhealthyNodes
public Integer maxPercentUnhealthyNodes()
Get the maxPercentUnhealthyNodes property: The maximum allowed percentage of unhealthy nodes before reporting an error. For example, to allow 10% of nodes to be unhealthy, this value would be 10. The percentage represents the maximum tolerated percentage of nodes that can be unhealthy before the cluster is considered in error. If the percentage is respected but there is at least one unhealthy node, the health is evaluated as Warning. The percentage is calculated by dividing the number of unhealthy nodes over the total number of nodes in the cluster. The computation rounds up to tolerate one failure on small numbers of nodes. Default percentage is zero. In large clusters, some nodes will always be down or out for repairs, so this percentage should be configured to tolerate that.
Returns:
validate
public void validate()
Validates the instance.
withApplicationHealthPolicies
public ClusterHealthPolicy withApplicationHealthPolicies(Map
Set the applicationHealthPolicies property: Defines the application health policy map used to evaluate the health of an application or one of its children entities.
Parameters:
Returns:
withMaxPercentUnhealthyApplications
public ClusterHealthPolicy withMaxPercentUnhealthyApplications(Integer maxPercentUnhealthyApplications)
Set the maxPercentUnhealthyApplications property: The maximum allowed percentage of unhealthy applications before reporting an error. For example, to allow 10% of applications to be unhealthy, this value would be 10. The percentage represents the maximum tolerated percentage of applications that can be unhealthy before the cluster is considered in error. If the percentage is respected but there is at least one unhealthy application, the health is evaluated as Warning. This is calculated by dividing the number of unhealthy applications over the total number of application instances in the cluster, excluding applications of application types that are included in the ApplicationTypeHealthPolicyMap. The computation rounds up to tolerate one failure on small numbers of applications. Default percentage is zero.
Parameters:
Returns:
withMaxPercentUnhealthyNodes
public ClusterHealthPolicy withMaxPercentUnhealthyNodes(Integer maxPercentUnhealthyNodes)
Set the maxPercentUnhealthyNodes property: The maximum allowed percentage of unhealthy nodes before reporting an error. For example, to allow 10% of nodes to be unhealthy, this value would be 10. The percentage represents the maximum tolerated percentage of nodes that can be unhealthy before the cluster is considered in error. If the percentage is respected but there is at least one unhealthy node, the health is evaluated as Warning. The percentage is calculated by dividing the number of unhealthy nodes over the total number of nodes in the cluster. The computation rounds up to tolerate one failure on small numbers of nodes. Default percentage is zero. In large clusters, some nodes will always be down or out for repairs, so this percentage should be configured to tolerate that.
Parameters:
Returns:
Applies to
Azure SDK for Java
Feedback
https://aka.ms/ContentUserFeedback.
Coming soon: Throughout 2024 we will be phasing out GitHub Issues as the feedback mechanism for content and replacing it with a new feedback system. For more information see:Submit and view feedback for