
com.pulumi.azurenative.apimanagement.outputs.CircuitBreakerRuleResponse Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of azure-native Show documentation
Show all versions of azure-native Show documentation
A native Pulumi package for creating and managing Azure resources.
// *** 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.apimanagement.outputs;
import com.pulumi.azurenative.apimanagement.outputs.CircuitBreakerFailureConditionResponse;
import com.pulumi.core.annotations.CustomType;
import java.lang.Boolean;
import java.lang.String;
import java.util.Objects;
import java.util.Optional;
import javax.annotation.Nullable;
@CustomType
public final class CircuitBreakerRuleResponse {
/**
* @return flag to accept Retry-After header from the backend.
*
*/
private @Nullable Boolean acceptRetryAfter;
/**
* @return The conditions for tripping the circuit breaker.
*
*/
private @Nullable CircuitBreakerFailureConditionResponse failureCondition;
/**
* @return The rule name.
*
*/
private @Nullable String name;
/**
* @return The duration for which the circuit will be tripped.
*
*/
private @Nullable String tripDuration;
private CircuitBreakerRuleResponse() {}
/**
* @return flag to accept Retry-After header from the backend.
*
*/
public Optional acceptRetryAfter() {
return Optional.ofNullable(this.acceptRetryAfter);
}
/**
* @return The conditions for tripping the circuit breaker.
*
*/
public Optional failureCondition() {
return Optional.ofNullable(this.failureCondition);
}
/**
* @return The rule name.
*
*/
public Optional name() {
return Optional.ofNullable(this.name);
}
/**
* @return The duration for which the circuit will be tripped.
*
*/
public Optional tripDuration() {
return Optional.ofNullable(this.tripDuration);
}
public static Builder builder() {
return new Builder();
}
public static Builder builder(CircuitBreakerRuleResponse defaults) {
return new Builder(defaults);
}
@CustomType.Builder
public static final class Builder {
private @Nullable Boolean acceptRetryAfter;
private @Nullable CircuitBreakerFailureConditionResponse failureCondition;
private @Nullable String name;
private @Nullable String tripDuration;
public Builder() {}
public Builder(CircuitBreakerRuleResponse defaults) {
Objects.requireNonNull(defaults);
this.acceptRetryAfter = defaults.acceptRetryAfter;
this.failureCondition = defaults.failureCondition;
this.name = defaults.name;
this.tripDuration = defaults.tripDuration;
}
@CustomType.Setter
public Builder acceptRetryAfter(@Nullable Boolean acceptRetryAfter) {
this.acceptRetryAfter = acceptRetryAfter;
return this;
}
@CustomType.Setter
public Builder failureCondition(@Nullable CircuitBreakerFailureConditionResponse failureCondition) {
this.failureCondition = failureCondition;
return this;
}
@CustomType.Setter
public Builder name(@Nullable String name) {
this.name = name;
return this;
}
@CustomType.Setter
public Builder tripDuration(@Nullable String tripDuration) {
this.tripDuration = tripDuration;
return this;
}
public CircuitBreakerRuleResponse build() {
final var _resultValue = new CircuitBreakerRuleResponse();
_resultValue.acceptRetryAfter = acceptRetryAfter;
_resultValue.failureCondition = failureCondition;
_resultValue.name = name;
_resultValue.tripDuration = tripDuration;
return _resultValue;
}
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy