"use strict";
// *** WARNING: this file was generated by pulumi-language-nodejs. ***
// *** Do not edit by hand unless you're certain you know what you are doing! ***
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
    if (k2 === undefined) k2 = k;
    var desc = Object.getOwnPropertyDescriptor(m, k);
    if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
      desc = { enumerable: true, get: function() { return m[k]; } };
    }
    Object.defineProperty(o, k2, desc);
}) : (function(o, m, k, k2) {
    if (k2 === undefined) k2 = k;
    o[k2] = m[k];
}));
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
    Object.defineProperty(o, "default", { enumerable: true, value: v });
}) : function(o, v) {
    o["default"] = v;
});
var __importStar = (this && this.__importStar) || function (mod) {
    if (mod && mod.__esModule) return mod;
    var result = {};
    if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
    __setModuleDefault(result, mod);
    return result;
};
Object.defineProperty(exports, "__esModule", { value: true });
exports.ExadbVmCluster = void 0;
const pulumi = __importStar(require("@pulumi/pulumi"));
const utilities = __importStar(require("../utilities"));
/**
 * This resource provides the Exadb Vm Cluster resource in Oracle Cloud Infrastructure Database service.
 * Api doc link for the resource: https://docs.oracle.com/iaas/api/#/en/database/latest/ExadbVmCluster
 *
 * Example terraform configs related to the resource : https://github.com/oracle/terraform-provider-oci/tree/master/examples/database
 *
 * Creates an Exadata VM cluster on Exascale Infrastructure
 *
 * ## Example Usage
 *
 * ```typescript
 * import * as pulumi from "@pulumi/pulumi";
 * import * as oci from "@pulumi/oci";
 *
 * const testExadbVmCluster = new oci.database.ExadbVmCluster("test_exadb_vm_cluster", {
 *     availabilityDomain: exadbVmClusterAvailabilityDomain,
 *     backupSubnetId: testSubnet.id,
 *     compartmentId: compartmentId,
 *     displayName: exadbVmClusterDisplayName,
 *     exascaleDbStorageVaultId: testExascaleDbStorageVault.id,
 *     gridImageId: testImage.id,
 *     hostname: exadbVmClusterHostname,
 *     shape: exadbVmClusterShape,
 *     nodeConfig: {
 *         enabledEcpuCountPerNode: Number(exadbVmClusterEnabledEcpuCountPerNode),
 *         totalEcpuCountPerNode: Number(exadbVmClusterTotalEcpuCountPerNode),
 *         vmFileSystemStorageSizeGbsPerNode: Number(exadbVmClusterVmFileSystemStorageSizeInGbsPerNode),
 *     },
 *     nodeResources: [
 *         {
 *             nodeName: "node1",
 *         },
 *         {
 *             nodeName: "node2",
 *         },
 *     ],
 *     sshPublicKeys: exadbVmClusterSshPublicKeys,
 *     subnetId: testSubnet.id,
 *     backupNetworkNsgIds: exadbVmClusterBackupNetworkNsgIds,
 *     clusterName: exadbVmClusterClusterName,
 *     dataCollectionOptions: {
 *         isDiagnosticsEventsEnabled: exadbVmClusterDataCollectionOptionsIsDiagnosticsEventsEnabled === "true",
 *         isHealthMonitoringEnabled: exadbVmClusterDataCollectionOptionsIsHealthMonitoringEnabled === "true",
 *         isIncidentLogsEnabled: exadbVmClusterDataCollectionOptionsIsIncidentLogsEnabled === "true",
 *     },
 *     definedTags: exadbVmClusterDefinedTags,
 *     domain: exadbVmClusterDomain,
 *     freeformTags: {
 *         Department: "Finance",
 *     },
 *     licenseModel: exadbVmClusterLicenseModel,
 *     nsgIds: exadbVmClusterNsgIds,
 *     privateZoneId: testZone.id,
 *     scanListenerPortTcp: Number(exadbVmClusterScanListenerPortTcp),
 *     scanListenerPortTcpSsl: Number(exadbVmClusterScanListenerPortTcpSsl),
 *     securityAttributes: exadbVmClusterSecurityAttributes,
 *     shapeAttribute: exadbVmClusterShapeAttribute,
 *     subscriptionId: tenantSubscriptionId,
 *     systemVersion: exadbVmClusterSystemVersion,
 *     timeZone: exadbVmClusterTimeZone,
 * });
 * ```
 *
 * ## Import
 *
 * ExadbVmClusters can be imported using the `id`, e.g.
 *
 * ```sh
 * $ pulumi import oci:Database/exadbVmCluster:ExadbVmCluster test_exadb_vm_cluster "id"
 * ```
 */
class ExadbVmCluster extends pulumi.CustomResource {
    /**
     * Get an existing ExadbVmCluster 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, id, state, opts) {
        return new ExadbVmCluster(name, state, { ...opts, id: id });
    }
    /** @internal */
    static __pulumiType = 'oci:Database/exadbVmCluster:ExadbVmCluster';
    /**
     * Returns true if the given object is an instance of ExadbVmCluster.  This is designed to work even
     * when multiple copies of the Pulumi SDK have been loaded into the same process.
     */
    static isInstance(obj) {
        if (obj === undefined || obj === null) {
            return false;
        }
        return obj['__pulumiType'] === ExadbVmCluster.__pulumiType;
    }
    constructor(name, argsOrState, opts) {
        let resourceInputs = {};
        opts = opts || {};
        if (opts.id) {
            const state = argsOrState;
            resourceInputs["availabilityDomain"] = state?.availabilityDomain;
            resourceInputs["backupNetworkNsgIds"] = state?.backupNetworkNsgIds;
            resourceInputs["backupSubnetId"] = state?.backupSubnetId;
            resourceInputs["clusterName"] = state?.clusterName;
            resourceInputs["clusterPlacementGroupId"] = state?.clusterPlacementGroupId;
            resourceInputs["compartmentId"] = state?.compartmentId;
            resourceInputs["dataCollectionOptions"] = state?.dataCollectionOptions;
            resourceInputs["definedTags"] = state?.definedTags;
            resourceInputs["displayName"] = state?.displayName;
            resourceInputs["domain"] = state?.domain;
            resourceInputs["exascaleDbStorageVaultId"] = state?.exascaleDbStorageVaultId;
            resourceInputs["freeformTags"] = state?.freeformTags;
            resourceInputs["giVersion"] = state?.giVersion;
            resourceInputs["gridImageId"] = state?.gridImageId;
            resourceInputs["gridImageType"] = state?.gridImageType;
            resourceInputs["hostname"] = state?.hostname;
            resourceInputs["iormConfigCaches"] = state?.iormConfigCaches;
            resourceInputs["lastUpdateHistoryEntryId"] = state?.lastUpdateHistoryEntryId;
            resourceInputs["licenseModel"] = state?.licenseModel;
            resourceInputs["lifecycleDetails"] = state?.lifecycleDetails;
            resourceInputs["listenerPort"] = state?.listenerPort;
            resourceInputs["nodeConfig"] = state?.nodeConfig;
            resourceInputs["nodeResources"] = state?.nodeResources;
            resourceInputs["nsgIds"] = state?.nsgIds;
            resourceInputs["privateZoneId"] = state?.privateZoneId;
            resourceInputs["scanDnsName"] = state?.scanDnsName;
            resourceInputs["scanDnsRecordId"] = state?.scanDnsRecordId;
            resourceInputs["scanIpIds"] = state?.scanIpIds;
            resourceInputs["scanListenerPortTcp"] = state?.scanListenerPortTcp;
            resourceInputs["scanListenerPortTcpSsl"] = state?.scanListenerPortTcpSsl;
            resourceInputs["securityAttributes"] = state?.securityAttributes;
            resourceInputs["shape"] = state?.shape;
            resourceInputs["shapeAttribute"] = state?.shapeAttribute;
            resourceInputs["sshPublicKeys"] = state?.sshPublicKeys;
            resourceInputs["state"] = state?.state;
            resourceInputs["subnetId"] = state?.subnetId;
            resourceInputs["subscriptionId"] = state?.subscriptionId;
            resourceInputs["systemTags"] = state?.systemTags;
            resourceInputs["systemVersion"] = state?.systemVersion;
            resourceInputs["timeCreated"] = state?.timeCreated;
            resourceInputs["timeZone"] = state?.timeZone;
            resourceInputs["vipIds"] = state?.vipIds;
            resourceInputs["zoneId"] = state?.zoneId;
        }
        else {
            const args = argsOrState;
            if (args?.availabilityDomain === undefined && !opts.urn) {
                throw new Error("Missing required property 'availabilityDomain'");
            }
            if (args?.backupSubnetId === undefined && !opts.urn) {
                throw new Error("Missing required property 'backupSubnetId'");
            }
            if (args?.compartmentId === undefined && !opts.urn) {
                throw new Error("Missing required property 'compartmentId'");
            }
            if (args?.displayName === undefined && !opts.urn) {
                throw new Error("Missing required property 'displayName'");
            }
            if (args?.exascaleDbStorageVaultId === undefined && !opts.urn) {
                throw new Error("Missing required property 'exascaleDbStorageVaultId'");
            }
            if (args?.gridImageId === undefined && !opts.urn) {
                throw new Error("Missing required property 'gridImageId'");
            }
            if (args?.hostname === undefined && !opts.urn) {
                throw new Error("Missing required property 'hostname'");
            }
            if (args?.nodeConfig === undefined && !opts.urn) {
                throw new Error("Missing required property 'nodeConfig'");
            }
            if (args?.shape === undefined && !opts.urn) {
                throw new Error("Missing required property 'shape'");
            }
            if (args?.sshPublicKeys === undefined && !opts.urn) {
                throw new Error("Missing required property 'sshPublicKeys'");
            }
            if (args?.subnetId === undefined && !opts.urn) {
                throw new Error("Missing required property 'subnetId'");
            }
            resourceInputs["availabilityDomain"] = args?.availabilityDomain;
            resourceInputs["backupNetworkNsgIds"] = args?.backupNetworkNsgIds;
            resourceInputs["backupSubnetId"] = args?.backupSubnetId;
            resourceInputs["clusterName"] = args?.clusterName;
            resourceInputs["compartmentId"] = args?.compartmentId;
            resourceInputs["dataCollectionOptions"] = args?.dataCollectionOptions;
            resourceInputs["definedTags"] = args?.definedTags;
            resourceInputs["displayName"] = args?.displayName;
            resourceInputs["domain"] = args?.domain;
            resourceInputs["exascaleDbStorageVaultId"] = args?.exascaleDbStorageVaultId;
            resourceInputs["freeformTags"] = args?.freeformTags;
            resourceInputs["gridImageId"] = args?.gridImageId;
            resourceInputs["hostname"] = args?.hostname;
            resourceInputs["licenseModel"] = args?.licenseModel;
            resourceInputs["nodeConfig"] = args?.nodeConfig;
            resourceInputs["nodeResources"] = args?.nodeResources;
            resourceInputs["nsgIds"] = args?.nsgIds;
            resourceInputs["privateZoneId"] = args?.privateZoneId;
            resourceInputs["scanListenerPortTcp"] = args?.scanListenerPortTcp;
            resourceInputs["scanListenerPortTcpSsl"] = args?.scanListenerPortTcpSsl;
            resourceInputs["securityAttributes"] = args?.securityAttributes;
            resourceInputs["shape"] = args?.shape;
            resourceInputs["shapeAttribute"] = args?.shapeAttribute;
            resourceInputs["sshPublicKeys"] = args?.sshPublicKeys;
            resourceInputs["subnetId"] = args?.subnetId;
            resourceInputs["subscriptionId"] = args?.subscriptionId;
            resourceInputs["systemVersion"] = args?.systemVersion;
            resourceInputs["timeZone"] = args?.timeZone;
            resourceInputs["clusterPlacementGroupId"] = undefined /*out*/;
            resourceInputs["giVersion"] = undefined /*out*/;
            resourceInputs["gridImageType"] = undefined /*out*/;
            resourceInputs["iormConfigCaches"] = undefined /*out*/;
            resourceInputs["lastUpdateHistoryEntryId"] = undefined /*out*/;
            resourceInputs["lifecycleDetails"] = undefined /*out*/;
            resourceInputs["listenerPort"] = undefined /*out*/;
            resourceInputs["scanDnsName"] = undefined /*out*/;
            resourceInputs["scanDnsRecordId"] = undefined /*out*/;
            resourceInputs["scanIpIds"] = undefined /*out*/;
            resourceInputs["state"] = undefined /*out*/;
            resourceInputs["systemTags"] = undefined /*out*/;
            resourceInputs["timeCreated"] = undefined /*out*/;
            resourceInputs["vipIds"] = undefined /*out*/;
            resourceInputs["zoneId"] = undefined /*out*/;
        }
        opts = pulumi.mergeOptions(utilities.resourceOptsDefaults(), opts);
        super(ExadbVmCluster.__pulumiType, name, resourceInputs, opts);
    }
}
exports.ExadbVmCluster = ExadbVmCluster;
//# sourceMappingURL=exadbVmCluster.js.map