All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.pulumi.alicloud.waf.inputs.DomainState Maven / Gradle / Ivy

There is a newer version: 3.63.0-alpha.1727424957
Show newest version
// *** 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.alicloud.waf.inputs;

import com.pulumi.alicloud.waf.inputs.DomainLogHeaderArgs;
import com.pulumi.core.Output;
import com.pulumi.core.annotations.Import;
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 DomainState extends com.pulumi.resources.ResourceArgs {

    public static final DomainState Empty = new DomainState();

    /**
     * The type of the WAF cluster. Valid values: `PhysicalCluster` and `VirtualCluster`. Default to `PhysicalCluster`.
     * 
     */
    @Import(name="clusterType")
    private @Nullable Output clusterType;

    /**
     * @return The type of the WAF cluster. Valid values: `PhysicalCluster` and `VirtualCluster`. Default to `PhysicalCluster`.
     * 
     */
    public Optional> clusterType() {
        return Optional.ofNullable(this.clusterType);
    }

    /**
     * The CNAME record assigned by the WAF instance to the specified domain.
     * 
     */
    @Import(name="cname")
    private @Nullable Output cname;

    /**
     * @return The CNAME record assigned by the WAF instance to the specified domain.
     * 
     */
    public Optional> cname() {
        return Optional.ofNullable(this.cname);
    }

    /**
     * The connection timeout for WAF exclusive clusters. Unit: seconds.
     * 
     */
    @Import(name="connectionTime")
    private @Nullable Output connectionTime;

    /**
     * @return The connection timeout for WAF exclusive clusters. Unit: seconds.
     * 
     */
    public Optional> connectionTime() {
        return Optional.ofNullable(this.connectionTime);
    }

    /**
     * Field `domain` has been deprecated from version 1.94.0. Use `domain_name` instead.
     * 
     * @deprecated
     * Field 'domain' has been deprecated from version 1.94.0. Use 'domain_name' instead.
     * 
     */
    @Deprecated /* Field 'domain' has been deprecated from version 1.94.0. Use 'domain_name' instead. */
    @Import(name="domain")
    private @Nullable Output domain;

    /**
     * @return Field `domain` has been deprecated from version 1.94.0. Use `domain_name` instead.
     * 
     * @deprecated
     * Field 'domain' has been deprecated from version 1.94.0. Use 'domain_name' instead.
     * 
     */
    @Deprecated /* Field 'domain' has been deprecated from version 1.94.0. Use 'domain_name' instead. */
    public Optional> domain() {
        return Optional.ofNullable(this.domain);
    }

    /**
     * The domain that you want to add to WAF. The `domain_name` is required when the value of the `domain`  is Empty.
     * 
     */
    @Import(name="domainName")
    private @Nullable Output domainName;

    /**
     * @return The domain that you want to add to WAF. The `domain_name` is required when the value of the `domain`  is Empty.
     * 
     */
    public Optional> domainName() {
        return Optional.ofNullable(this.domainName);
    }

    /**
     * List of the HTTP 2.0 ports.
     * 
     */
    @Import(name="http2Ports")
    private @Nullable Output> http2Ports;

    /**
     * @return List of the HTTP 2.0 ports.
     * 
     */
    public Optional>> http2Ports() {
        return Optional.ofNullable(this.http2Ports);
    }

    /**
     * List of the HTTP ports.
     * 
     */
    @Import(name="httpPorts")
    private @Nullable Output> httpPorts;

    /**
     * @return List of the HTTP ports.
     * 
     */
    public Optional>> httpPorts() {
        return Optional.ofNullable(this.httpPorts);
    }

    /**
     * Specifies whether to enable the HTTP back-to-origin feature. After this feature is enabled, the WAF instance can use HTTP to forward HTTPS requests to the origin server.
     * By default, port 80 is used to forward the requests to the origin server. Valid values: `On` and `Off`. Default to `Off`.
     * 
     */
    @Import(name="httpToUserIp")
    private @Nullable Output httpToUserIp;

    /**
     * @return Specifies whether to enable the HTTP back-to-origin feature. After this feature is enabled, the WAF instance can use HTTP to forward HTTPS requests to the origin server.
     * By default, port 80 is used to forward the requests to the origin server. Valid values: `On` and `Off`. Default to `Off`.
     * 
     */
    public Optional> httpToUserIp() {
        return Optional.ofNullable(this.httpToUserIp);
    }

    /**
     * List of the HTTPS ports.
     * 
     */
    @Import(name="httpsPorts")
    private @Nullable Output> httpsPorts;

    /**
     * @return List of the HTTPS ports.
     * 
     */
    public Optional>> httpsPorts() {
        return Optional.ofNullable(this.httpsPorts);
    }

    /**
     * Specifies whether to redirect HTTP requests as HTTPS requests. Valid values: "On" and `Off`. Default to `Off`.
     * 
     */
    @Import(name="httpsRedirect")
    private @Nullable Output httpsRedirect;

    /**
     * @return Specifies whether to redirect HTTP requests as HTTPS requests. Valid values: "On" and `Off`. Default to `Off`.
     * 
     */
    public Optional> httpsRedirect() {
        return Optional.ofNullable(this.httpsRedirect);
    }

    /**
     * The ID of the WAF instance.
     * 
     */
    @Import(name="instanceId")
    private @Nullable Output instanceId;

    /**
     * @return The ID of the WAF instance.
     * 
     */
    public Optional> instanceId() {
        return Optional.ofNullable(this.instanceId);
    }

    /**
     * Specifies whether to configure a Layer-7 proxy, such as Anti-DDoS Pro or CDN, to filter the inbound traffic before it is forwarded to WAF. Valid values: `On` and `Off`. Default to `Off`.
     * 
     */
    @Import(name="isAccessProduct")
    private @Nullable Output isAccessProduct;

    /**
     * @return Specifies whether to configure a Layer-7 proxy, such as Anti-DDoS Pro or CDN, to filter the inbound traffic before it is forwarded to WAF. Valid values: `On` and `Off`. Default to `Off`.
     * 
     */
    public Optional> isAccessProduct() {
        return Optional.ofNullable(this.isAccessProduct);
    }

    /**
     * The load balancing algorithm that is used to forward requests to the origin. Valid values: `IpHash` and `RoundRobin`. Default to `IpHash`.
     * 
     */
    @Import(name="loadBalancing")
    private @Nullable Output loadBalancing;

    /**
     * @return The load balancing algorithm that is used to forward requests to the origin. Valid values: `IpHash` and `RoundRobin`. Default to `IpHash`.
     * 
     */
    public Optional> loadBalancing() {
        return Optional.ofNullable(this.loadBalancing);
    }

    /**
     * The key-value pair that is used to mark the traffic that flows through WAF to the domain. Each item contains two field:
     * * key: The key of label
     * * value: The value of label
     * 
     */
    @Import(name="logHeaders")
    private @Nullable Output> logHeaders;

    /**
     * @return The key-value pair that is used to mark the traffic that flows through WAF to the domain. Each item contains two field:
     * * key: The key of label
     * * value: The value of label
     * 
     */
    public Optional>> logHeaders() {
        return Optional.ofNullable(this.logHeaders);
    }

    /**
     * The read timeout of a WAF exclusive cluster. Unit: seconds.
     * 
     */
    @Import(name="readTime")
    private @Nullable Output readTime;

    /**
     * @return The read timeout of a WAF exclusive cluster. Unit: seconds.
     * 
     */
    public Optional> readTime() {
        return Optional.ofNullable(this.readTime);
    }

    /**
     * The ID of the resource group to which the queried domain belongs in Resource Management. By default, no value is specified, indicating that the domain belongs to the default resource group.
     * 
     */
    @Import(name="resourceGroupId")
    private @Nullable Output resourceGroupId;

    /**
     * @return The ID of the resource group to which the queried domain belongs in Resource Management. By default, no value is specified, indicating that the domain belongs to the default resource group.
     * 
     */
    public Optional> resourceGroupId() {
        return Optional.ofNullable(this.resourceGroupId);
    }

    /**
     * List of the IP address or domain of the origin server to which the specified domain points.
     * 
     */
    @Import(name="sourceIps")
    private @Nullable Output> sourceIps;

    /**
     * @return List of the IP address or domain of the origin server to which the specified domain points.
     * 
     */
    public Optional>> sourceIps() {
        return Optional.ofNullable(this.sourceIps);
    }

    /**
     * The timeout period for a WAF exclusive cluster write connection. Unit: seconds.
     * 
     */
    @Import(name="writeTime")
    private @Nullable Output writeTime;

    /**
     * @return The timeout period for a WAF exclusive cluster write connection. Unit: seconds.
     * 
     */
    public Optional> writeTime() {
        return Optional.ofNullable(this.writeTime);
    }

    private DomainState() {}

    private DomainState(DomainState $) {
        this.clusterType = $.clusterType;
        this.cname = $.cname;
        this.connectionTime = $.connectionTime;
        this.domain = $.domain;
        this.domainName = $.domainName;
        this.http2Ports = $.http2Ports;
        this.httpPorts = $.httpPorts;
        this.httpToUserIp = $.httpToUserIp;
        this.httpsPorts = $.httpsPorts;
        this.httpsRedirect = $.httpsRedirect;
        this.instanceId = $.instanceId;
        this.isAccessProduct = $.isAccessProduct;
        this.loadBalancing = $.loadBalancing;
        this.logHeaders = $.logHeaders;
        this.readTime = $.readTime;
        this.resourceGroupId = $.resourceGroupId;
        this.sourceIps = $.sourceIps;
        this.writeTime = $.writeTime;
    }

    public static Builder builder() {
        return new Builder();
    }
    public static Builder builder(DomainState defaults) {
        return new Builder(defaults);
    }

    public static final class Builder {
        private DomainState $;

        public Builder() {
            $ = new DomainState();
        }

        public Builder(DomainState defaults) {
            $ = new DomainState(Objects.requireNonNull(defaults));
        }

        /**
         * @param clusterType The type of the WAF cluster. Valid values: `PhysicalCluster` and `VirtualCluster`. Default to `PhysicalCluster`.
         * 
         * @return builder
         * 
         */
        public Builder clusterType(@Nullable Output clusterType) {
            $.clusterType = clusterType;
            return this;
        }

        /**
         * @param clusterType The type of the WAF cluster. Valid values: `PhysicalCluster` and `VirtualCluster`. Default to `PhysicalCluster`.
         * 
         * @return builder
         * 
         */
        public Builder clusterType(String clusterType) {
            return clusterType(Output.of(clusterType));
        }

        /**
         * @param cname The CNAME record assigned by the WAF instance to the specified domain.
         * 
         * @return builder
         * 
         */
        public Builder cname(@Nullable Output cname) {
            $.cname = cname;
            return this;
        }

        /**
         * @param cname The CNAME record assigned by the WAF instance to the specified domain.
         * 
         * @return builder
         * 
         */
        public Builder cname(String cname) {
            return cname(Output.of(cname));
        }

        /**
         * @param connectionTime The connection timeout for WAF exclusive clusters. Unit: seconds.
         * 
         * @return builder
         * 
         */
        public Builder connectionTime(@Nullable Output connectionTime) {
            $.connectionTime = connectionTime;
            return this;
        }

        /**
         * @param connectionTime The connection timeout for WAF exclusive clusters. Unit: seconds.
         * 
         * @return builder
         * 
         */
        public Builder connectionTime(Integer connectionTime) {
            return connectionTime(Output.of(connectionTime));
        }

        /**
         * @param domain Field `domain` has been deprecated from version 1.94.0. Use `domain_name` instead.
         * 
         * @return builder
         * 
         * @deprecated
         * Field 'domain' has been deprecated from version 1.94.0. Use 'domain_name' instead.
         * 
         */
        @Deprecated /* Field 'domain' has been deprecated from version 1.94.0. Use 'domain_name' instead. */
        public Builder domain(@Nullable Output domain) {
            $.domain = domain;
            return this;
        }

        /**
         * @param domain Field `domain` has been deprecated from version 1.94.0. Use `domain_name` instead.
         * 
         * @return builder
         * 
         * @deprecated
         * Field 'domain' has been deprecated from version 1.94.0. Use 'domain_name' instead.
         * 
         */
        @Deprecated /* Field 'domain' has been deprecated from version 1.94.0. Use 'domain_name' instead. */
        public Builder domain(String domain) {
            return domain(Output.of(domain));
        }

        /**
         * @param domainName The domain that you want to add to WAF. The `domain_name` is required when the value of the `domain`  is Empty.
         * 
         * @return builder
         * 
         */
        public Builder domainName(@Nullable Output domainName) {
            $.domainName = domainName;
            return this;
        }

        /**
         * @param domainName The domain that you want to add to WAF. The `domain_name` is required when the value of the `domain`  is Empty.
         * 
         * @return builder
         * 
         */
        public Builder domainName(String domainName) {
            return domainName(Output.of(domainName));
        }

        /**
         * @param http2Ports List of the HTTP 2.0 ports.
         * 
         * @return builder
         * 
         */
        public Builder http2Ports(@Nullable Output> http2Ports) {
            $.http2Ports = http2Ports;
            return this;
        }

        /**
         * @param http2Ports List of the HTTP 2.0 ports.
         * 
         * @return builder
         * 
         */
        public Builder http2Ports(List http2Ports) {
            return http2Ports(Output.of(http2Ports));
        }

        /**
         * @param http2Ports List of the HTTP 2.0 ports.
         * 
         * @return builder
         * 
         */
        public Builder http2Ports(String... http2Ports) {
            return http2Ports(List.of(http2Ports));
        }

        /**
         * @param httpPorts List of the HTTP ports.
         * 
         * @return builder
         * 
         */
        public Builder httpPorts(@Nullable Output> httpPorts) {
            $.httpPorts = httpPorts;
            return this;
        }

        /**
         * @param httpPorts List of the HTTP ports.
         * 
         * @return builder
         * 
         */
        public Builder httpPorts(List httpPorts) {
            return httpPorts(Output.of(httpPorts));
        }

        /**
         * @param httpPorts List of the HTTP ports.
         * 
         * @return builder
         * 
         */
        public Builder httpPorts(String... httpPorts) {
            return httpPorts(List.of(httpPorts));
        }

        /**
         * @param httpToUserIp Specifies whether to enable the HTTP back-to-origin feature. After this feature is enabled, the WAF instance can use HTTP to forward HTTPS requests to the origin server.
         * By default, port 80 is used to forward the requests to the origin server. Valid values: `On` and `Off`. Default to `Off`.
         * 
         * @return builder
         * 
         */
        public Builder httpToUserIp(@Nullable Output httpToUserIp) {
            $.httpToUserIp = httpToUserIp;
            return this;
        }

        /**
         * @param httpToUserIp Specifies whether to enable the HTTP back-to-origin feature. After this feature is enabled, the WAF instance can use HTTP to forward HTTPS requests to the origin server.
         * By default, port 80 is used to forward the requests to the origin server. Valid values: `On` and `Off`. Default to `Off`.
         * 
         * @return builder
         * 
         */
        public Builder httpToUserIp(String httpToUserIp) {
            return httpToUserIp(Output.of(httpToUserIp));
        }

        /**
         * @param httpsPorts List of the HTTPS ports.
         * 
         * @return builder
         * 
         */
        public Builder httpsPorts(@Nullable Output> httpsPorts) {
            $.httpsPorts = httpsPorts;
            return this;
        }

        /**
         * @param httpsPorts List of the HTTPS ports.
         * 
         * @return builder
         * 
         */
        public Builder httpsPorts(List httpsPorts) {
            return httpsPorts(Output.of(httpsPorts));
        }

        /**
         * @param httpsPorts List of the HTTPS ports.
         * 
         * @return builder
         * 
         */
        public Builder httpsPorts(String... httpsPorts) {
            return httpsPorts(List.of(httpsPorts));
        }

        /**
         * @param httpsRedirect Specifies whether to redirect HTTP requests as HTTPS requests. Valid values: "On" and `Off`. Default to `Off`.
         * 
         * @return builder
         * 
         */
        public Builder httpsRedirect(@Nullable Output httpsRedirect) {
            $.httpsRedirect = httpsRedirect;
            return this;
        }

        /**
         * @param httpsRedirect Specifies whether to redirect HTTP requests as HTTPS requests. Valid values: "On" and `Off`. Default to `Off`.
         * 
         * @return builder
         * 
         */
        public Builder httpsRedirect(String httpsRedirect) {
            return httpsRedirect(Output.of(httpsRedirect));
        }

        /**
         * @param instanceId The ID of the WAF instance.
         * 
         * @return builder
         * 
         */
        public Builder instanceId(@Nullable Output instanceId) {
            $.instanceId = instanceId;
            return this;
        }

        /**
         * @param instanceId The ID of the WAF instance.
         * 
         * @return builder
         * 
         */
        public Builder instanceId(String instanceId) {
            return instanceId(Output.of(instanceId));
        }

        /**
         * @param isAccessProduct Specifies whether to configure a Layer-7 proxy, such as Anti-DDoS Pro or CDN, to filter the inbound traffic before it is forwarded to WAF. Valid values: `On` and `Off`. Default to `Off`.
         * 
         * @return builder
         * 
         */
        public Builder isAccessProduct(@Nullable Output isAccessProduct) {
            $.isAccessProduct = isAccessProduct;
            return this;
        }

        /**
         * @param isAccessProduct Specifies whether to configure a Layer-7 proxy, such as Anti-DDoS Pro or CDN, to filter the inbound traffic before it is forwarded to WAF. Valid values: `On` and `Off`. Default to `Off`.
         * 
         * @return builder
         * 
         */
        public Builder isAccessProduct(String isAccessProduct) {
            return isAccessProduct(Output.of(isAccessProduct));
        }

        /**
         * @param loadBalancing The load balancing algorithm that is used to forward requests to the origin. Valid values: `IpHash` and `RoundRobin`. Default to `IpHash`.
         * 
         * @return builder
         * 
         */
        public Builder loadBalancing(@Nullable Output loadBalancing) {
            $.loadBalancing = loadBalancing;
            return this;
        }

        /**
         * @param loadBalancing The load balancing algorithm that is used to forward requests to the origin. Valid values: `IpHash` and `RoundRobin`. Default to `IpHash`.
         * 
         * @return builder
         * 
         */
        public Builder loadBalancing(String loadBalancing) {
            return loadBalancing(Output.of(loadBalancing));
        }

        /**
         * @param logHeaders The key-value pair that is used to mark the traffic that flows through WAF to the domain. Each item contains two field:
         * * key: The key of label
         * * value: The value of label
         * 
         * @return builder
         * 
         */
        public Builder logHeaders(@Nullable Output> logHeaders) {
            $.logHeaders = logHeaders;
            return this;
        }

        /**
         * @param logHeaders The key-value pair that is used to mark the traffic that flows through WAF to the domain. Each item contains two field:
         * * key: The key of label
         * * value: The value of label
         * 
         * @return builder
         * 
         */
        public Builder logHeaders(List logHeaders) {
            return logHeaders(Output.of(logHeaders));
        }

        /**
         * @param logHeaders The key-value pair that is used to mark the traffic that flows through WAF to the domain. Each item contains two field:
         * * key: The key of label
         * * value: The value of label
         * 
         * @return builder
         * 
         */
        public Builder logHeaders(DomainLogHeaderArgs... logHeaders) {
            return logHeaders(List.of(logHeaders));
        }

        /**
         * @param readTime The read timeout of a WAF exclusive cluster. Unit: seconds.
         * 
         * @return builder
         * 
         */
        public Builder readTime(@Nullable Output readTime) {
            $.readTime = readTime;
            return this;
        }

        /**
         * @param readTime The read timeout of a WAF exclusive cluster. Unit: seconds.
         * 
         * @return builder
         * 
         */
        public Builder readTime(Integer readTime) {
            return readTime(Output.of(readTime));
        }

        /**
         * @param resourceGroupId The ID of the resource group to which the queried domain belongs in Resource Management. By default, no value is specified, indicating that the domain belongs to the default resource group.
         * 
         * @return builder
         * 
         */
        public Builder resourceGroupId(@Nullable Output resourceGroupId) {
            $.resourceGroupId = resourceGroupId;
            return this;
        }

        /**
         * @param resourceGroupId The ID of the resource group to which the queried domain belongs in Resource Management. By default, no value is specified, indicating that the domain belongs to the default resource group.
         * 
         * @return builder
         * 
         */
        public Builder resourceGroupId(String resourceGroupId) {
            return resourceGroupId(Output.of(resourceGroupId));
        }

        /**
         * @param sourceIps List of the IP address or domain of the origin server to which the specified domain points.
         * 
         * @return builder
         * 
         */
        public Builder sourceIps(@Nullable Output> sourceIps) {
            $.sourceIps = sourceIps;
            return this;
        }

        /**
         * @param sourceIps List of the IP address or domain of the origin server to which the specified domain points.
         * 
         * @return builder
         * 
         */
        public Builder sourceIps(List sourceIps) {
            return sourceIps(Output.of(sourceIps));
        }

        /**
         * @param sourceIps List of the IP address or domain of the origin server to which the specified domain points.
         * 
         * @return builder
         * 
         */
        public Builder sourceIps(String... sourceIps) {
            return sourceIps(List.of(sourceIps));
        }

        /**
         * @param writeTime The timeout period for a WAF exclusive cluster write connection. Unit: seconds.
         * 
         * @return builder
         * 
         */
        public Builder writeTime(@Nullable Output writeTime) {
            $.writeTime = writeTime;
            return this;
        }

        /**
         * @param writeTime The timeout period for a WAF exclusive cluster write connection. Unit: seconds.
         * 
         * @return builder
         * 
         */
        public Builder writeTime(Integer writeTime) {
            return writeTime(Output.of(writeTime));
        }

        public DomainState build() {
            return $;
        }
    }

}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy