# coding=utf-8
# *** WARNING: this file was generated by the Pulumi Terraform Bridge (tfgen) Tool. ***
# *** Do not edit by hand unless you're certain you know what you are doing! ***

import builtins
import copy
import warnings
import sys
import pulumi
import pulumi.runtime
from typing import Any, Mapping, Optional, Sequence, Union, overload
if sys.version_info >= (3, 11):
    from typing import NotRequired, TypedDict, TypeAlias
else:
    from typing_extensions import NotRequired, TypedDict, TypeAlias
from .. import _utilities
from . import outputs

__all__ = [
    'GetClusterResult',
    'AwaitableGetClusterResult',
    'get_cluster',
    'get_cluster_output',
]

@pulumi.output_type
class GetClusterResult:
    """
    A collection of values returned by getCluster.
    """
    def __init__(__self__, cluster_config=None, cluster_id=None, created_time=None, delete_protection_enabled=None, description=None, id=None, kubernetes_version=None, kubernetes_version_create=None, logging_config=None, message=None, monitoring_config=None, name=None, node_statistics=None, pods_config=None, project_name=None, services_config=None, source_region=None, status=None, tags=None, type=None, updated_time=None):
        if cluster_config and not isinstance(cluster_config, dict):
            raise TypeError("Expected argument 'cluster_config' to be a dict")
        pulumi.set(__self__, "cluster_config", cluster_config)
        if cluster_id and not isinstance(cluster_id, str):
            raise TypeError("Expected argument 'cluster_id' to be a str")
        pulumi.set(__self__, "cluster_id", cluster_id)
        if created_time and not isinstance(created_time, str):
            raise TypeError("Expected argument 'created_time' to be a str")
        pulumi.set(__self__, "created_time", created_time)
        if delete_protection_enabled and not isinstance(delete_protection_enabled, bool):
            raise TypeError("Expected argument 'delete_protection_enabled' to be a bool")
        pulumi.set(__self__, "delete_protection_enabled", delete_protection_enabled)
        if description and not isinstance(description, str):
            raise TypeError("Expected argument 'description' to be a str")
        pulumi.set(__self__, "description", description)
        if id and not isinstance(id, str):
            raise TypeError("Expected argument 'id' to be a str")
        pulumi.set(__self__, "id", id)
        if kubernetes_version and not isinstance(kubernetes_version, str):
            raise TypeError("Expected argument 'kubernetes_version' to be a str")
        pulumi.set(__self__, "kubernetes_version", kubernetes_version)
        if kubernetes_version_create and not isinstance(kubernetes_version_create, str):
            raise TypeError("Expected argument 'kubernetes_version_create' to be a str")
        pulumi.set(__self__, "kubernetes_version_create", kubernetes_version_create)
        if logging_config and not isinstance(logging_config, dict):
            raise TypeError("Expected argument 'logging_config' to be a dict")
        pulumi.set(__self__, "logging_config", logging_config)
        if message and not isinstance(message, str):
            raise TypeError("Expected argument 'message' to be a str")
        pulumi.set(__self__, "message", message)
        if monitoring_config and not isinstance(monitoring_config, dict):
            raise TypeError("Expected argument 'monitoring_config' to be a dict")
        pulumi.set(__self__, "monitoring_config", monitoring_config)
        if name and not isinstance(name, str):
            raise TypeError("Expected argument 'name' to be a str")
        pulumi.set(__self__, "name", name)
        if node_statistics and not isinstance(node_statistics, dict):
            raise TypeError("Expected argument 'node_statistics' to be a dict")
        pulumi.set(__self__, "node_statistics", node_statistics)
        if pods_config and not isinstance(pods_config, dict):
            raise TypeError("Expected argument 'pods_config' to be a dict")
        pulumi.set(__self__, "pods_config", pods_config)
        if project_name and not isinstance(project_name, str):
            raise TypeError("Expected argument 'project_name' to be a str")
        pulumi.set(__self__, "project_name", project_name)
        if services_config and not isinstance(services_config, dict):
            raise TypeError("Expected argument 'services_config' to be a dict")
        pulumi.set(__self__, "services_config", services_config)
        if source_region and not isinstance(source_region, str):
            raise TypeError("Expected argument 'source_region' to be a str")
        pulumi.set(__self__, "source_region", source_region)
        if status and not isinstance(status, dict):
            raise TypeError("Expected argument 'status' to be a dict")
        pulumi.set(__self__, "status", status)
        if tags and not isinstance(tags, list):
            raise TypeError("Expected argument 'tags' to be a list")
        pulumi.set(__self__, "tags", tags)
        if type and not isinstance(type, str):
            raise TypeError("Expected argument 'type' to be a str")
        pulumi.set(__self__, "type", type)
        if updated_time and not isinstance(updated_time, str):
            raise TypeError("Expected argument 'updated_time' to be a str")
        pulumi.set(__self__, "updated_time", updated_time)

    @property
    @pulumi.getter(name="clusterConfig")
    def cluster_config(self) -> 'outputs.GetClusterClusterConfigResult':
        """
        集群控制面及部分节点的网络配置。
        """
        return pulumi.get(self, "cluster_config")

    @property
    @pulumi.getter(name="clusterId")
    def cluster_id(self) -> builtins.str:
        """
        集群 ID。
        """
        return pulumi.get(self, "cluster_id")

    @property
    @pulumi.getter(name="createdTime")
    def created_time(self) -> builtins.str:
        """
        集群创建时间。标准 RFC3339 格式的 UTC+0 时间。
        """
        return pulumi.get(self, "created_time")

    @property
    @pulumi.getter(name="deleteProtectionEnabled")
    def delete_protection_enabled(self) -> builtins.bool:
        """
        集群删除保护，取值：false：（默认值）关闭删除保护。true：开启删除保护，不允许直接删除集群。
        """
        return pulumi.get(self, "delete_protection_enabled")

    @property
    @pulumi.getter
    def description(self) -> builtins.str:
        """
        集群描述。长度限制为 300 个字符以内。
        """
        return pulumi.get(self, "description")

    @property
    @pulumi.getter
    def id(self) -> builtins.str:
        """
        Uniquely identifies the resource.
        """
        return pulumi.get(self, "id")

    @property
    @pulumi.getter(name="kubernetesVersion")
    def kubernetes_version(self) -> builtins.str:
        """
        集群的 Kubernetes 版本，格式为x.xx。创建集群时，系统自动匹配该 Kubernetes 版本对应的最新 VKE 版本。（查询使用）
        """
        return pulumi.get(self, "kubernetes_version")

    @property
    @pulumi.getter(name="kubernetesVersionCreate")
    def kubernetes_version_create(self) -> builtins.str:
        """
        集群的 Kubernetes 版本，格式为x.xx。创建集群时，系统自动匹配该 Kubernetes 版本对应的最新 VKE 版本。(创建使用)
        """
        return pulumi.get(self, "kubernetes_version_create")

    @property
    @pulumi.getter(name="loggingConfig")
    def logging_config(self) -> 'outputs.GetClusterLoggingConfigResult':
        """
        集群的日志配置信息。
        """
        return pulumi.get(self, "logging_config")

    @property
    @pulumi.getter
    def message(self) -> builtins.str:
        """
        集群状态描述。
        """
        return pulumi.get(self, "message")

    @property
    @pulumi.getter(name="monitoringConfig")
    def monitoring_config(self) -> 'outputs.GetClusterMonitoringConfigResult':
        """
        监控配置信息。
        """
        return pulumi.get(self, "monitoring_config")

    @property
    @pulumi.getter
    def name(self) -> builtins.str:
        """
        集群名称。同一个地域下，名称必须唯一。支持大小写英文字母、汉字、数字、短划线（-），长度限制为 2～64 个字符。
        """
        return pulumi.get(self, "name")

    @property
    @pulumi.getter(name="nodeStatistics")
    def node_statistics(self) -> 'outputs.GetClusterNodeStatisticsResult':
        """
        集群中各主状态下对应的节点数量统计。
        """
        return pulumi.get(self, "node_statistics")

    @property
    @pulumi.getter(name="podsConfig")
    def pods_config(self) -> 'outputs.GetClusterPodsConfigResult':
        """
        Pod 的网络配置。
        """
        return pulumi.get(self, "pods_config")

    @property
    @pulumi.getter(name="projectName")
    def project_name(self) -> builtins.str:
        """
        集群所属项目名称，一个集群只能归属于一个项目。只能包含英文字母、数字、下划线（_）、英文句点（.）和中划线（-）。长度限制在 64 个字符以内。默认值：default。
        """
        return pulumi.get(self, "project_name")

    @property
    @pulumi.getter(name="servicesConfig")
    def services_config(self) -> 'outputs.GetClusterServicesConfigResult':
        """
        服务的网络配置。
        """
        return pulumi.get(self, "services_config")

    @property
    @pulumi.getter(name="sourceRegion")
    def source_region(self) -> builtins.str:
        """
        集群源地域。
        """
        return pulumi.get(self, "source_region")

    @property
    @pulumi.getter
    def status(self) -> 'outputs.GetClusterStatusResult':
        """
        集群状态。
        """
        return pulumi.get(self, "status")

    @property
    @pulumi.getter
    def tags(self) -> Sequence['outputs.GetClusterTagResult']:
        """
        集群的标签。
        """
        return pulumi.get(self, "tags")

    @property
    @pulumi.getter
    def type(self) -> builtins.str:
        """
        集群类型。
        """
        return pulumi.get(self, "type")

    @property
    @pulumi.getter(name="updatedTime")
    def updated_time(self) -> builtins.str:
        """
        集群最近一次更新的时间。标准 RFC3339 格式的 UTC+0 时间。
        """
        return pulumi.get(self, "updated_time")


class AwaitableGetClusterResult(GetClusterResult):
    # pylint: disable=using-constant-test
    def __await__(self):
        if False:
            yield self
        return GetClusterResult(
            cluster_config=self.cluster_config,
            cluster_id=self.cluster_id,
            created_time=self.created_time,
            delete_protection_enabled=self.delete_protection_enabled,
            description=self.description,
            id=self.id,
            kubernetes_version=self.kubernetes_version,
            kubernetes_version_create=self.kubernetes_version_create,
            logging_config=self.logging_config,
            message=self.message,
            monitoring_config=self.monitoring_config,
            name=self.name,
            node_statistics=self.node_statistics,
            pods_config=self.pods_config,
            project_name=self.project_name,
            services_config=self.services_config,
            source_region=self.source_region,
            status=self.status,
            tags=self.tags,
            type=self.type,
            updated_time=self.updated_time)


def get_cluster(id: Optional[builtins.str] = None,
                opts: Optional[pulumi.InvokeOptions] = None) -> AwaitableGetClusterResult:
    """
    Data Source schema for Byteplus::VKE::Cluster


    :param builtins.str id: Uniquely identifies the resource.
    """
    __args__ = dict()
    __args__['id'] = id
    opts = pulumi.InvokeOptions.merge(_utilities.get_invoke_opts_defaults(), opts)
    __ret__ = pulumi.runtime.invoke('bytepluscc:vke/getCluster:getCluster', __args__, opts=opts, typ=GetClusterResult).value

    return AwaitableGetClusterResult(
        cluster_config=pulumi.get(__ret__, 'cluster_config'),
        cluster_id=pulumi.get(__ret__, 'cluster_id'),
        created_time=pulumi.get(__ret__, 'created_time'),
        delete_protection_enabled=pulumi.get(__ret__, 'delete_protection_enabled'),
        description=pulumi.get(__ret__, 'description'),
        id=pulumi.get(__ret__, 'id'),
        kubernetes_version=pulumi.get(__ret__, 'kubernetes_version'),
        kubernetes_version_create=pulumi.get(__ret__, 'kubernetes_version_create'),
        logging_config=pulumi.get(__ret__, 'logging_config'),
        message=pulumi.get(__ret__, 'message'),
        monitoring_config=pulumi.get(__ret__, 'monitoring_config'),
        name=pulumi.get(__ret__, 'name'),
        node_statistics=pulumi.get(__ret__, 'node_statistics'),
        pods_config=pulumi.get(__ret__, 'pods_config'),
        project_name=pulumi.get(__ret__, 'project_name'),
        services_config=pulumi.get(__ret__, 'services_config'),
        source_region=pulumi.get(__ret__, 'source_region'),
        status=pulumi.get(__ret__, 'status'),
        tags=pulumi.get(__ret__, 'tags'),
        type=pulumi.get(__ret__, 'type'),
        updated_time=pulumi.get(__ret__, 'updated_time'))
def get_cluster_output(id: Optional[pulumi.Input[builtins.str]] = None,
                       opts: Optional[Union[pulumi.InvokeOptions, pulumi.InvokeOutputOptions]] = None) -> pulumi.Output[GetClusterResult]:
    """
    Data Source schema for Byteplus::VKE::Cluster


    :param builtins.str id: Uniquely identifies the resource.
    """
    __args__ = dict()
    __args__['id'] = id
    opts = pulumi.InvokeOutputOptions.merge(_utilities.get_invoke_opts_defaults(), opts)
    __ret__ = pulumi.runtime.invoke_output('bytepluscc:vke/getCluster:getCluster', __args__, opts=opts, typ=GetClusterResult)
    return __ret__.apply(lambda __response__: GetClusterResult(
        cluster_config=pulumi.get(__response__, 'cluster_config'),
        cluster_id=pulumi.get(__response__, 'cluster_id'),
        created_time=pulumi.get(__response__, 'created_time'),
        delete_protection_enabled=pulumi.get(__response__, 'delete_protection_enabled'),
        description=pulumi.get(__response__, 'description'),
        id=pulumi.get(__response__, 'id'),
        kubernetes_version=pulumi.get(__response__, 'kubernetes_version'),
        kubernetes_version_create=pulumi.get(__response__, 'kubernetes_version_create'),
        logging_config=pulumi.get(__response__, 'logging_config'),
        message=pulumi.get(__response__, 'message'),
        monitoring_config=pulumi.get(__response__, 'monitoring_config'),
        name=pulumi.get(__response__, 'name'),
        node_statistics=pulumi.get(__response__, 'node_statistics'),
        pods_config=pulumi.get(__response__, 'pods_config'),
        project_name=pulumi.get(__response__, 'project_name'),
        services_config=pulumi.get(__response__, 'services_config'),
        source_region=pulumi.get(__response__, 'source_region'),
        status=pulumi.get(__response__, 'status'),
        tags=pulumi.get(__response__, 'tags'),
        type=pulumi.get(__response__, 'type'),
        updated_time=pulumi.get(__response__, 'updated_time')))
