import * as pulumi from "@pulumi/pulumi";
import * as inputs from "../types/input";
import * as outputs from "../types/output";
/**
 * Provides a resource to manage rds postgresql instance
 * ## Example Usage
 *
 * ```typescript
 * import * as pulumi from "@pulumi/pulumi";
 * import * as volcengine from "@pulumi/volcengine";
 * import * as volcengine from "@volcengine/pulumi";
 *
 * const fooZones = volcengine.ecs.getZones({});
 * // create vpc
 * const fooVpc = new volcengine.vpc.Vpc("fooVpc", {
 *     vpcName: "acc-test-vpc",
 *     cidrBlock: "172.16.0.0/16",
 *     dnsServers: [
 *         "8.8.8.8",
 *         "114.114.114.114",
 *     ],
 *     projectName: "default",
 * });
 * // create subnet
 * const fooSubnet = new volcengine.vpc.Subnet("fooSubnet", {
 *     subnetName: "acc-test-subnet",
 *     cidrBlock: "172.16.0.0/24",
 *     zoneId: fooZones.then(fooZones => fooZones.zones?.[0]?.id),
 *     vpcId: fooVpc.id,
 * });
 * // create postgresql instance
 * const fooInstance = new volcengine.rds_postgresql.Instance("fooInstance", {
 *     dbEngineVersion: "PostgreSQL_12",
 *     nodeSpec: "rds.postgres.1c2g",
 *     primaryZoneId: fooZones.then(fooZones => fooZones.zones?.[0]?.id),
 *     secondaryZoneId: fooZones.then(fooZones => fooZones.zones?.[0]?.id),
 *     storageSpace: 40,
 *     subnetId: fooSubnet.id,
 *     instanceName: "acc-test-postgresql-instance",
 *     chargeInfo: {
 *         chargeType: "PostPaid",
 *     },
 *     projectName: "default",
 *     tags: [{
 *         key: "tfk1",
 *         value: "tfv1",
 *     }],
 *     parameters: [
 *         {
 *             name: "auto_explain.log_analyze",
 *             value: "off",
 *         },
 *         {
 *             name: "auto_explain.log_format",
 *             value: "text",
 *         },
 *     ],
 * });
 * // create postgresql instance readonly node
 * const fooInstanceReadonlyNode = new volcengine.rds_postgresql.InstanceReadonlyNode("fooInstanceReadonlyNode", {
 *     instanceId: fooInstance.id,
 *     nodeSpec: "rds.postgres.1c2g",
 *     zoneId: fooZones.then(fooZones => fooZones.zones?.[0]?.id),
 * });
 * // create postgresql allow list
 * const fooAllowlist = new volcengine.rds_postgresql.Allowlist("fooAllowlist", {
 *     allowListName: "acc-test-allowlist",
 *     allowListDesc: "acc-test",
 *     allowListType: "IPv4",
 *     allowLists: [
 *         "192.168.0.0/24",
 *         "192.168.1.0/24",
 *     ],
 * });
 * // associate postgresql allow list to postgresql instance
 * const fooAllowlistAssociate = new volcengine.rds_postgresql.AllowlistAssociate("fooAllowlistAssociate", {
 *     instanceId: fooInstance.id,
 *     allowListId: fooAllowlist.id,
 * });
 * // create postgresql database
 * const fooDatabase = new volcengine.rds_postgresql.Database("fooDatabase", {
 *     dbName: "acc-test-database",
 *     instanceId: fooInstance.id,
 *     cType: "C",
 *     collate: "zh_CN.utf8",
 * });
 * // create postgresql account
 * const fooAccount = new volcengine.rds_postgresql.Account("fooAccount", {
 *     accountName: "acc-test-account",
 *     accountPassword: "9wc@********12",
 *     accountType: "Normal",
 *     instanceId: fooInstance.id,
 *     accountPrivileges: "Inherit,Login,CreateRole,CreateDB",
 * });
 * // create postgresql schema
 * const fooSchema = new volcengine.rds_postgresql.Schema("fooSchema", {
 *     dbName: fooDatabase.dbName,
 *     instanceId: fooInstance.id,
 *     owner: fooAccount.accountName,
 *     schemaName: "acc-test-schema",
 * });
 * ```
 *
 * ## Import
 *
 * RdsPostgresqlInstance can be imported using the id, e.g.
 *
 * ```sh
 * $ pulumi import volcengine:rds_postgresql/instance:Instance default postgres-21a3333b****
 * ```
 */
export declare class Instance extends pulumi.CustomResource {
    /**
     * Get an existing Instance resource's state with the given name, ID, and optional extra
     * properties used to qualify the lookup.
     *
     * @param name The _unique_ name of the resulting resource.
     * @param id The _unique_ provider ID of the resource to lookup.
     * @param state Any extra arguments used during the lookup.
     * @param opts Optional settings to control the behavior of the CustomResource.
     */
    static get(name: string, id: pulumi.Input<pulumi.ID>, state?: InstanceState, opts?: pulumi.CustomResourceOptions): Instance;
    /**
     * Returns true if the given object is an instance of Instance.  This is designed to work even
     * when multiple copies of the Pulumi SDK have been loaded into the same process.
     */
    static isInstance(obj: any): obj is Instance;
    /**
     * The instance has used backup space. Unit: GB.
     */
    readonly backupUse: pulumi.Output<number>;
    /**
     * Payment methods.
     */
    readonly chargeDetails: pulumi.Output<outputs.rds_postgresql.InstanceChargeDetail[]>;
    /**
     * Payment methods.
     */
    readonly chargeInfo: pulumi.Output<outputs.rds_postgresql.InstanceChargeInfo>;
    /**
     * Node creation local time.
     */
    readonly createTime: pulumi.Output<string>;
    /**
     * Data synchronization mode.
     */
    readonly dataSyncMode: pulumi.Output<string>;
    /**
     * Instance type. Value: PostgreSQL_11, PostgreSQL_12, PostgreSQL_13.
     */
    readonly dbEngineVersion: pulumi.Output<string>;
    /**
     * The endpoint info of the RDS instance.
     */
    readonly endpoints: pulumi.Output<outputs.rds_postgresql.InstanceEndpoint[]>;
    /**
     * Instance ID.
     */
    readonly instanceId: pulumi.Output<string>;
    /**
     * Instance name. Cannot start with a number or a dash. Can only contain Chinese characters, letters, numbers, underscores and dashes. The length is limited between 1 ~ 128.
     */
    readonly instanceName: pulumi.Output<string | undefined>;
    /**
     * The status of the RDS PostgreSQL instance.
     */
    readonly instanceStatus: pulumi.Output<string>;
    /**
     * The instance type of the RDS PostgreSQL instance.
     */
    readonly instanceType: pulumi.Output<string>;
    /**
     * Memory size in GB.
     */
    readonly memory: pulumi.Output<number>;
    /**
     * The number of nodes.
     */
    readonly nodeNumber: pulumi.Output<number>;
    /**
     * The specification of primary node and secondary node.
     */
    readonly nodeSpec: pulumi.Output<string>;
    /**
     * Instance node information.
     */
    readonly nodes: pulumi.Output<outputs.rds_postgresql.InstanceNode[]>;
    /**
     * Parameter of the RDS PostgreSQL instance. This field can only be added or modified. Deleting this field is invalid.
     */
    readonly parameters: pulumi.Output<outputs.rds_postgresql.InstanceParameter[] | undefined>;
    /**
     * The available zone of primary node.
     */
    readonly primaryZoneId: pulumi.Output<string>;
    /**
     * The project name of the RDS instance.
     */
    readonly projectName: pulumi.Output<string>;
    /**
     * The region of the RDS PostgreSQL instance.
     */
    readonly regionId: pulumi.Output<string>;
    /**
     * The available zone of secondary node.
     */
    readonly secondaryZoneId: pulumi.Output<string>;
    /**
     * Instance storage space. Value range: [20, 3000], unit: GB, increments every 100GB. Default value: 100.
     */
    readonly storageSpace: pulumi.Output<number | undefined>;
    /**
     * Instance storage type.
     */
    readonly storageType: pulumi.Output<string>;
    /**
     * Subnet ID of the RDS PostgreSQL instance.
     */
    readonly subnetId: pulumi.Output<string>;
    /**
     * Tags.
     */
    readonly tags: pulumi.Output<outputs.rds_postgresql.InstanceTag[] | undefined>;
    /**
     * The update time of the RDS PostgreSQL instance.
     */
    readonly updateTime: pulumi.Output<string>;
    /**
     * CPU size.
     */
    readonly vCpu: pulumi.Output<number>;
    /**
     * The vpc ID of the RDS PostgreSQL instance.
     */
    readonly vpcId: pulumi.Output<string>;
    /**
     * The available zone of the RDS PostgreSQL instance.
     */
    readonly zoneId: pulumi.Output<string>;
    /**
     * ID of the availability zone where each instance is located.
     */
    readonly zoneIds: pulumi.Output<string[]>;
    /**
     * Create a Instance resource with the given unique name, arguments, and options.
     *
     * @param name The _unique_ name of the resource.
     * @param args The arguments to use to populate this resource's properties.
     * @param opts A bag of options that control this resource's behavior.
     */
    constructor(name: string, args: InstanceArgs, opts?: pulumi.CustomResourceOptions);
}
/**
 * Input properties used for looking up and filtering Instance resources.
 */
export interface InstanceState {
    /**
     * The instance has used backup space. Unit: GB.
     */
    backupUse?: pulumi.Input<number>;
    /**
     * Payment methods.
     */
    chargeDetails?: pulumi.Input<pulumi.Input<inputs.rds_postgresql.InstanceChargeDetail>[]>;
    /**
     * Payment methods.
     */
    chargeInfo?: pulumi.Input<inputs.rds_postgresql.InstanceChargeInfo>;
    /**
     * Node creation local time.
     */
    createTime?: pulumi.Input<string>;
    /**
     * Data synchronization mode.
     */
    dataSyncMode?: pulumi.Input<string>;
    /**
     * Instance type. Value: PostgreSQL_11, PostgreSQL_12, PostgreSQL_13.
     */
    dbEngineVersion?: pulumi.Input<string>;
    /**
     * The endpoint info of the RDS instance.
     */
    endpoints?: pulumi.Input<pulumi.Input<inputs.rds_postgresql.InstanceEndpoint>[]>;
    /**
     * Instance ID.
     */
    instanceId?: pulumi.Input<string>;
    /**
     * Instance name. Cannot start with a number or a dash. Can only contain Chinese characters, letters, numbers, underscores and dashes. The length is limited between 1 ~ 128.
     */
    instanceName?: pulumi.Input<string>;
    /**
     * The status of the RDS PostgreSQL instance.
     */
    instanceStatus?: pulumi.Input<string>;
    /**
     * The instance type of the RDS PostgreSQL instance.
     */
    instanceType?: pulumi.Input<string>;
    /**
     * Memory size in GB.
     */
    memory?: pulumi.Input<number>;
    /**
     * The number of nodes.
     */
    nodeNumber?: pulumi.Input<number>;
    /**
     * The specification of primary node and secondary node.
     */
    nodeSpec?: pulumi.Input<string>;
    /**
     * Instance node information.
     */
    nodes?: pulumi.Input<pulumi.Input<inputs.rds_postgresql.InstanceNode>[]>;
    /**
     * Parameter of the RDS PostgreSQL instance. This field can only be added or modified. Deleting this field is invalid.
     */
    parameters?: pulumi.Input<pulumi.Input<inputs.rds_postgresql.InstanceParameter>[]>;
    /**
     * The available zone of primary node.
     */
    primaryZoneId?: pulumi.Input<string>;
    /**
     * The project name of the RDS instance.
     */
    projectName?: pulumi.Input<string>;
    /**
     * The region of the RDS PostgreSQL instance.
     */
    regionId?: pulumi.Input<string>;
    /**
     * The available zone of secondary node.
     */
    secondaryZoneId?: pulumi.Input<string>;
    /**
     * Instance storage space. Value range: [20, 3000], unit: GB, increments every 100GB. Default value: 100.
     */
    storageSpace?: pulumi.Input<number>;
    /**
     * Instance storage type.
     */
    storageType?: pulumi.Input<string>;
    /**
     * Subnet ID of the RDS PostgreSQL instance.
     */
    subnetId?: pulumi.Input<string>;
    /**
     * Tags.
     */
    tags?: pulumi.Input<pulumi.Input<inputs.rds_postgresql.InstanceTag>[]>;
    /**
     * The update time of the RDS PostgreSQL instance.
     */
    updateTime?: pulumi.Input<string>;
    /**
     * CPU size.
     */
    vCpu?: pulumi.Input<number>;
    /**
     * The vpc ID of the RDS PostgreSQL instance.
     */
    vpcId?: pulumi.Input<string>;
    /**
     * The available zone of the RDS PostgreSQL instance.
     */
    zoneId?: pulumi.Input<string>;
    /**
     * ID of the availability zone where each instance is located.
     */
    zoneIds?: pulumi.Input<pulumi.Input<string>[]>;
}
/**
 * The set of arguments for constructing a Instance resource.
 */
export interface InstanceArgs {
    /**
     * Payment methods.
     */
    chargeInfo: pulumi.Input<inputs.rds_postgresql.InstanceChargeInfo>;
    /**
     * Instance type. Value: PostgreSQL_11, PostgreSQL_12, PostgreSQL_13.
     */
    dbEngineVersion: pulumi.Input<string>;
    /**
     * Instance name. Cannot start with a number or a dash. Can only contain Chinese characters, letters, numbers, underscores and dashes. The length is limited between 1 ~ 128.
     */
    instanceName?: pulumi.Input<string>;
    /**
     * The specification of primary node and secondary node.
     */
    nodeSpec: pulumi.Input<string>;
    /**
     * Parameter of the RDS PostgreSQL instance. This field can only be added or modified. Deleting this field is invalid.
     */
    parameters?: pulumi.Input<pulumi.Input<inputs.rds_postgresql.InstanceParameter>[]>;
    /**
     * The available zone of primary node.
     */
    primaryZoneId: pulumi.Input<string>;
    /**
     * The project name of the RDS instance.
     */
    projectName?: pulumi.Input<string>;
    /**
     * The available zone of secondary node.
     */
    secondaryZoneId: pulumi.Input<string>;
    /**
     * Instance storage space. Value range: [20, 3000], unit: GB, increments every 100GB. Default value: 100.
     */
    storageSpace?: pulumi.Input<number>;
    /**
     * Subnet ID of the RDS PostgreSQL instance.
     */
    subnetId: pulumi.Input<string>;
    /**
     * Tags.
     */
    tags?: pulumi.Input<pulumi.Input<inputs.rds_postgresql.InstanceTag>[]>;
}
