
com.pulumi.azurenative.servicefabric.outputs.AverageServiceLoadScalingTriggerResponse Maven / Gradle / Ivy
// *** WARNING: this file was generated by pulumi-java-gen. ***
// *** Do not edit by hand unless you're certain you know what you are doing! ***
package com.pulumi.azurenative.servicefabric.outputs;
import com.pulumi.core.annotations.CustomType;
import com.pulumi.exceptions.MissingRequiredPropertyException;
import java.lang.Boolean;
import java.lang.Double;
import java.lang.String;
import java.util.Objects;
@CustomType
public final class AverageServiceLoadScalingTriggerResponse {
/**
* @return Enumerates the ways that a service can be partitioned.
* Expected value is 'AverageServiceLoadTrigger'.
*
*/
private String kind;
/**
* @return The lower limit of the load below which a scale in operation should be performed.
*
*/
private Double lowerLoadThreshold;
/**
* @return The name of the metric for which usage should be tracked.
*
*/
private String metricName;
/**
* @return The period in seconds on which a decision is made whether to scale or not. This property should come in ISO 8601 format "hh:mm:ss".
*
*/
private String scaleInterval;
/**
* @return The upper limit of the load beyond which a scale out operation should be performed.
*
*/
private Double upperLoadThreshold;
/**
* @return Flag determines whether only the load of primary replica should be considered for scaling. If set to true, then trigger will only consider the load of primary replicas of stateful service. If set to false, trigger will consider load of all replicas. This parameter cannot be set to true for stateless service.
*
*/
private Boolean useOnlyPrimaryLoad;
private AverageServiceLoadScalingTriggerResponse() {}
/**
* @return Enumerates the ways that a service can be partitioned.
* Expected value is 'AverageServiceLoadTrigger'.
*
*/
public String kind() {
return this.kind;
}
/**
* @return The lower limit of the load below which a scale in operation should be performed.
*
*/
public Double lowerLoadThreshold() {
return this.lowerLoadThreshold;
}
/**
* @return The name of the metric for which usage should be tracked.
*
*/
public String metricName() {
return this.metricName;
}
/**
* @return The period in seconds on which a decision is made whether to scale or not. This property should come in ISO 8601 format "hh:mm:ss".
*
*/
public String scaleInterval() {
return this.scaleInterval;
}
/**
* @return The upper limit of the load beyond which a scale out operation should be performed.
*
*/
public Double upperLoadThreshold() {
return this.upperLoadThreshold;
}
/**
* @return Flag determines whether only the load of primary replica should be considered for scaling. If set to true, then trigger will only consider the load of primary replicas of stateful service. If set to false, trigger will consider load of all replicas. This parameter cannot be set to true for stateless service.
*
*/
public Boolean useOnlyPrimaryLoad() {
return this.useOnlyPrimaryLoad;
}
public static Builder builder() {
return new Builder();
}
public static Builder builder(AverageServiceLoadScalingTriggerResponse defaults) {
return new Builder(defaults);
}
@CustomType.Builder
public static final class Builder {
private String kind;
private Double lowerLoadThreshold;
private String metricName;
private String scaleInterval;
private Double upperLoadThreshold;
private Boolean useOnlyPrimaryLoad;
public Builder() {}
public Builder(AverageServiceLoadScalingTriggerResponse defaults) {
Objects.requireNonNull(defaults);
this.kind = defaults.kind;
this.lowerLoadThreshold = defaults.lowerLoadThreshold;
this.metricName = defaults.metricName;
this.scaleInterval = defaults.scaleInterval;
this.upperLoadThreshold = defaults.upperLoadThreshold;
this.useOnlyPrimaryLoad = defaults.useOnlyPrimaryLoad;
}
@CustomType.Setter
public Builder kind(String kind) {
if (kind == null) {
throw new MissingRequiredPropertyException("AverageServiceLoadScalingTriggerResponse", "kind");
}
this.kind = kind;
return this;
}
@CustomType.Setter
public Builder lowerLoadThreshold(Double lowerLoadThreshold) {
if (lowerLoadThreshold == null) {
throw new MissingRequiredPropertyException("AverageServiceLoadScalingTriggerResponse", "lowerLoadThreshold");
}
this.lowerLoadThreshold = lowerLoadThreshold;
return this;
}
@CustomType.Setter
public Builder metricName(String metricName) {
if (metricName == null) {
throw new MissingRequiredPropertyException("AverageServiceLoadScalingTriggerResponse", "metricName");
}
this.metricName = metricName;
return this;
}
@CustomType.Setter
public Builder scaleInterval(String scaleInterval) {
if (scaleInterval == null) {
throw new MissingRequiredPropertyException("AverageServiceLoadScalingTriggerResponse", "scaleInterval");
}
this.scaleInterval = scaleInterval;
return this;
}
@CustomType.Setter
public Builder upperLoadThreshold(Double upperLoadThreshold) {
if (upperLoadThreshold == null) {
throw new MissingRequiredPropertyException("AverageServiceLoadScalingTriggerResponse", "upperLoadThreshold");
}
this.upperLoadThreshold = upperLoadThreshold;
return this;
}
@CustomType.Setter
public Builder useOnlyPrimaryLoad(Boolean useOnlyPrimaryLoad) {
if (useOnlyPrimaryLoad == null) {
throw new MissingRequiredPropertyException("AverageServiceLoadScalingTriggerResponse", "useOnlyPrimaryLoad");
}
this.useOnlyPrimaryLoad = useOnlyPrimaryLoad;
return this;
}
public AverageServiceLoadScalingTriggerResponse build() {
final var _resultValue = new AverageServiceLoadScalingTriggerResponse();
_resultValue.kind = kind;
_resultValue.lowerLoadThreshold = lowerLoadThreshold;
_resultValue.metricName = metricName;
_resultValue.scaleInterval = scaleInterval;
_resultValue.upperLoadThreshold = upperLoadThreshold;
_resultValue.useOnlyPrimaryLoad = useOnlyPrimaryLoad;
return _resultValue;
}
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy