Please wait. This can take some minutes ...
Many resources are needed to download a project. Please understand that we have to compensate our server costs. Thank you in advance.
Project price only 1 $
You can buy this project and download/modify it how often you want.
com.pulumi.kong.inputs.UpstreamState Maven / Gradle / Ivy
Go to download
A Pulumi package for creating and managing Kong 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.kong.inputs;
import com.pulumi.core.Output;
import com.pulumi.core.annotations.Import;
import com.pulumi.kong.inputs.UpstreamHealthchecksArgs;
import java.lang.Integer;
import java.lang.String;
import java.util.List;
import java.util.Objects;
import java.util.Optional;
import javax.annotation.Nullable;
public final class UpstreamState extends com.pulumi.resources.ResourceArgs {
public static final UpstreamState Empty = new UpstreamState();
/**
* The ID of the client certificate to use (from certificate resource) while TLS handshaking to the upstream server.
*
*/
@Import(name="clientCertificateId")
private @Nullable Output clientCertificateId;
/**
* @return The ID of the client certificate to use (from certificate resource) while TLS handshaking to the upstream server.
*
*/
public Optional> clientCertificateId() {
return Optional.ofNullable(this.clientCertificateId);
}
/**
* is a hashing input type if the primary `hash_on` does not return a hash (eg. header is missing, or no consumer identified). One of: `none`, `consumer`, `ip`, `header`, or `cookie`. Not available if `hash_on` is set to `cookie`. Defaults to `none`.
*
*/
@Import(name="hashFallback")
private @Nullable Output hashFallback;
/**
* @return is a hashing input type if the primary `hash_on` does not return a hash (eg. header is missing, or no consumer identified). One of: `none`, `consumer`, `ip`, `header`, or `cookie`. Not available if `hash_on` is set to `cookie`. Defaults to `none`.
*
*/
public Optional> hashFallback() {
return Optional.ofNullable(this.hashFallback);
}
/**
* is a header name to take the value from as hash input. Only required when `hash_fallback` is set to `header`. Default `nil`.
*
*/
@Import(name="hashFallbackHeader")
private @Nullable Output hashFallbackHeader;
/**
* @return is a header name to take the value from as hash input. Only required when `hash_fallback` is set to `header`. Default `nil`.
*
*/
public Optional> hashFallbackHeader() {
return Optional.ofNullable(this.hashFallbackHeader);
}
/**
* is a hashing input type: ` none `(resulting in a weighted*round*robin scheme with no hashing), `consumer`, `ip`, `header`, or `cookie`. Defaults to `none`.
*
*/
@Import(name="hashOn")
private @Nullable Output hashOn;
/**
* @return is a hashing input type: ` none `(resulting in a weighted*round*robin scheme with no hashing), `consumer`, `ip`, `header`, or `cookie`. Defaults to `none`.
*
*/
public Optional> hashOn() {
return Optional.ofNullable(this.hashOn);
}
/**
* is a cookie name to take the value from as hash input. Only required when `hash_on` or `hash_fallback` is set to `cookie`. If the specified cookie is not in the request, Kong will generate a value and set the cookie in the response. Default `nil`.
*
*/
@Import(name="hashOnCookie")
private @Nullable Output hashOnCookie;
/**
* @return is a cookie name to take the value from as hash input. Only required when `hash_on` or `hash_fallback` is set to `cookie`. If the specified cookie is not in the request, Kong will generate a value and set the cookie in the response. Default `nil`.
*
*/
public Optional> hashOnCookie() {
return Optional.ofNullable(this.hashOnCookie);
}
/**
* is a cookie path to set in the response headers. Only required when `hash_on` or `hash_fallback` is set to `cookie`. Defaults to `/`.
* * `healthchecks.active.type` - (Optional) is a active health check type. HTTP or HTTPS, or just attempt a TCP connection. Possible values are `tcp`, `http` or `https`. Defaults to `http`.
* * `healthchecks.active.timeout` - (Optional) is a socket timeout for active health checks (in seconds). Defaults to `1`.
* * `healthchecks.active.concurrency` - (Optional) is a number of targets to check concurrently in active health checks. Defaults to `10`.
* * `healthchecks.active.http_path` - (Optional) is a path to use in GET HTTP request to run as a probe on active health checks. Defaults to `/`.
* * `healthchecks.active.https_verify_certificate` - (Optional) check the validity of the SSL certificate of the remote host when performing active health checks using HTTPS. Defaults to `true`.
* * `healthchecks.active.https_sni` - (Optional) is the hostname to use as an SNI (Server Name Identification) when performing active health checks using HTTPS. This is particularly useful when Targets are configured using IPs, so that the target host’s certificate can be verified with the proper SNI. Default `nil`.
* * `healthchecks.active.healthy.interval` - (Optional) is an interval between active health checks for healthy targets (in seconds). A value of zero indicates that active probes for healthy targets should not be performed. Defaults to `0`.
* * `healthchecks.active.healthy.successes` - (Optional) is a number of successes in active probes (as defined by `healthchecks.active.healthy.http_statuses`) to consider a target healthy. Defaults to `0`.
* * `healthchecks.active.healthy.http_statuses` - (Optional) is an array of HTTP statuses to consider a success, indicating healthiness, when returned by a probe in active health checks. Defaults to `[200, 302]`.
* * `healthchecks.active.unhealthy.interval` - (Optional) is an interval between active health checks for unhealthy targets (in seconds). A value of zero indicates that active probes for unhealthy targets should not be performed. Defaults to `0`.
* * `healthchecks.active.unhealthy.tcp_failures` - (Optional) is a number of TCP failures in active probes to consider a target unhealthy. Defaults to `0`.
* * `healthchecks.active.unhealthy.http_failures` - (Optional) is a number of HTTP failures in active probes (as defined by `healthchecks.active.unhealthy.http_statuses`) to consider a target unhealthy. Defaults to `0`.
* * `healthchecks.active.unhealthy.timeouts` - (Optional) is a number of timeouts in active probes to consider a target unhealthy. Defaults to `0`.
* * `healthchecks.active.unhealthy.http_statuses` - (Optional) is an array of HTTP statuses to consider a failure, indicating unhealthiness, when returned by a probe in active health checks. Defaults to `[429, 404, 500, 501, 502, 503, 504, 505]`.
* * `healthchecks.passive.type` - (Optional) is a passive health check type. Interpreting HTTP/HTTPS statuses, or just check for TCP connection success. Possible values are `tcp`, `http` or `https` (in passive checks, `http` and `https` options are equivalent.). Defaults to `http`.
* * `healthchecks.passive.healthy.successes` - (Optional) is a Number of successes in proxied traffic (as defined by `healthchecks.passive.healthy.http_statuses`) to consider a target healthy, as observed by passive health checks. Defaults to `0`.
* * `healthchecks.passive.healthy.http_statuses` - (Optional) is an array of HTTP statuses which represent healthiness when produced by proxied traffic, as observed by passive health checks. Defaults to `[200, 201, 202, 203, 204, 205, 206, 207, 208, 226, 300, 301, 302, 303, 304, 305, 306, 307, 308]`.
* * `healthchecks.passive.unhealthy.tcp_failures` - (Optional) is a number of TCP failures in proxied traffic to consider a target unhealthy, as observed by passive health checks. Defaults to `0`.
* * `healthchecks.passive.unhealthy.http_failures` - (Optional) is a number of HTTP failures in proxied traffic (as defined by `healthchecks.passive.unhealthy.http_statuses`) to consider a target unhealthy, as observed by passive health checks. Defaults to `0`.
* * `healthchecks.passive.unhealthy.timeouts` - (Optional) is a number of timeouts in proxied traffic to consider a target unhealthy, as observed by passive health checks. Defaults to `0`.
* * `healthchecks.passive.unhealthy.http_statuses` - (Optional) is an array of HTTP statuses which represent unhealthiness when produced by proxied traffic, as observed by passive health checks. Defaults to `[429, 500, 503]`.
*
*/
@Import(name="hashOnCookiePath")
private @Nullable Output hashOnCookiePath;
/**
* @return is a cookie path to set in the response headers. Only required when `hash_on` or `hash_fallback` is set to `cookie`. Defaults to `/`.
* * `healthchecks.active.type` - (Optional) is a active health check type. HTTP or HTTPS, or just attempt a TCP connection. Possible values are `tcp`, `http` or `https`. Defaults to `http`.
* * `healthchecks.active.timeout` - (Optional) is a socket timeout for active health checks (in seconds). Defaults to `1`.
* * `healthchecks.active.concurrency` - (Optional) is a number of targets to check concurrently in active health checks. Defaults to `10`.
* * `healthchecks.active.http_path` - (Optional) is a path to use in GET HTTP request to run as a probe on active health checks. Defaults to `/`.
* * `healthchecks.active.https_verify_certificate` - (Optional) check the validity of the SSL certificate of the remote host when performing active health checks using HTTPS. Defaults to `true`.
* * `healthchecks.active.https_sni` - (Optional) is the hostname to use as an SNI (Server Name Identification) when performing active health checks using HTTPS. This is particularly useful when Targets are configured using IPs, so that the target host’s certificate can be verified with the proper SNI. Default `nil`.
* * `healthchecks.active.healthy.interval` - (Optional) is an interval between active health checks for healthy targets (in seconds). A value of zero indicates that active probes for healthy targets should not be performed. Defaults to `0`.
* * `healthchecks.active.healthy.successes` - (Optional) is a number of successes in active probes (as defined by `healthchecks.active.healthy.http_statuses`) to consider a target healthy. Defaults to `0`.
* * `healthchecks.active.healthy.http_statuses` - (Optional) is an array of HTTP statuses to consider a success, indicating healthiness, when returned by a probe in active health checks. Defaults to `[200, 302]`.
* * `healthchecks.active.unhealthy.interval` - (Optional) is an interval between active health checks for unhealthy targets (in seconds). A value of zero indicates that active probes for unhealthy targets should not be performed. Defaults to `0`.
* * `healthchecks.active.unhealthy.tcp_failures` - (Optional) is a number of TCP failures in active probes to consider a target unhealthy. Defaults to `0`.
* * `healthchecks.active.unhealthy.http_failures` - (Optional) is a number of HTTP failures in active probes (as defined by `healthchecks.active.unhealthy.http_statuses`) to consider a target unhealthy. Defaults to `0`.
* * `healthchecks.active.unhealthy.timeouts` - (Optional) is a number of timeouts in active probes to consider a target unhealthy. Defaults to `0`.
* * `healthchecks.active.unhealthy.http_statuses` - (Optional) is an array of HTTP statuses to consider a failure, indicating unhealthiness, when returned by a probe in active health checks. Defaults to `[429, 404, 500, 501, 502, 503, 504, 505]`.
* * `healthchecks.passive.type` - (Optional) is a passive health check type. Interpreting HTTP/HTTPS statuses, or just check for TCP connection success. Possible values are `tcp`, `http` or `https` (in passive checks, `http` and `https` options are equivalent.). Defaults to `http`.
* * `healthchecks.passive.healthy.successes` - (Optional) is a Number of successes in proxied traffic (as defined by `healthchecks.passive.healthy.http_statuses`) to consider a target healthy, as observed by passive health checks. Defaults to `0`.
* * `healthchecks.passive.healthy.http_statuses` - (Optional) is an array of HTTP statuses which represent healthiness when produced by proxied traffic, as observed by passive health checks. Defaults to `[200, 201, 202, 203, 204, 205, 206, 207, 208, 226, 300, 301, 302, 303, 304, 305, 306, 307, 308]`.
* * `healthchecks.passive.unhealthy.tcp_failures` - (Optional) is a number of TCP failures in proxied traffic to consider a target unhealthy, as observed by passive health checks. Defaults to `0`.
* * `healthchecks.passive.unhealthy.http_failures` - (Optional) is a number of HTTP failures in proxied traffic (as defined by `healthchecks.passive.unhealthy.http_statuses`) to consider a target unhealthy, as observed by passive health checks. Defaults to `0`.
* * `healthchecks.passive.unhealthy.timeouts` - (Optional) is a number of timeouts in proxied traffic to consider a target unhealthy, as observed by passive health checks. Defaults to `0`.
* * `healthchecks.passive.unhealthy.http_statuses` - (Optional) is an array of HTTP statuses which represent unhealthiness when produced by proxied traffic, as observed by passive health checks. Defaults to `[429, 500, 503]`.
*
*/
public Optional> hashOnCookiePath() {
return Optional.ofNullable(this.hashOnCookiePath);
}
/**
* is a header name to take the value from as hash input. Only required when `hash_on` is set to `header`. Default `nil`.
*
*/
@Import(name="hashOnHeader")
private @Nullable Output hashOnHeader;
/**
* @return is a header name to take the value from as hash input. Only required when `hash_on` is set to `header`. Default `nil`.
*
*/
public Optional> hashOnHeader() {
return Optional.ofNullable(this.hashOnHeader);
}
@Import(name="healthchecks")
private @Nullable Output healthchecks;
public Optional> healthchecks() {
return Optional.ofNullable(this.healthchecks);
}
/**
* The hostname to be used as Host header when proxying requests through Kong.
*
*/
@Import(name="hostHeader")
private @Nullable Output hostHeader;
/**
* @return The hostname to be used as Host header when proxying requests through Kong.
*
*/
public Optional> hostHeader() {
return Optional.ofNullable(this.hostHeader);
}
/**
* is a hostname, which must be equal to the host of a Service.
*
*/
@Import(name="name")
private @Nullable Output name;
/**
* @return is a hostname, which must be equal to the host of a Service.
*
*/
public Optional> name() {
return Optional.ofNullable(this.name);
}
/**
* is the number of slots in the load balancer algorithm (10*65536, defaults to 10000).
*
*/
@Import(name="slots")
private @Nullable Output slots;
/**
* @return is the number of slots in the load balancer algorithm (10*65536, defaults to 10000).
*
*/
public Optional> slots() {
return Optional.ofNullable(this.slots);
}
/**
* A list of strings associated with the Upstream for grouping and filtering.
*
*/
@Import(name="tags")
private @Nullable Output> tags;
/**
* @return A list of strings associated with the Upstream for grouping and filtering.
*
*/
public Optional>> tags() {
return Optional.ofNullable(this.tags);
}
private UpstreamState() {}
private UpstreamState(UpstreamState $) {
this.clientCertificateId = $.clientCertificateId;
this.hashFallback = $.hashFallback;
this.hashFallbackHeader = $.hashFallbackHeader;
this.hashOn = $.hashOn;
this.hashOnCookie = $.hashOnCookie;
this.hashOnCookiePath = $.hashOnCookiePath;
this.hashOnHeader = $.hashOnHeader;
this.healthchecks = $.healthchecks;
this.hostHeader = $.hostHeader;
this.name = $.name;
this.slots = $.slots;
this.tags = $.tags;
}
public static Builder builder() {
return new Builder();
}
public static Builder builder(UpstreamState defaults) {
return new Builder(defaults);
}
public static final class Builder {
private UpstreamState $;
public Builder() {
$ = new UpstreamState();
}
public Builder(UpstreamState defaults) {
$ = new UpstreamState(Objects.requireNonNull(defaults));
}
/**
* @param clientCertificateId The ID of the client certificate to use (from certificate resource) while TLS handshaking to the upstream server.
*
* @return builder
*
*/
public Builder clientCertificateId(@Nullable Output clientCertificateId) {
$.clientCertificateId = clientCertificateId;
return this;
}
/**
* @param clientCertificateId The ID of the client certificate to use (from certificate resource) while TLS handshaking to the upstream server.
*
* @return builder
*
*/
public Builder clientCertificateId(String clientCertificateId) {
return clientCertificateId(Output.of(clientCertificateId));
}
/**
* @param hashFallback is a hashing input type if the primary `hash_on` does not return a hash (eg. header is missing, or no consumer identified). One of: `none`, `consumer`, `ip`, `header`, or `cookie`. Not available if `hash_on` is set to `cookie`. Defaults to `none`.
*
* @return builder
*
*/
public Builder hashFallback(@Nullable Output hashFallback) {
$.hashFallback = hashFallback;
return this;
}
/**
* @param hashFallback is a hashing input type if the primary `hash_on` does not return a hash (eg. header is missing, or no consumer identified). One of: `none`, `consumer`, `ip`, `header`, or `cookie`. Not available if `hash_on` is set to `cookie`. Defaults to `none`.
*
* @return builder
*
*/
public Builder hashFallback(String hashFallback) {
return hashFallback(Output.of(hashFallback));
}
/**
* @param hashFallbackHeader is a header name to take the value from as hash input. Only required when `hash_fallback` is set to `header`. Default `nil`.
*
* @return builder
*
*/
public Builder hashFallbackHeader(@Nullable Output hashFallbackHeader) {
$.hashFallbackHeader = hashFallbackHeader;
return this;
}
/**
* @param hashFallbackHeader is a header name to take the value from as hash input. Only required when `hash_fallback` is set to `header`. Default `nil`.
*
* @return builder
*
*/
public Builder hashFallbackHeader(String hashFallbackHeader) {
return hashFallbackHeader(Output.of(hashFallbackHeader));
}
/**
* @param hashOn is a hashing input type: ` none `(resulting in a weighted*round*robin scheme with no hashing), `consumer`, `ip`, `header`, or `cookie`. Defaults to `none`.
*
* @return builder
*
*/
public Builder hashOn(@Nullable Output hashOn) {
$.hashOn = hashOn;
return this;
}
/**
* @param hashOn is a hashing input type: ` none `(resulting in a weighted*round*robin scheme with no hashing), `consumer`, `ip`, `header`, or `cookie`. Defaults to `none`.
*
* @return builder
*
*/
public Builder hashOn(String hashOn) {
return hashOn(Output.of(hashOn));
}
/**
* @param hashOnCookie is a cookie name to take the value from as hash input. Only required when `hash_on` or `hash_fallback` is set to `cookie`. If the specified cookie is not in the request, Kong will generate a value and set the cookie in the response. Default `nil`.
*
* @return builder
*
*/
public Builder hashOnCookie(@Nullable Output hashOnCookie) {
$.hashOnCookie = hashOnCookie;
return this;
}
/**
* @param hashOnCookie is a cookie name to take the value from as hash input. Only required when `hash_on` or `hash_fallback` is set to `cookie`. If the specified cookie is not in the request, Kong will generate a value and set the cookie in the response. Default `nil`.
*
* @return builder
*
*/
public Builder hashOnCookie(String hashOnCookie) {
return hashOnCookie(Output.of(hashOnCookie));
}
/**
* @param hashOnCookiePath is a cookie path to set in the response headers. Only required when `hash_on` or `hash_fallback` is set to `cookie`. Defaults to `/`.
* * `healthchecks.active.type` - (Optional) is a active health check type. HTTP or HTTPS, or just attempt a TCP connection. Possible values are `tcp`, `http` or `https`. Defaults to `http`.
* * `healthchecks.active.timeout` - (Optional) is a socket timeout for active health checks (in seconds). Defaults to `1`.
* * `healthchecks.active.concurrency` - (Optional) is a number of targets to check concurrently in active health checks. Defaults to `10`.
* * `healthchecks.active.http_path` - (Optional) is a path to use in GET HTTP request to run as a probe on active health checks. Defaults to `/`.
* * `healthchecks.active.https_verify_certificate` - (Optional) check the validity of the SSL certificate of the remote host when performing active health checks using HTTPS. Defaults to `true`.
* * `healthchecks.active.https_sni` - (Optional) is the hostname to use as an SNI (Server Name Identification) when performing active health checks using HTTPS. This is particularly useful when Targets are configured using IPs, so that the target host’s certificate can be verified with the proper SNI. Default `nil`.
* * `healthchecks.active.healthy.interval` - (Optional) is an interval between active health checks for healthy targets (in seconds). A value of zero indicates that active probes for healthy targets should not be performed. Defaults to `0`.
* * `healthchecks.active.healthy.successes` - (Optional) is a number of successes in active probes (as defined by `healthchecks.active.healthy.http_statuses`) to consider a target healthy. Defaults to `0`.
* * `healthchecks.active.healthy.http_statuses` - (Optional) is an array of HTTP statuses to consider a success, indicating healthiness, when returned by a probe in active health checks. Defaults to `[200, 302]`.
* * `healthchecks.active.unhealthy.interval` - (Optional) is an interval between active health checks for unhealthy targets (in seconds). A value of zero indicates that active probes for unhealthy targets should not be performed. Defaults to `0`.
* * `healthchecks.active.unhealthy.tcp_failures` - (Optional) is a number of TCP failures in active probes to consider a target unhealthy. Defaults to `0`.
* * `healthchecks.active.unhealthy.http_failures` - (Optional) is a number of HTTP failures in active probes (as defined by `healthchecks.active.unhealthy.http_statuses`) to consider a target unhealthy. Defaults to `0`.
* * `healthchecks.active.unhealthy.timeouts` - (Optional) is a number of timeouts in active probes to consider a target unhealthy. Defaults to `0`.
* * `healthchecks.active.unhealthy.http_statuses` - (Optional) is an array of HTTP statuses to consider a failure, indicating unhealthiness, when returned by a probe in active health checks. Defaults to `[429, 404, 500, 501, 502, 503, 504, 505]`.
* * `healthchecks.passive.type` - (Optional) is a passive health check type. Interpreting HTTP/HTTPS statuses, or just check for TCP connection success. Possible values are `tcp`, `http` or `https` (in passive checks, `http` and `https` options are equivalent.). Defaults to `http`.
* * `healthchecks.passive.healthy.successes` - (Optional) is a Number of successes in proxied traffic (as defined by `healthchecks.passive.healthy.http_statuses`) to consider a target healthy, as observed by passive health checks. Defaults to `0`.
* * `healthchecks.passive.healthy.http_statuses` - (Optional) is an array of HTTP statuses which represent healthiness when produced by proxied traffic, as observed by passive health checks. Defaults to `[200, 201, 202, 203, 204, 205, 206, 207, 208, 226, 300, 301, 302, 303, 304, 305, 306, 307, 308]`.
* * `healthchecks.passive.unhealthy.tcp_failures` - (Optional) is a number of TCP failures in proxied traffic to consider a target unhealthy, as observed by passive health checks. Defaults to `0`.
* * `healthchecks.passive.unhealthy.http_failures` - (Optional) is a number of HTTP failures in proxied traffic (as defined by `healthchecks.passive.unhealthy.http_statuses`) to consider a target unhealthy, as observed by passive health checks. Defaults to `0`.
* * `healthchecks.passive.unhealthy.timeouts` - (Optional) is a number of timeouts in proxied traffic to consider a target unhealthy, as observed by passive health checks. Defaults to `0`.
* * `healthchecks.passive.unhealthy.http_statuses` - (Optional) is an array of HTTP statuses which represent unhealthiness when produced by proxied traffic, as observed by passive health checks. Defaults to `[429, 500, 503]`.
*
* @return builder
*
*/
public Builder hashOnCookiePath(@Nullable Output hashOnCookiePath) {
$.hashOnCookiePath = hashOnCookiePath;
return this;
}
/**
* @param hashOnCookiePath is a cookie path to set in the response headers. Only required when `hash_on` or `hash_fallback` is set to `cookie`. Defaults to `/`.
* * `healthchecks.active.type` - (Optional) is a active health check type. HTTP or HTTPS, or just attempt a TCP connection. Possible values are `tcp`, `http` or `https`. Defaults to `http`.
* * `healthchecks.active.timeout` - (Optional) is a socket timeout for active health checks (in seconds). Defaults to `1`.
* * `healthchecks.active.concurrency` - (Optional) is a number of targets to check concurrently in active health checks. Defaults to `10`.
* * `healthchecks.active.http_path` - (Optional) is a path to use in GET HTTP request to run as a probe on active health checks. Defaults to `/`.
* * `healthchecks.active.https_verify_certificate` - (Optional) check the validity of the SSL certificate of the remote host when performing active health checks using HTTPS. Defaults to `true`.
* * `healthchecks.active.https_sni` - (Optional) is the hostname to use as an SNI (Server Name Identification) when performing active health checks using HTTPS. This is particularly useful when Targets are configured using IPs, so that the target host’s certificate can be verified with the proper SNI. Default `nil`.
* * `healthchecks.active.healthy.interval` - (Optional) is an interval between active health checks for healthy targets (in seconds). A value of zero indicates that active probes for healthy targets should not be performed. Defaults to `0`.
* * `healthchecks.active.healthy.successes` - (Optional) is a number of successes in active probes (as defined by `healthchecks.active.healthy.http_statuses`) to consider a target healthy. Defaults to `0`.
* * `healthchecks.active.healthy.http_statuses` - (Optional) is an array of HTTP statuses to consider a success, indicating healthiness, when returned by a probe in active health checks. Defaults to `[200, 302]`.
* * `healthchecks.active.unhealthy.interval` - (Optional) is an interval between active health checks for unhealthy targets (in seconds). A value of zero indicates that active probes for unhealthy targets should not be performed. Defaults to `0`.
* * `healthchecks.active.unhealthy.tcp_failures` - (Optional) is a number of TCP failures in active probes to consider a target unhealthy. Defaults to `0`.
* * `healthchecks.active.unhealthy.http_failures` - (Optional) is a number of HTTP failures in active probes (as defined by `healthchecks.active.unhealthy.http_statuses`) to consider a target unhealthy. Defaults to `0`.
* * `healthchecks.active.unhealthy.timeouts` - (Optional) is a number of timeouts in active probes to consider a target unhealthy. Defaults to `0`.
* * `healthchecks.active.unhealthy.http_statuses` - (Optional) is an array of HTTP statuses to consider a failure, indicating unhealthiness, when returned by a probe in active health checks. Defaults to `[429, 404, 500, 501, 502, 503, 504, 505]`.
* * `healthchecks.passive.type` - (Optional) is a passive health check type. Interpreting HTTP/HTTPS statuses, or just check for TCP connection success. Possible values are `tcp`, `http` or `https` (in passive checks, `http` and `https` options are equivalent.). Defaults to `http`.
* * `healthchecks.passive.healthy.successes` - (Optional) is a Number of successes in proxied traffic (as defined by `healthchecks.passive.healthy.http_statuses`) to consider a target healthy, as observed by passive health checks. Defaults to `0`.
* * `healthchecks.passive.healthy.http_statuses` - (Optional) is an array of HTTP statuses which represent healthiness when produced by proxied traffic, as observed by passive health checks. Defaults to `[200, 201, 202, 203, 204, 205, 206, 207, 208, 226, 300, 301, 302, 303, 304, 305, 306, 307, 308]`.
* * `healthchecks.passive.unhealthy.tcp_failures` - (Optional) is a number of TCP failures in proxied traffic to consider a target unhealthy, as observed by passive health checks. Defaults to `0`.
* * `healthchecks.passive.unhealthy.http_failures` - (Optional) is a number of HTTP failures in proxied traffic (as defined by `healthchecks.passive.unhealthy.http_statuses`) to consider a target unhealthy, as observed by passive health checks. Defaults to `0`.
* * `healthchecks.passive.unhealthy.timeouts` - (Optional) is a number of timeouts in proxied traffic to consider a target unhealthy, as observed by passive health checks. Defaults to `0`.
* * `healthchecks.passive.unhealthy.http_statuses` - (Optional) is an array of HTTP statuses which represent unhealthiness when produced by proxied traffic, as observed by passive health checks. Defaults to `[429, 500, 503]`.
*
* @return builder
*
*/
public Builder hashOnCookiePath(String hashOnCookiePath) {
return hashOnCookiePath(Output.of(hashOnCookiePath));
}
/**
* @param hashOnHeader is a header name to take the value from as hash input. Only required when `hash_on` is set to `header`. Default `nil`.
*
* @return builder
*
*/
public Builder hashOnHeader(@Nullable Output hashOnHeader) {
$.hashOnHeader = hashOnHeader;
return this;
}
/**
* @param hashOnHeader is a header name to take the value from as hash input. Only required when `hash_on` is set to `header`. Default `nil`.
*
* @return builder
*
*/
public Builder hashOnHeader(String hashOnHeader) {
return hashOnHeader(Output.of(hashOnHeader));
}
public Builder healthchecks(@Nullable Output healthchecks) {
$.healthchecks = healthchecks;
return this;
}
public Builder healthchecks(UpstreamHealthchecksArgs healthchecks) {
return healthchecks(Output.of(healthchecks));
}
/**
* @param hostHeader The hostname to be used as Host header when proxying requests through Kong.
*
* @return builder
*
*/
public Builder hostHeader(@Nullable Output hostHeader) {
$.hostHeader = hostHeader;
return this;
}
/**
* @param hostHeader The hostname to be used as Host header when proxying requests through Kong.
*
* @return builder
*
*/
public Builder hostHeader(String hostHeader) {
return hostHeader(Output.of(hostHeader));
}
/**
* @param name is a hostname, which must be equal to the host of a Service.
*
* @return builder
*
*/
public Builder name(@Nullable Output name) {
$.name = name;
return this;
}
/**
* @param name is a hostname, which must be equal to the host of a Service.
*
* @return builder
*
*/
public Builder name(String name) {
return name(Output.of(name));
}
/**
* @param slots is the number of slots in the load balancer algorithm (10*65536, defaults to 10000).
*
* @return builder
*
*/
public Builder slots(@Nullable Output slots) {
$.slots = slots;
return this;
}
/**
* @param slots is the number of slots in the load balancer algorithm (10*65536, defaults to 10000).
*
* @return builder
*
*/
public Builder slots(Integer slots) {
return slots(Output.of(slots));
}
/**
* @param tags A list of strings associated with the Upstream for grouping and filtering.
*
* @return builder
*
*/
public Builder tags(@Nullable Output> tags) {
$.tags = tags;
return this;
}
/**
* @param tags A list of strings associated with the Upstream for grouping and filtering.
*
* @return builder
*
*/
public Builder tags(List tags) {
return tags(Output.of(tags));
}
/**
* @param tags A list of strings associated with the Upstream for grouping and filtering.
*
* @return builder
*
*/
public Builder tags(String... tags) {
return tags(List.of(tags));
}
public UpstreamState build() {
return $;
}
}
}