# 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__ = [
    'GetInstanceResult',
    'AwaitableGetInstanceResult',
    'get_instance',
    'get_instance_output',
]

@pulumi.output_type
class GetInstanceResult:
    """
    A collection of values returned by getInstance.
    """
    def __init__(__self__, address_objects=None, allow_list_ids=None, allow_list_version=None, auto_storage_scaling_config=None, auto_upgrade_minor_version=None, backup_audit_log_size=None, backup_bin_log_size=None, backup_data_size=None, backup_error_log_size=None, backup_free_quota_size=None, backup_log_size=None, backup_slow_log_size=None, backup_use=None, basic_backup_binlog_size=None, basic_backup_data_size=None, charge_detail=None, cpu_num=None, created_time=None, current_kernel_version=None, db_engine_version=None, db_param_group_id=None, db_time_zone=None, deletion_protection=None, disaster_recovery_instances=None, dr_dts_task_id=None, dr_dts_task_name=None, dr_dts_task_status=None, dr_seconds_behind_master=None, endpoints=None, global_read_only=None, has_disaster_recovery_instances=None, has_green_instance=None, id=None, instance_id=None, instance_name=None, instance_status=None, instance_type=None, lower_case_table_names=None, maintenance_window=None, master_instance_id=None, master_instance_name=None, memory=None, node_cpu_used_percentage=None, node_memory_used_percentage=None, node_number=None, node_space_used_percentage=None, node_spec=None, nodes=None, port=None, project_name=None, proxy_detail=None, storage_audit_log_size=None, storage_bin_log_size=None, storage_data_size=None, storage_error_log_size=None, storage_log_size=None, storage_slow_log_size=None, storage_space=None, storage_type=None, storage_use=None, subnet_id=None, super_account_name=None, super_account_password=None, sync_mode=None, tags=None, time_zone=None, updated_time=None, vcpu=None, vpc_id=None, zone_id=None, zone_ids=None):
        if address_objects and not isinstance(address_objects, list):
            raise TypeError("Expected argument 'address_objects' to be a list")
        pulumi.set(__self__, "address_objects", address_objects)
        if allow_list_ids and not isinstance(allow_list_ids, list):
            raise TypeError("Expected argument 'allow_list_ids' to be a list")
        pulumi.set(__self__, "allow_list_ids", allow_list_ids)
        if allow_list_version and not isinstance(allow_list_version, str):
            raise TypeError("Expected argument 'allow_list_version' to be a str")
        pulumi.set(__self__, "allow_list_version", allow_list_version)
        if auto_storage_scaling_config and not isinstance(auto_storage_scaling_config, dict):
            raise TypeError("Expected argument 'auto_storage_scaling_config' to be a dict")
        pulumi.set(__self__, "auto_storage_scaling_config", auto_storage_scaling_config)
        if auto_upgrade_minor_version and not isinstance(auto_upgrade_minor_version, str):
            raise TypeError("Expected argument 'auto_upgrade_minor_version' to be a str")
        pulumi.set(__self__, "auto_upgrade_minor_version", auto_upgrade_minor_version)
        if backup_audit_log_size and not isinstance(backup_audit_log_size, int):
            raise TypeError("Expected argument 'backup_audit_log_size' to be a int")
        pulumi.set(__self__, "backup_audit_log_size", backup_audit_log_size)
        if backup_bin_log_size and not isinstance(backup_bin_log_size, int):
            raise TypeError("Expected argument 'backup_bin_log_size' to be a int")
        pulumi.set(__self__, "backup_bin_log_size", backup_bin_log_size)
        if backup_data_size and not isinstance(backup_data_size, int):
            raise TypeError("Expected argument 'backup_data_size' to be a int")
        pulumi.set(__self__, "backup_data_size", backup_data_size)
        if backup_error_log_size and not isinstance(backup_error_log_size, int):
            raise TypeError("Expected argument 'backup_error_log_size' to be a int")
        pulumi.set(__self__, "backup_error_log_size", backup_error_log_size)
        if backup_free_quota_size and not isinstance(backup_free_quota_size, int):
            raise TypeError("Expected argument 'backup_free_quota_size' to be a int")
        pulumi.set(__self__, "backup_free_quota_size", backup_free_quota_size)
        if backup_log_size and not isinstance(backup_log_size, int):
            raise TypeError("Expected argument 'backup_log_size' to be a int")
        pulumi.set(__self__, "backup_log_size", backup_log_size)
        if backup_slow_log_size and not isinstance(backup_slow_log_size, int):
            raise TypeError("Expected argument 'backup_slow_log_size' to be a int")
        pulumi.set(__self__, "backup_slow_log_size", backup_slow_log_size)
        if backup_use and not isinstance(backup_use, float):
            raise TypeError("Expected argument 'backup_use' to be a float")
        pulumi.set(__self__, "backup_use", backup_use)
        if basic_backup_binlog_size and not isinstance(basic_backup_binlog_size, int):
            raise TypeError("Expected argument 'basic_backup_binlog_size' to be a int")
        pulumi.set(__self__, "basic_backup_binlog_size", basic_backup_binlog_size)
        if basic_backup_data_size and not isinstance(basic_backup_data_size, int):
            raise TypeError("Expected argument 'basic_backup_data_size' to be a int")
        pulumi.set(__self__, "basic_backup_data_size", basic_backup_data_size)
        if charge_detail and not isinstance(charge_detail, dict):
            raise TypeError("Expected argument 'charge_detail' to be a dict")
        pulumi.set(__self__, "charge_detail", charge_detail)
        if cpu_num and not isinstance(cpu_num, int):
            raise TypeError("Expected argument 'cpu_num' to be a int")
        pulumi.set(__self__, "cpu_num", cpu_num)
        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 current_kernel_version and not isinstance(current_kernel_version, str):
            raise TypeError("Expected argument 'current_kernel_version' to be a str")
        pulumi.set(__self__, "current_kernel_version", current_kernel_version)
        if db_engine_version and not isinstance(db_engine_version, str):
            raise TypeError("Expected argument 'db_engine_version' to be a str")
        pulumi.set(__self__, "db_engine_version", db_engine_version)
        if db_param_group_id and not isinstance(db_param_group_id, str):
            raise TypeError("Expected argument 'db_param_group_id' to be a str")
        pulumi.set(__self__, "db_param_group_id", db_param_group_id)
        if db_time_zone and not isinstance(db_time_zone, str):
            raise TypeError("Expected argument 'db_time_zone' to be a str")
        pulumi.set(__self__, "db_time_zone", db_time_zone)
        if deletion_protection and not isinstance(deletion_protection, str):
            raise TypeError("Expected argument 'deletion_protection' to be a str")
        pulumi.set(__self__, "deletion_protection", deletion_protection)
        if disaster_recovery_instances and not isinstance(disaster_recovery_instances, list):
            raise TypeError("Expected argument 'disaster_recovery_instances' to be a list")
        pulumi.set(__self__, "disaster_recovery_instances", disaster_recovery_instances)
        if dr_dts_task_id and not isinstance(dr_dts_task_id, str):
            raise TypeError("Expected argument 'dr_dts_task_id' to be a str")
        pulumi.set(__self__, "dr_dts_task_id", dr_dts_task_id)
        if dr_dts_task_name and not isinstance(dr_dts_task_name, str):
            raise TypeError("Expected argument 'dr_dts_task_name' to be a str")
        pulumi.set(__self__, "dr_dts_task_name", dr_dts_task_name)
        if dr_dts_task_status and not isinstance(dr_dts_task_status, str):
            raise TypeError("Expected argument 'dr_dts_task_status' to be a str")
        pulumi.set(__self__, "dr_dts_task_status", dr_dts_task_status)
        if dr_seconds_behind_master and not isinstance(dr_seconds_behind_master, int):
            raise TypeError("Expected argument 'dr_seconds_behind_master' to be a int")
        pulumi.set(__self__, "dr_seconds_behind_master", dr_seconds_behind_master)
        if endpoints and not isinstance(endpoints, list):
            raise TypeError("Expected argument 'endpoints' to be a list")
        pulumi.set(__self__, "endpoints", endpoints)
        if global_read_only and not isinstance(global_read_only, bool):
            raise TypeError("Expected argument 'global_read_only' to be a bool")
        pulumi.set(__self__, "global_read_only", global_read_only)
        if has_disaster_recovery_instances and not isinstance(has_disaster_recovery_instances, bool):
            raise TypeError("Expected argument 'has_disaster_recovery_instances' to be a bool")
        pulumi.set(__self__, "has_disaster_recovery_instances", has_disaster_recovery_instances)
        if has_green_instance and not isinstance(has_green_instance, bool):
            raise TypeError("Expected argument 'has_green_instance' to be a bool")
        pulumi.set(__self__, "has_green_instance", has_green_instance)
        if id and not isinstance(id, str):
            raise TypeError("Expected argument 'id' to be a str")
        pulumi.set(__self__, "id", id)
        if instance_id and not isinstance(instance_id, str):
            raise TypeError("Expected argument 'instance_id' to be a str")
        pulumi.set(__self__, "instance_id", instance_id)
        if instance_name and not isinstance(instance_name, str):
            raise TypeError("Expected argument 'instance_name' to be a str")
        pulumi.set(__self__, "instance_name", instance_name)
        if instance_status and not isinstance(instance_status, str):
            raise TypeError("Expected argument 'instance_status' to be a str")
        pulumi.set(__self__, "instance_status", instance_status)
        if instance_type and not isinstance(instance_type, str):
            raise TypeError("Expected argument 'instance_type' to be a str")
        pulumi.set(__self__, "instance_type", instance_type)
        if lower_case_table_names and not isinstance(lower_case_table_names, str):
            raise TypeError("Expected argument 'lower_case_table_names' to be a str")
        pulumi.set(__self__, "lower_case_table_names", lower_case_table_names)
        if maintenance_window and not isinstance(maintenance_window, dict):
            raise TypeError("Expected argument 'maintenance_window' to be a dict")
        pulumi.set(__self__, "maintenance_window", maintenance_window)
        if master_instance_id and not isinstance(master_instance_id, str):
            raise TypeError("Expected argument 'master_instance_id' to be a str")
        pulumi.set(__self__, "master_instance_id", master_instance_id)
        if master_instance_name and not isinstance(master_instance_name, str):
            raise TypeError("Expected argument 'master_instance_name' to be a str")
        pulumi.set(__self__, "master_instance_name", master_instance_name)
        if memory and not isinstance(memory, int):
            raise TypeError("Expected argument 'memory' to be a int")
        pulumi.set(__self__, "memory", memory)
        if node_cpu_used_percentage and not isinstance(node_cpu_used_percentage, float):
            raise TypeError("Expected argument 'node_cpu_used_percentage' to be a float")
        pulumi.set(__self__, "node_cpu_used_percentage", node_cpu_used_percentage)
        if node_memory_used_percentage and not isinstance(node_memory_used_percentage, float):
            raise TypeError("Expected argument 'node_memory_used_percentage' to be a float")
        pulumi.set(__self__, "node_memory_used_percentage", node_memory_used_percentage)
        if node_number and not isinstance(node_number, str):
            raise TypeError("Expected argument 'node_number' to be a str")
        pulumi.set(__self__, "node_number", node_number)
        if node_space_used_percentage and not isinstance(node_space_used_percentage, float):
            raise TypeError("Expected argument 'node_space_used_percentage' to be a float")
        pulumi.set(__self__, "node_space_used_percentage", node_space_used_percentage)
        if node_spec and not isinstance(node_spec, str):
            raise TypeError("Expected argument 'node_spec' to be a str")
        pulumi.set(__self__, "node_spec", node_spec)
        if nodes and not isinstance(nodes, list):
            raise TypeError("Expected argument 'nodes' to be a list")
        pulumi.set(__self__, "nodes", nodes)
        if port and not isinstance(port, int):
            raise TypeError("Expected argument 'port' to be a int")
        pulumi.set(__self__, "port", port)
        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 proxy_detail and not isinstance(proxy_detail, dict):
            raise TypeError("Expected argument 'proxy_detail' to be a dict")
        pulumi.set(__self__, "proxy_detail", proxy_detail)
        if storage_audit_log_size and not isinstance(storage_audit_log_size, int):
            raise TypeError("Expected argument 'storage_audit_log_size' to be a int")
        pulumi.set(__self__, "storage_audit_log_size", storage_audit_log_size)
        if storage_bin_log_size and not isinstance(storage_bin_log_size, int):
            raise TypeError("Expected argument 'storage_bin_log_size' to be a int")
        pulumi.set(__self__, "storage_bin_log_size", storage_bin_log_size)
        if storage_data_size and not isinstance(storage_data_size, int):
            raise TypeError("Expected argument 'storage_data_size' to be a int")
        pulumi.set(__self__, "storage_data_size", storage_data_size)
        if storage_error_log_size and not isinstance(storage_error_log_size, int):
            raise TypeError("Expected argument 'storage_error_log_size' to be a int")
        pulumi.set(__self__, "storage_error_log_size", storage_error_log_size)
        if storage_log_size and not isinstance(storage_log_size, int):
            raise TypeError("Expected argument 'storage_log_size' to be a int")
        pulumi.set(__self__, "storage_log_size", storage_log_size)
        if storage_slow_log_size and not isinstance(storage_slow_log_size, int):
            raise TypeError("Expected argument 'storage_slow_log_size' to be a int")
        pulumi.set(__self__, "storage_slow_log_size", storage_slow_log_size)
        if storage_space and not isinstance(storage_space, int):
            raise TypeError("Expected argument 'storage_space' to be a int")
        pulumi.set(__self__, "storage_space", storage_space)
        if storage_type and not isinstance(storage_type, str):
            raise TypeError("Expected argument 'storage_type' to be a str")
        pulumi.set(__self__, "storage_type", storage_type)
        if storage_use and not isinstance(storage_use, float):
            raise TypeError("Expected argument 'storage_use' to be a float")
        pulumi.set(__self__, "storage_use", storage_use)
        if subnet_id and not isinstance(subnet_id, str):
            raise TypeError("Expected argument 'subnet_id' to be a str")
        pulumi.set(__self__, "subnet_id", subnet_id)
        if super_account_name and not isinstance(super_account_name, str):
            raise TypeError("Expected argument 'super_account_name' to be a str")
        pulumi.set(__self__, "super_account_name", super_account_name)
        if super_account_password and not isinstance(super_account_password, str):
            raise TypeError("Expected argument 'super_account_password' to be a str")
        pulumi.set(__self__, "super_account_password", super_account_password)
        if sync_mode and not isinstance(sync_mode, str):
            raise TypeError("Expected argument 'sync_mode' to be a str")
        pulumi.set(__self__, "sync_mode", sync_mode)
        if tags and not isinstance(tags, list):
            raise TypeError("Expected argument 'tags' to be a list")
        pulumi.set(__self__, "tags", tags)
        if time_zone and not isinstance(time_zone, str):
            raise TypeError("Expected argument 'time_zone' to be a str")
        pulumi.set(__self__, "time_zone", time_zone)
        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)
        if vcpu and not isinstance(vcpu, int):
            raise TypeError("Expected argument 'vcpu' to be a int")
        pulumi.set(__self__, "vcpu", vcpu)
        if vpc_id and not isinstance(vpc_id, str):
            raise TypeError("Expected argument 'vpc_id' to be a str")
        pulumi.set(__self__, "vpc_id", vpc_id)
        if zone_id and not isinstance(zone_id, str):
            raise TypeError("Expected argument 'zone_id' to be a str")
        pulumi.set(__self__, "zone_id", zone_id)
        if zone_ids and not isinstance(zone_ids, list):
            raise TypeError("Expected argument 'zone_ids' to be a list")
        pulumi.set(__self__, "zone_ids", zone_ids)

    @property
    @pulumi.getter(name="addressObjects")
    def address_objects(self) -> Sequence['outputs.GetInstanceAddressObjectResult']:
        """
        默认终端的连接信息。
        """
        return pulumi.get(self, "address_objects")

    @property
    @pulumi.getter(name="allowListIds")
    def allow_list_ids(self) -> Sequence[builtins.str]:
        """
        白名单 ID。如需绑定多个白名单，白名单 ID 用英文逗号（,）分隔。一个实例最多可绑定 100 个白名单。
        """
        return pulumi.get(self, "allow_list_ids")

    @property
    @pulumi.getter(name="allowListVersion")
    def allow_list_version(self) -> builtins.str:
        """
        白名单版本。
        """
        return pulumi.get(self, "allow_list_version")

    @property
    @pulumi.getter(name="autoStorageScalingConfig")
    def auto_storage_scaling_config(self) -> 'outputs.GetInstanceAutoStorageScalingConfigResult':
        """
        自动扩容配置。
        """
        return pulumi.get(self, "auto_storage_scaling_config")

    @property
    @pulumi.getter(name="autoUpgradeMinorVersion")
    def auto_upgrade_minor_version(self) -> builtins.str:
        """
        实例内核小版本的升级策略。取值：Auto：自动升级。Manual：手动升级。
        """
        return pulumi.get(self, "auto_upgrade_minor_version")

    @property
    @pulumi.getter(name="backupAuditLogSize")
    def backup_audit_log_size(self) -> builtins.int:
        """
        备份中审计日志使用的空间。
        """
        return pulumi.get(self, "backup_audit_log_size")

    @property
    @pulumi.getter(name="backupBinLogSize")
    def backup_bin_log_size(self) -> builtins.int:
        """
        备份中 Binlog 日志使用的空间。
        """
        return pulumi.get(self, "backup_bin_log_size")

    @property
    @pulumi.getter(name="backupDataSize")
    def backup_data_size(self) -> builtins.int:
        """
        备份中数据使用的空间。
        """
        return pulumi.get(self, "backup_data_size")

    @property
    @pulumi.getter(name="backupErrorLogSize")
    def backup_error_log_size(self) -> builtins.int:
        """
        备份中错误日志使用的空间。
        """
        return pulumi.get(self, "backup_error_log_size")

    @property
    @pulumi.getter(name="backupFreeQuotaSize")
    def backup_free_quota_size(self) -> builtins.int:
        """
        免费的备份存储空间，单位为 GB。
        """
        return pulumi.get(self, "backup_free_quota_size")

    @property
    @pulumi.getter(name="backupLogSize")
    def backup_log_size(self) -> builtins.int:
        """
        备份中日志使用的空间。
        """
        return pulumi.get(self, "backup_log_size")

    @property
    @pulumi.getter(name="backupSlowLogSize")
    def backup_slow_log_size(self) -> builtins.int:
        """
        备份中慢日志使用的空间。
        """
        return pulumi.get(self, "backup_slow_log_size")

    @property
    @pulumi.getter(name="backupUse")
    def backup_use(self) -> builtins.float:
        """
        实例的备份已使用的空间，单位为 GB。
        """
        return pulumi.get(self, "backup_use")

    @property
    @pulumi.getter(name="basicBackupBinlogSize")
    def basic_backup_binlog_size(self) -> builtins.int:
        """
        基础备份中 Binlog 日志使用的空间。
        """
        return pulumi.get(self, "basic_backup_binlog_size")

    @property
    @pulumi.getter(name="basicBackupDataSize")
    def basic_backup_data_size(self) -> builtins.int:
        """
        基础备份中数据使用的空间。
        """
        return pulumi.get(self, "basic_backup_data_size")

    @property
    @pulumi.getter(name="chargeDetail")
    def charge_detail(self) -> 'outputs.GetInstanceChargeDetailResult':
        """
        付费方式。
        """
        return pulumi.get(self, "charge_detail")

    @property
    @pulumi.getter(name="cpuNum")
    def cpu_num(self) -> builtins.int:
        """
        实例数据库代理服务的 CPU 核数。
        """
        return pulumi.get(self, "cpu_num")

    @property
    @pulumi.getter(name="createdTime")
    def created_time(self) -> builtins.str:
        """
        实例创建本地时间。
        """
        return pulumi.get(self, "created_time")

    @property
    @pulumi.getter(name="currentKernelVersion")
    def current_kernel_version(self) -> builtins.str:
        """
        实例的内核小版本。
        """
        return pulumi.get(self, "current_kernel_version")

    @property
    @pulumi.getter(name="dbEngineVersion")
    def db_engine_version(self) -> builtins.str:
        """
        兼容版本。取值：MySQL*5*7：MySQL 5.7 版本。MySQL*8*0：MySQL 8.0 版本。
        """
        return pulumi.get(self, "db_engine_version")

    @property
    @pulumi.getter(name="dbParamGroupId")
    def db_param_group_id(self) -> builtins.str:
        """
        参数模板 ID。默认值为数据库引擎版本对应的默认参数模板。
        """
        return pulumi.get(self, "db_param_group_id")

    @property
    @pulumi.getter(name="dbTimeZone")
    def db_time_zone(self) -> builtins.str:
        """
        时区。支持 UTC -12:00 ~ +13:00。默认值为 Region 所在的 TimeZone。
        """
        return pulumi.get(self, "db_time_zone")

    @property
    @pulumi.getter(name="deletionProtection")
    def deletion_protection(self) -> builtins.str:
        """
        是否启用实例的删除保护功能。取值：Enabled：是。Disabled：否。默认值。
        """
        return pulumi.get(self, "deletion_protection")

    @property
    @pulumi.getter(name="disasterRecoveryInstances")
    def disaster_recovery_instances(self) -> Sequence['outputs.GetInstanceDisasterRecoveryInstanceResult']:
        """
        实例的灾备实例的信息。
        """
        return pulumi.get(self, "disaster_recovery_instances")

    @property
    @pulumi.getter(name="drDtsTaskId")
    def dr_dts_task_id(self) -> builtins.str:
        """
        主实例与灾备实例之间的数据同步链路在 DTS 数据同步任务的 ID。
        """
        return pulumi.get(self, "dr_dts_task_id")

    @property
    @pulumi.getter(name="drDtsTaskName")
    def dr_dts_task_name(self) -> builtins.str:
        """
        主实例与灾备实例之间同步任务的名称。
        """
        return pulumi.get(self, "dr_dts_task_name")

    @property
    @pulumi.getter(name="drDtsTaskStatus")
    def dr_dts_task_status(self) -> builtins.str:
        """
        主实例与灾备实例之间同步任务的状态。
        """
        return pulumi.get(self, "dr_dts_task_status")

    @property
    @pulumi.getter(name="drSecondsBehindMaster")
    def dr_seconds_behind_master(self) -> builtins.int:
        """
        灾备实例与主实例之间的时延。
        """
        return pulumi.get(self, "dr_seconds_behind_master")

    @property
    @pulumi.getter
    def endpoints(self) -> Sequence['outputs.GetInstanceEndpointResult']:
        """
        实例的连接信息。
        """
        return pulumi.get(self, "endpoints")

    @property
    @pulumi.getter(name="globalReadOnly")
    def global_read_only(self) -> builtins.bool:
        """
        是否开启全局只读。取值：true：是。false：否。默认值为 false。
        """
        return pulumi.get(self, "global_read_only")

    @property
    @pulumi.getter(name="hasDisasterRecoveryInstances")
    def has_disaster_recovery_instances(self) -> builtins.bool:
        """
        实例是否有灾备实例。取值：true：是。false：否。
        """
        return pulumi.get(self, "has_disaster_recovery_instances")

    @property
    @pulumi.getter(name="hasGreenInstance")
    def has_green_instance(self) -> builtins.bool:
        """
        实例是否处于蓝绿部署中。取值：true：是。false：否。
        """
        return pulumi.get(self, "has_green_instance")

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

    @property
    @pulumi.getter(name="instanceId")
    def instance_id(self) -> builtins.str:
        """
        实例 ID。
        """
        return pulumi.get(self, "instance_id")

    @property
    @pulumi.getter(name="instanceName")
    def instance_name(self) -> builtins.str:
        """
        实例名称。
        """
        return pulumi.get(self, "instance_name")

    @property
    @pulumi.getter(name="instanceStatus")
    def instance_status(self) -> builtins.str:
        """
        实例状态。
        """
        return pulumi.get(self, "instance_status")

    @property
    @pulumi.getter(name="instanceType")
    def instance_type(self) -> builtins.str:
        """
        实例类型。取值：DoubleNode，双节点类型。MultiNode，多节点类型。
        """
        return pulumi.get(self, "instance_type")

    @property
    @pulumi.getter(name="lowerCaseTableNames")
    def lower_case_table_names(self) -> builtins.str:
        """
        表名是否区分大小写，默认取值为 true。取值：false：表名被存储成固定且表名称大小写敏感。true：表名将被存储成小写且表名称大小写不敏感。
        """
        return pulumi.get(self, "lower_case_table_names")

    @property
    @pulumi.getter(name="maintenanceWindow")
    def maintenance_window(self) -> 'outputs.GetInstanceMaintenanceWindowResult':
        """
        在创建实例时指定实例的可维护时间段。该字段为可选，不设置时默认为一周内每一天的 UTC18:00Z-21:59Z（即北京时间 02:00-05:59）。
        """
        return pulumi.get(self, "maintenance_window")

    @property
    @pulumi.getter(name="masterInstanceId")
    def master_instance_id(self) -> builtins.str:
        """
        主实例的 ID。
        """
        return pulumi.get(self, "master_instance_id")

    @property
    @pulumi.getter(name="masterInstanceName")
    def master_instance_name(self) -> builtins.str:
        """
        主实例的名称。
        """
        return pulumi.get(self, "master_instance_name")

    @property
    @pulumi.getter
    def memory(self) -> builtins.int:
        """
        内存大小。单位：GB。
        """
        return pulumi.get(self, "memory")

    @property
    @pulumi.getter(name="nodeCpuUsedPercentage")
    def node_cpu_used_percentage(self) -> builtins.float:
        """
        实例主节点 CPU 使用率近一分钟的平均值。
        """
        return pulumi.get(self, "node_cpu_used_percentage")

    @property
    @pulumi.getter(name="nodeMemoryUsedPercentage")
    def node_memory_used_percentage(self) -> builtins.float:
        """
        实例主节点内存使用率近一分钟的平均值。
        """
        return pulumi.get(self, "node_memory_used_percentage")

    @property
    @pulumi.getter(name="nodeNumber")
    def node_number(self) -> builtins.str:
        """
        节点数量。
        """
        return pulumi.get(self, "node_number")

    @property
    @pulumi.getter(name="nodeSpaceUsedPercentage")
    def node_space_used_percentage(self) -> builtins.float:
        """
        实例主节点磁盘使用率近一分钟的平均值。
        """
        return pulumi.get(self, "node_space_used_percentage")

    @property
    @pulumi.getter(name="nodeSpec")
    def node_spec(self) -> builtins.str:
        """
        节点规格。
        """
        return pulumi.get(self, "node_spec")

    @property
    @pulumi.getter
    def nodes(self) -> Sequence['outputs.GetInstanceNodeResult']:
        """
        实例节点信息。
        """
        return pulumi.get(self, "nodes")

    @property
    @pulumi.getter
    def port(self) -> builtins.int:
        """
        默认终端的私网端口。端口号的取值范围为 1000~65534，默认值为 3306。创建新的连接终端或开启新地址时，将使用默认终端的私网端口实时配置为默认端口。
        """
        return pulumi.get(self, "port")

    @property
    @pulumi.getter(name="projectName")
    def project_name(self) -> builtins.str:
        """
        所属项目。
        """
        return pulumi.get(self, "project_name")

    @property
    @pulumi.getter(name="proxyDetail")
    def proxy_detail(self) -> 'outputs.GetInstanceProxyDetailResult':
        """
        proxy信息
        """
        return pulumi.get(self, "proxy_detail")

    @property
    @pulumi.getter(name="storageAuditLogSize")
    def storage_audit_log_size(self) -> builtins.int:
        """
        实例存储空间中审计日志使用的空间。
        """
        return pulumi.get(self, "storage_audit_log_size")

    @property
    @pulumi.getter(name="storageBinLogSize")
    def storage_bin_log_size(self) -> builtins.int:
        """
        实例存储空间中 Binlog 使用的空间。
        """
        return pulumi.get(self, "storage_bin_log_size")

    @property
    @pulumi.getter(name="storageDataSize")
    def storage_data_size(self) -> builtins.int:
        """
        实例存储空间中数据使用的空间。
        """
        return pulumi.get(self, "storage_data_size")

    @property
    @pulumi.getter(name="storageErrorLogSize")
    def storage_error_log_size(self) -> builtins.int:
        """
        实例存储空间中错误日志使用的空间。
        """
        return pulumi.get(self, "storage_error_log_size")

    @property
    @pulumi.getter(name="storageLogSize")
    def storage_log_size(self) -> builtins.int:
        """
        实例存储空间中日志使用的空间。
        """
        return pulumi.get(self, "storage_log_size")

    @property
    @pulumi.getter(name="storageSlowLogSize")
    def storage_slow_log_size(self) -> builtins.int:
        """
        实例存储空间中慢日志使用的空间。
        """
        return pulumi.get(self, "storage_slow_log_size")

    @property
    @pulumi.getter(name="storageSpace")
    def storage_space(self) -> builtins.int:
        """
        实例总存储空间。单位为 GB。
        """
        return pulumi.get(self, "storage_space")

    @property
    @pulumi.getter(name="storageType")
    def storage_type(self) -> builtins.str:
        """
        实例的存储类型。取值范围：LocalSSD：本地盘。CloudESSD*FlexPL：FlexPL 云盘。CloudESSD*PL0：PL0 云盘。
        """
        return pulumi.get(self, "storage_type")

    @property
    @pulumi.getter(name="storageUse")
    def storage_use(self) -> builtins.float:
        """
        实例已使用用存储空间，单位为 GB。
        """
        return pulumi.get(self, "storage_use")

    @property
    @pulumi.getter(name="subnetId")
    def subnet_id(self) -> builtins.str:
        """
        子网 ID。
        """
        return pulumi.get(self, "subnet_id")

    @property
    @pulumi.getter(name="superAccountName")
    def super_account_name(self) -> builtins.str:
        """
        高权限账号名称。不传此参数默认不创建高权限账号。
        """
        return pulumi.get(self, "super_account_name")

    @property
    @pulumi.getter(name="superAccountPassword")
    def super_account_password(self) -> builtins.str:
        """
        高权限账号的密码。密码规则如下：长度为 8~32 个字符。由大写字母、小写字母、数字、特殊字符中的至少三种组成。特殊字符为 !@#$%^&*()_+-=,.&?|/。
        """
        return pulumi.get(self, "super_account_password")

    @property
    @pulumi.getter(name="syncMode")
    def sync_mode(self) -> builtins.str:
        """
        数据同步方式：SemiSync：半同步。Async：异步。
        """
        return pulumi.get(self, "sync_mode")

    @property
    @pulumi.getter
    def tags(self) -> Sequence['outputs.GetInstanceTagResult']:
        """
        RDS MySQL 实例的标签信息
        """
        return pulumi.get(self, "tags")

    @property
    @pulumi.getter(name="timeZone")
    def time_zone(self) -> builtins.str:
        """
        时区。
        """
        return pulumi.get(self, "time_zone")

    @property
    @pulumi.getter(name="updatedTime")
    def updated_time(self) -> builtins.str:
        """
        实例更新本地时间。
        """
        return pulumi.get(self, "updated_time")

    @property
    @pulumi.getter
    def vcpu(self) -> builtins.int:
        """
        CPU 大小。例如：1 表示 1U。
        """
        return pulumi.get(self, "vcpu")

    @property
    @pulumi.getter(name="vpcId")
    def vpc_id(self) -> builtins.str:
        """
        专有网络（VPC） ID。
        """
        return pulumi.get(self, "vpc_id")

    @property
    @pulumi.getter(name="zoneId")
    def zone_id(self) -> builtins.str:
        """
        实例主节点所在可用区。
        """
        return pulumi.get(self, "zone_id")

    @property
    @pulumi.getter(name="zoneIds")
    def zone_ids(self) -> Sequence[builtins.str]:
        """
        实例各节点所在的可用区列表。
        """
        return pulumi.get(self, "zone_ids")


class AwaitableGetInstanceResult(GetInstanceResult):
    # pylint: disable=using-constant-test
    def __await__(self):
        if False:
            yield self
        return GetInstanceResult(
            address_objects=self.address_objects,
            allow_list_ids=self.allow_list_ids,
            allow_list_version=self.allow_list_version,
            auto_storage_scaling_config=self.auto_storage_scaling_config,
            auto_upgrade_minor_version=self.auto_upgrade_minor_version,
            backup_audit_log_size=self.backup_audit_log_size,
            backup_bin_log_size=self.backup_bin_log_size,
            backup_data_size=self.backup_data_size,
            backup_error_log_size=self.backup_error_log_size,
            backup_free_quota_size=self.backup_free_quota_size,
            backup_log_size=self.backup_log_size,
            backup_slow_log_size=self.backup_slow_log_size,
            backup_use=self.backup_use,
            basic_backup_binlog_size=self.basic_backup_binlog_size,
            basic_backup_data_size=self.basic_backup_data_size,
            charge_detail=self.charge_detail,
            cpu_num=self.cpu_num,
            created_time=self.created_time,
            current_kernel_version=self.current_kernel_version,
            db_engine_version=self.db_engine_version,
            db_param_group_id=self.db_param_group_id,
            db_time_zone=self.db_time_zone,
            deletion_protection=self.deletion_protection,
            disaster_recovery_instances=self.disaster_recovery_instances,
            dr_dts_task_id=self.dr_dts_task_id,
            dr_dts_task_name=self.dr_dts_task_name,
            dr_dts_task_status=self.dr_dts_task_status,
            dr_seconds_behind_master=self.dr_seconds_behind_master,
            endpoints=self.endpoints,
            global_read_only=self.global_read_only,
            has_disaster_recovery_instances=self.has_disaster_recovery_instances,
            has_green_instance=self.has_green_instance,
            id=self.id,
            instance_id=self.instance_id,
            instance_name=self.instance_name,
            instance_status=self.instance_status,
            instance_type=self.instance_type,
            lower_case_table_names=self.lower_case_table_names,
            maintenance_window=self.maintenance_window,
            master_instance_id=self.master_instance_id,
            master_instance_name=self.master_instance_name,
            memory=self.memory,
            node_cpu_used_percentage=self.node_cpu_used_percentage,
            node_memory_used_percentage=self.node_memory_used_percentage,
            node_number=self.node_number,
            node_space_used_percentage=self.node_space_used_percentage,
            node_spec=self.node_spec,
            nodes=self.nodes,
            port=self.port,
            project_name=self.project_name,
            proxy_detail=self.proxy_detail,
            storage_audit_log_size=self.storage_audit_log_size,
            storage_bin_log_size=self.storage_bin_log_size,
            storage_data_size=self.storage_data_size,
            storage_error_log_size=self.storage_error_log_size,
            storage_log_size=self.storage_log_size,
            storage_slow_log_size=self.storage_slow_log_size,
            storage_space=self.storage_space,
            storage_type=self.storage_type,
            storage_use=self.storage_use,
            subnet_id=self.subnet_id,
            super_account_name=self.super_account_name,
            super_account_password=self.super_account_password,
            sync_mode=self.sync_mode,
            tags=self.tags,
            time_zone=self.time_zone,
            updated_time=self.updated_time,
            vcpu=self.vcpu,
            vpc_id=self.vpc_id,
            zone_id=self.zone_id,
            zone_ids=self.zone_ids)


def get_instance(id: Optional[builtins.str] = None,
                 opts: Optional[pulumi.InvokeOptions] = None) -> AwaitableGetInstanceResult:
    """
    Data Source schema for Byteplus::RDSMySQL::Instance


    :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:rdsmysql/getInstance:getInstance', __args__, opts=opts, typ=GetInstanceResult).value

    return AwaitableGetInstanceResult(
        address_objects=pulumi.get(__ret__, 'address_objects'),
        allow_list_ids=pulumi.get(__ret__, 'allow_list_ids'),
        allow_list_version=pulumi.get(__ret__, 'allow_list_version'),
        auto_storage_scaling_config=pulumi.get(__ret__, 'auto_storage_scaling_config'),
        auto_upgrade_minor_version=pulumi.get(__ret__, 'auto_upgrade_minor_version'),
        backup_audit_log_size=pulumi.get(__ret__, 'backup_audit_log_size'),
        backup_bin_log_size=pulumi.get(__ret__, 'backup_bin_log_size'),
        backup_data_size=pulumi.get(__ret__, 'backup_data_size'),
        backup_error_log_size=pulumi.get(__ret__, 'backup_error_log_size'),
        backup_free_quota_size=pulumi.get(__ret__, 'backup_free_quota_size'),
        backup_log_size=pulumi.get(__ret__, 'backup_log_size'),
        backup_slow_log_size=pulumi.get(__ret__, 'backup_slow_log_size'),
        backup_use=pulumi.get(__ret__, 'backup_use'),
        basic_backup_binlog_size=pulumi.get(__ret__, 'basic_backup_binlog_size'),
        basic_backup_data_size=pulumi.get(__ret__, 'basic_backup_data_size'),
        charge_detail=pulumi.get(__ret__, 'charge_detail'),
        cpu_num=pulumi.get(__ret__, 'cpu_num'),
        created_time=pulumi.get(__ret__, 'created_time'),
        current_kernel_version=pulumi.get(__ret__, 'current_kernel_version'),
        db_engine_version=pulumi.get(__ret__, 'db_engine_version'),
        db_param_group_id=pulumi.get(__ret__, 'db_param_group_id'),
        db_time_zone=pulumi.get(__ret__, 'db_time_zone'),
        deletion_protection=pulumi.get(__ret__, 'deletion_protection'),
        disaster_recovery_instances=pulumi.get(__ret__, 'disaster_recovery_instances'),
        dr_dts_task_id=pulumi.get(__ret__, 'dr_dts_task_id'),
        dr_dts_task_name=pulumi.get(__ret__, 'dr_dts_task_name'),
        dr_dts_task_status=pulumi.get(__ret__, 'dr_dts_task_status'),
        dr_seconds_behind_master=pulumi.get(__ret__, 'dr_seconds_behind_master'),
        endpoints=pulumi.get(__ret__, 'endpoints'),
        global_read_only=pulumi.get(__ret__, 'global_read_only'),
        has_disaster_recovery_instances=pulumi.get(__ret__, 'has_disaster_recovery_instances'),
        has_green_instance=pulumi.get(__ret__, 'has_green_instance'),
        id=pulumi.get(__ret__, 'id'),
        instance_id=pulumi.get(__ret__, 'instance_id'),
        instance_name=pulumi.get(__ret__, 'instance_name'),
        instance_status=pulumi.get(__ret__, 'instance_status'),
        instance_type=pulumi.get(__ret__, 'instance_type'),
        lower_case_table_names=pulumi.get(__ret__, 'lower_case_table_names'),
        maintenance_window=pulumi.get(__ret__, 'maintenance_window'),
        master_instance_id=pulumi.get(__ret__, 'master_instance_id'),
        master_instance_name=pulumi.get(__ret__, 'master_instance_name'),
        memory=pulumi.get(__ret__, 'memory'),
        node_cpu_used_percentage=pulumi.get(__ret__, 'node_cpu_used_percentage'),
        node_memory_used_percentage=pulumi.get(__ret__, 'node_memory_used_percentage'),
        node_number=pulumi.get(__ret__, 'node_number'),
        node_space_used_percentage=pulumi.get(__ret__, 'node_space_used_percentage'),
        node_spec=pulumi.get(__ret__, 'node_spec'),
        nodes=pulumi.get(__ret__, 'nodes'),
        port=pulumi.get(__ret__, 'port'),
        project_name=pulumi.get(__ret__, 'project_name'),
        proxy_detail=pulumi.get(__ret__, 'proxy_detail'),
        storage_audit_log_size=pulumi.get(__ret__, 'storage_audit_log_size'),
        storage_bin_log_size=pulumi.get(__ret__, 'storage_bin_log_size'),
        storage_data_size=pulumi.get(__ret__, 'storage_data_size'),
        storage_error_log_size=pulumi.get(__ret__, 'storage_error_log_size'),
        storage_log_size=pulumi.get(__ret__, 'storage_log_size'),
        storage_slow_log_size=pulumi.get(__ret__, 'storage_slow_log_size'),
        storage_space=pulumi.get(__ret__, 'storage_space'),
        storage_type=pulumi.get(__ret__, 'storage_type'),
        storage_use=pulumi.get(__ret__, 'storage_use'),
        subnet_id=pulumi.get(__ret__, 'subnet_id'),
        super_account_name=pulumi.get(__ret__, 'super_account_name'),
        super_account_password=pulumi.get(__ret__, 'super_account_password'),
        sync_mode=pulumi.get(__ret__, 'sync_mode'),
        tags=pulumi.get(__ret__, 'tags'),
        time_zone=pulumi.get(__ret__, 'time_zone'),
        updated_time=pulumi.get(__ret__, 'updated_time'),
        vcpu=pulumi.get(__ret__, 'vcpu'),
        vpc_id=pulumi.get(__ret__, 'vpc_id'),
        zone_id=pulumi.get(__ret__, 'zone_id'),
        zone_ids=pulumi.get(__ret__, 'zone_ids'))
def get_instance_output(id: Optional[pulumi.Input[builtins.str]] = None,
                        opts: Optional[Union[pulumi.InvokeOptions, pulumi.InvokeOutputOptions]] = None) -> pulumi.Output[GetInstanceResult]:
    """
    Data Source schema for Byteplus::RDSMySQL::Instance


    :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:rdsmysql/getInstance:getInstance', __args__, opts=opts, typ=GetInstanceResult)
    return __ret__.apply(lambda __response__: GetInstanceResult(
        address_objects=pulumi.get(__response__, 'address_objects'),
        allow_list_ids=pulumi.get(__response__, 'allow_list_ids'),
        allow_list_version=pulumi.get(__response__, 'allow_list_version'),
        auto_storage_scaling_config=pulumi.get(__response__, 'auto_storage_scaling_config'),
        auto_upgrade_minor_version=pulumi.get(__response__, 'auto_upgrade_minor_version'),
        backup_audit_log_size=pulumi.get(__response__, 'backup_audit_log_size'),
        backup_bin_log_size=pulumi.get(__response__, 'backup_bin_log_size'),
        backup_data_size=pulumi.get(__response__, 'backup_data_size'),
        backup_error_log_size=pulumi.get(__response__, 'backup_error_log_size'),
        backup_free_quota_size=pulumi.get(__response__, 'backup_free_quota_size'),
        backup_log_size=pulumi.get(__response__, 'backup_log_size'),
        backup_slow_log_size=pulumi.get(__response__, 'backup_slow_log_size'),
        backup_use=pulumi.get(__response__, 'backup_use'),
        basic_backup_binlog_size=pulumi.get(__response__, 'basic_backup_binlog_size'),
        basic_backup_data_size=pulumi.get(__response__, 'basic_backup_data_size'),
        charge_detail=pulumi.get(__response__, 'charge_detail'),
        cpu_num=pulumi.get(__response__, 'cpu_num'),
        created_time=pulumi.get(__response__, 'created_time'),
        current_kernel_version=pulumi.get(__response__, 'current_kernel_version'),
        db_engine_version=pulumi.get(__response__, 'db_engine_version'),
        db_param_group_id=pulumi.get(__response__, 'db_param_group_id'),
        db_time_zone=pulumi.get(__response__, 'db_time_zone'),
        deletion_protection=pulumi.get(__response__, 'deletion_protection'),
        disaster_recovery_instances=pulumi.get(__response__, 'disaster_recovery_instances'),
        dr_dts_task_id=pulumi.get(__response__, 'dr_dts_task_id'),
        dr_dts_task_name=pulumi.get(__response__, 'dr_dts_task_name'),
        dr_dts_task_status=pulumi.get(__response__, 'dr_dts_task_status'),
        dr_seconds_behind_master=pulumi.get(__response__, 'dr_seconds_behind_master'),
        endpoints=pulumi.get(__response__, 'endpoints'),
        global_read_only=pulumi.get(__response__, 'global_read_only'),
        has_disaster_recovery_instances=pulumi.get(__response__, 'has_disaster_recovery_instances'),
        has_green_instance=pulumi.get(__response__, 'has_green_instance'),
        id=pulumi.get(__response__, 'id'),
        instance_id=pulumi.get(__response__, 'instance_id'),
        instance_name=pulumi.get(__response__, 'instance_name'),
        instance_status=pulumi.get(__response__, 'instance_status'),
        instance_type=pulumi.get(__response__, 'instance_type'),
        lower_case_table_names=pulumi.get(__response__, 'lower_case_table_names'),
        maintenance_window=pulumi.get(__response__, 'maintenance_window'),
        master_instance_id=pulumi.get(__response__, 'master_instance_id'),
        master_instance_name=pulumi.get(__response__, 'master_instance_name'),
        memory=pulumi.get(__response__, 'memory'),
        node_cpu_used_percentage=pulumi.get(__response__, 'node_cpu_used_percentage'),
        node_memory_used_percentage=pulumi.get(__response__, 'node_memory_used_percentage'),
        node_number=pulumi.get(__response__, 'node_number'),
        node_space_used_percentage=pulumi.get(__response__, 'node_space_used_percentage'),
        node_spec=pulumi.get(__response__, 'node_spec'),
        nodes=pulumi.get(__response__, 'nodes'),
        port=pulumi.get(__response__, 'port'),
        project_name=pulumi.get(__response__, 'project_name'),
        proxy_detail=pulumi.get(__response__, 'proxy_detail'),
        storage_audit_log_size=pulumi.get(__response__, 'storage_audit_log_size'),
        storage_bin_log_size=pulumi.get(__response__, 'storage_bin_log_size'),
        storage_data_size=pulumi.get(__response__, 'storage_data_size'),
        storage_error_log_size=pulumi.get(__response__, 'storage_error_log_size'),
        storage_log_size=pulumi.get(__response__, 'storage_log_size'),
        storage_slow_log_size=pulumi.get(__response__, 'storage_slow_log_size'),
        storage_space=pulumi.get(__response__, 'storage_space'),
        storage_type=pulumi.get(__response__, 'storage_type'),
        storage_use=pulumi.get(__response__, 'storage_use'),
        subnet_id=pulumi.get(__response__, 'subnet_id'),
        super_account_name=pulumi.get(__response__, 'super_account_name'),
        super_account_password=pulumi.get(__response__, 'super_account_password'),
        sync_mode=pulumi.get(__response__, 'sync_mode'),
        tags=pulumi.get(__response__, 'tags'),
        time_zone=pulumi.get(__response__, 'time_zone'),
        updated_time=pulumi.get(__response__, 'updated_time'),
        vcpu=pulumi.get(__response__, 'vcpu'),
        vpc_id=pulumi.get(__response__, 'vpc_id'),
        zone_id=pulumi.get(__response__, 'zone_id'),
        zone_ids=pulumi.get(__response__, 'zone_ids')))
