// *** 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.gcp.container;

import com.pulumi.core.Output;
import com.pulumi.core.annotations.Import;
import com.pulumi.gcp.container.inputs.AttachedClusterAuthorizationArgs;
import com.pulumi.gcp.container.inputs.AttachedClusterFleetArgs;
import com.pulumi.gcp.container.inputs.AttachedClusterLoggingConfigArgs;
import com.pulumi.gcp.container.inputs.AttachedClusterMonitoringConfigArgs;
import com.pulumi.gcp.container.inputs.AttachedClusterOidcConfigArgs;
import java.lang.String;
import java.util.Map;
import java.util.Objects;
import java.util.Optional;
import javax.annotation.Nullable;


public final class AttachedClusterArgs extends com.pulumi.resources.ResourceArgs {

    public static final AttachedClusterArgs Empty = new AttachedClusterArgs();

    /**
     * Optional. Annotations on the cluster. This field has the same
     * restrictions as Kubernetes annotations. The total size of all keys and
     * values combined is limited to 256k. Key can have 2 segments: prefix (optional)
     * and name (required), separated by a slash (/). Prefix must be a DNS subdomain.
     * Name must be 63 characters or less, begin and end with alphanumerics,
     * with dashes (-), underscores (_), dots (.), and alphanumerics between.
     * 
     */
    @Import(name="annotations")
    private @Nullable Output<Map<String,String>> annotations;

    /**
     * @return Optional. Annotations on the cluster. This field has the same
     * restrictions as Kubernetes annotations. The total size of all keys and
     * values combined is limited to 256k. Key can have 2 segments: prefix (optional)
     * and name (required), separated by a slash (/). Prefix must be a DNS subdomain.
     * Name must be 63 characters or less, begin and end with alphanumerics,
     * with dashes (-), underscores (_), dots (.), and alphanumerics between.
     * 
     */
    public Optional<Output<Map<String,String>>> annotations() {
        return Optional.ofNullable(this.annotations);
    }

    /**
     * Configuration related to the cluster RBAC settings.
     * Structure is documented below.
     * 
     */
    @Import(name="authorization")
    private @Nullable Output<AttachedClusterAuthorizationArgs> authorization;

    /**
     * @return Configuration related to the cluster RBAC settings.
     * Structure is documented below.
     * 
     */
    public Optional<Output<AttachedClusterAuthorizationArgs>> authorization() {
        return Optional.ofNullable(this.authorization);
    }

    /**
     * Policy to determine what flags to send on delete.
     * 
     */
    @Import(name="deletionPolicy")
    private @Nullable Output<String> deletionPolicy;

    /**
     * @return Policy to determine what flags to send on delete.
     * 
     */
    public Optional<Output<String>> deletionPolicy() {
        return Optional.ofNullable(this.deletionPolicy);
    }

    /**
     * A human readable description of this attached cluster. Cannot be longer
     * than 255 UTF-8 encoded bytes.
     * 
     */
    @Import(name="description")
    private @Nullable Output<String> description;

    /**
     * @return A human readable description of this attached cluster. Cannot be longer
     * than 255 UTF-8 encoded bytes.
     * 
     */
    public Optional<Output<String>> description() {
        return Optional.ofNullable(this.description);
    }

    /**
     * The Kubernetes distribution of the underlying attached cluster. Supported values:
     * &#34;eks&#34;, &#34;aks&#34;.
     * 
     */
    @Import(name="distribution", required=true)
    private Output<String> distribution;

    /**
     * @return The Kubernetes distribution of the underlying attached cluster. Supported values:
     * &#34;eks&#34;, &#34;aks&#34;.
     * 
     */
    public Output<String> distribution() {
        return this.distribution;
    }

    /**
     * Fleet configuration.
     * Structure is documented below.
     * 
     */
    @Import(name="fleet", required=true)
    private Output<AttachedClusterFleetArgs> fleet;

    /**
     * @return Fleet configuration.
     * Structure is documented below.
     * 
     */
    public Output<AttachedClusterFleetArgs> fleet() {
        return this.fleet;
    }

    /**
     * The location for the resource
     * 
     */
    @Import(name="location", required=true)
    private Output<String> location;

    /**
     * @return The location for the resource
     * 
     */
    public Output<String> location() {
        return this.location;
    }

    /**
     * Logging configuration.
     * Structure is documented below.
     * 
     */
    @Import(name="loggingConfig")
    private @Nullable Output<AttachedClusterLoggingConfigArgs> loggingConfig;

    /**
     * @return Logging configuration.
     * Structure is documented below.
     * 
     */
    public Optional<Output<AttachedClusterLoggingConfigArgs>> loggingConfig() {
        return Optional.ofNullable(this.loggingConfig);
    }

    /**
     * Monitoring configuration.
     * Structure is documented below.
     * 
     */
    @Import(name="monitoringConfig")
    private @Nullable Output<AttachedClusterMonitoringConfigArgs> monitoringConfig;

    /**
     * @return Monitoring configuration.
     * Structure is documented below.
     * 
     */
    public Optional<Output<AttachedClusterMonitoringConfigArgs>> monitoringConfig() {
        return Optional.ofNullable(this.monitoringConfig);
    }

    /**
     * The name of this resource.
     * 
     */
    @Import(name="name")
    private @Nullable Output<String> name;

    /**
     * @return The name of this resource.
     * 
     */
    public Optional<Output<String>> name() {
        return Optional.ofNullable(this.name);
    }

    /**
     * OIDC discovery information of the target cluster.
     * Kubernetes Service Account (KSA) tokens are JWT tokens signed by the cluster
     * API server. This fields indicates how GCP services
     * validate KSA tokens in order to allow system workloads (such as GKE Connect
     * and telemetry agents) to authenticate back to GCP.
     * Both clusters with public and private issuer URLs are supported.
     * Clusters with public issuers only need to specify the `issuer_url` field
     * while clusters with private issuers need to provide both
     * `issuer_url` and `jwks`.
     * Structure is documented below.
     * 
     */
    @Import(name="oidcConfig", required=true)
    private Output<AttachedClusterOidcConfigArgs> oidcConfig;

    /**
     * @return OIDC discovery information of the target cluster.
     * Kubernetes Service Account (KSA) tokens are JWT tokens signed by the cluster
     * API server. This fields indicates how GCP services
     * validate KSA tokens in order to allow system workloads (such as GKE Connect
     * and telemetry agents) to authenticate back to GCP.
     * Both clusters with public and private issuer URLs are supported.
     * Clusters with public issuers only need to specify the `issuer_url` field
     * while clusters with private issuers need to provide both
     * `issuer_url` and `jwks`.
     * Structure is documented below.
     * 
     */
    public Output<AttachedClusterOidcConfigArgs> oidcConfig() {
        return this.oidcConfig;
    }

    /**
     * The platform version for the cluster (e.g. `1.23.0-gke.1`).
     * 
     */
    @Import(name="platformVersion", required=true)
    private Output<String> platformVersion;

    /**
     * @return The platform version for the cluster (e.g. `1.23.0-gke.1`).
     * 
     */
    public Output<String> platformVersion() {
        return this.platformVersion;
    }

    /**
     * The number of the Fleet host project where this cluster will be registered.
     * 
     * ***
     * 
     * If it is not provided, the provider project is used.
     * 
     */
    @Import(name="project")
    private @Nullable Output<String> project;

    /**
     * @return The number of the Fleet host project where this cluster will be registered.
     * 
     * ***
     * 
     * If it is not provided, the provider project is used.
     * 
     */
    public Optional<Output<String>> project() {
        return Optional.ofNullable(this.project);
    }

    private AttachedClusterArgs() {}

    private AttachedClusterArgs(AttachedClusterArgs $) {
        this.annotations = $.annotations;
        this.authorization = $.authorization;
        this.deletionPolicy = $.deletionPolicy;
        this.description = $.description;
        this.distribution = $.distribution;
        this.fleet = $.fleet;
        this.location = $.location;
        this.loggingConfig = $.loggingConfig;
        this.monitoringConfig = $.monitoringConfig;
        this.name = $.name;
        this.oidcConfig = $.oidcConfig;
        this.platformVersion = $.platformVersion;
        this.project = $.project;
    }

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

    public static final class Builder {
        private AttachedClusterArgs $;

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

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

        /**
         * @param annotations Optional. Annotations on the cluster. This field has the same
         * restrictions as Kubernetes annotations. The total size of all keys and
         * values combined is limited to 256k. Key can have 2 segments: prefix (optional)
         * and name (required), separated by a slash (/). Prefix must be a DNS subdomain.
         * Name must be 63 characters or less, begin and end with alphanumerics,
         * with dashes (-), underscores (_), dots (.), and alphanumerics between.
         * 
         * @return builder
         * 
         */
        public Builder annotations(@Nullable Output<Map<String,String>> annotations) {
            $.annotations = annotations;
            return this;
        }

        /**
         * @param annotations Optional. Annotations on the cluster. This field has the same
         * restrictions as Kubernetes annotations. The total size of all keys and
         * values combined is limited to 256k. Key can have 2 segments: prefix (optional)
         * and name (required), separated by a slash (/). Prefix must be a DNS subdomain.
         * Name must be 63 characters or less, begin and end with alphanumerics,
         * with dashes (-), underscores (_), dots (.), and alphanumerics between.
         * 
         * @return builder
         * 
         */
        public Builder annotations(Map<String,String> annotations) {
            return annotations(Output.of(annotations));
        }

        /**
         * @param authorization Configuration related to the cluster RBAC settings.
         * Structure is documented below.
         * 
         * @return builder
         * 
         */
        public Builder authorization(@Nullable Output<AttachedClusterAuthorizationArgs> authorization) {
            $.authorization = authorization;
            return this;
        }

        /**
         * @param authorization Configuration related to the cluster RBAC settings.
         * Structure is documented below.
         * 
         * @return builder
         * 
         */
        public Builder authorization(AttachedClusterAuthorizationArgs authorization) {
            return authorization(Output.of(authorization));
        }

        /**
         * @param deletionPolicy Policy to determine what flags to send on delete.
         * 
         * @return builder
         * 
         */
        public Builder deletionPolicy(@Nullable Output<String> deletionPolicy) {
            $.deletionPolicy = deletionPolicy;
            return this;
        }

        /**
         * @param deletionPolicy Policy to determine what flags to send on delete.
         * 
         * @return builder
         * 
         */
        public Builder deletionPolicy(String deletionPolicy) {
            return deletionPolicy(Output.of(deletionPolicy));
        }

        /**
         * @param description A human readable description of this attached cluster. Cannot be longer
         * than 255 UTF-8 encoded bytes.
         * 
         * @return builder
         * 
         */
        public Builder description(@Nullable Output<String> description) {
            $.description = description;
            return this;
        }

        /**
         * @param description A human readable description of this attached cluster. Cannot be longer
         * than 255 UTF-8 encoded bytes.
         * 
         * @return builder
         * 
         */
        public Builder description(String description) {
            return description(Output.of(description));
        }

        /**
         * @param distribution The Kubernetes distribution of the underlying attached cluster. Supported values:
         * &#34;eks&#34;, &#34;aks&#34;.
         * 
         * @return builder
         * 
         */
        public Builder distribution(Output<String> distribution) {
            $.distribution = distribution;
            return this;
        }

        /**
         * @param distribution The Kubernetes distribution of the underlying attached cluster. Supported values:
         * &#34;eks&#34;, &#34;aks&#34;.
         * 
         * @return builder
         * 
         */
        public Builder distribution(String distribution) {
            return distribution(Output.of(distribution));
        }

        /**
         * @param fleet Fleet configuration.
         * Structure is documented below.
         * 
         * @return builder
         * 
         */
        public Builder fleet(Output<AttachedClusterFleetArgs> fleet) {
            $.fleet = fleet;
            return this;
        }

        /**
         * @param fleet Fleet configuration.
         * Structure is documented below.
         * 
         * @return builder
         * 
         */
        public Builder fleet(AttachedClusterFleetArgs fleet) {
            return fleet(Output.of(fleet));
        }

        /**
         * @param location The location for the resource
         * 
         * @return builder
         * 
         */
        public Builder location(Output<String> location) {
            $.location = location;
            return this;
        }

        /**
         * @param location The location for the resource
         * 
         * @return builder
         * 
         */
        public Builder location(String location) {
            return location(Output.of(location));
        }

        /**
         * @param loggingConfig Logging configuration.
         * Structure is documented below.
         * 
         * @return builder
         * 
         */
        public Builder loggingConfig(@Nullable Output<AttachedClusterLoggingConfigArgs> loggingConfig) {
            $.loggingConfig = loggingConfig;
            return this;
        }

        /**
         * @param loggingConfig Logging configuration.
         * Structure is documented below.
         * 
         * @return builder
         * 
         */
        public Builder loggingConfig(AttachedClusterLoggingConfigArgs loggingConfig) {
            return loggingConfig(Output.of(loggingConfig));
        }

        /**
         * @param monitoringConfig Monitoring configuration.
         * Structure is documented below.
         * 
         * @return builder
         * 
         */
        public Builder monitoringConfig(@Nullable Output<AttachedClusterMonitoringConfigArgs> monitoringConfig) {
            $.monitoringConfig = monitoringConfig;
            return this;
        }

        /**
         * @param monitoringConfig Monitoring configuration.
         * Structure is documented below.
         * 
         * @return builder
         * 
         */
        public Builder monitoringConfig(AttachedClusterMonitoringConfigArgs monitoringConfig) {
            return monitoringConfig(Output.of(monitoringConfig));
        }

        /**
         * @param name The name of this resource.
         * 
         * @return builder
         * 
         */
        public Builder name(@Nullable Output<String> name) {
            $.name = name;
            return this;
        }

        /**
         * @param name The name of this resource.
         * 
         * @return builder
         * 
         */
        public Builder name(String name) {
            return name(Output.of(name));
        }

        /**
         * @param oidcConfig OIDC discovery information of the target cluster.
         * Kubernetes Service Account (KSA) tokens are JWT tokens signed by the cluster
         * API server. This fields indicates how GCP services
         * validate KSA tokens in order to allow system workloads (such as GKE Connect
         * and telemetry agents) to authenticate back to GCP.
         * Both clusters with public and private issuer URLs are supported.
         * Clusters with public issuers only need to specify the `issuer_url` field
         * while clusters with private issuers need to provide both
         * `issuer_url` and `jwks`.
         * Structure is documented below.
         * 
         * @return builder
         * 
         */
        public Builder oidcConfig(Output<AttachedClusterOidcConfigArgs> oidcConfig) {
            $.oidcConfig = oidcConfig;
            return this;
        }

        /**
         * @param oidcConfig OIDC discovery information of the target cluster.
         * Kubernetes Service Account (KSA) tokens are JWT tokens signed by the cluster
         * API server. This fields indicates how GCP services
         * validate KSA tokens in order to allow system workloads (such as GKE Connect
         * and telemetry agents) to authenticate back to GCP.
         * Both clusters with public and private issuer URLs are supported.
         * Clusters with public issuers only need to specify the `issuer_url` field
         * while clusters with private issuers need to provide both
         * `issuer_url` and `jwks`.
         * Structure is documented below.
         * 
         * @return builder
         * 
         */
        public Builder oidcConfig(AttachedClusterOidcConfigArgs oidcConfig) {
            return oidcConfig(Output.of(oidcConfig));
        }

        /**
         * @param platformVersion The platform version for the cluster (e.g. `1.23.0-gke.1`).
         * 
         * @return builder
         * 
         */
        public Builder platformVersion(Output<String> platformVersion) {
            $.platformVersion = platformVersion;
            return this;
        }

        /**
         * @param platformVersion The platform version for the cluster (e.g. `1.23.0-gke.1`).
         * 
         * @return builder
         * 
         */
        public Builder platformVersion(String platformVersion) {
            return platformVersion(Output.of(platformVersion));
        }

        /**
         * @param project The number of the Fleet host project where this cluster will be registered.
         * 
         * ***
         * 
         * If it is not provided, the provider project is used.
         * 
         * @return builder
         * 
         */
        public Builder project(@Nullable Output<String> project) {
            $.project = project;
            return this;
        }

        /**
         * @param project The number of the Fleet host project where this cluster will be registered.
         * 
         * ***
         * 
         * If it is not provided, the provider project is used.
         * 
         * @return builder
         * 
         */
        public Builder project(String project) {
            return project(Output.of(project));
        }

        public AttachedClusterArgs build() {
            $.distribution = Objects.requireNonNull($.distribution, "expected parameter 'distribution' to be non-null");
            $.fleet = Objects.requireNonNull($.fleet, "expected parameter 'fleet' to be non-null");
            $.location = Objects.requireNonNull($.location, "expected parameter 'location' to be non-null");
            $.oidcConfig = Objects.requireNonNull($.oidcConfig, "expected parameter 'oidcConfig' to be non-null");
            $.platformVersion = Objects.requireNonNull($.platformVersion, "expected parameter 'platformVersion' to be non-null");
            return $;
        }
    }

}
