"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.VolumeGroupSapHana = void 0;
const pulumi = __importStar(require("@pulumi/pulumi"));
const utilities = __importStar(require("../utilities"));
/**
 * Manages a Application Volume Group for SAP HANA application.
 *
 * > **Note:** This feature is intended to be used for SAP-HANA workloads only, with several requirements, please refer to [Understand Azure NetApp Files application volume group for SAP HANA](https://learn.microsoft.com/en-us/azure/azure-netapp-files/application-volume-group-introduction) document as the starting point to understand this feature before using it with Terraform.
 *
 * ## Example Usage
 *
 * ```typescript
 * import * as pulumi from "@pulumi/pulumi";
 * import * as azure from "@pulumi/azure";
 * import * as random from "@pulumi/random";
 *
 * const example = new random.index.String("example", {
 *     length: 12,
 *     special: true,
 * });
 * const adminUsername = "exampleadmin";
 * const adminPassword = example.result;
 * const exampleResourceGroup = new azure.core.ResourceGroup("example", {
 *     name: `${prefix}-resources`,
 *     location: location,
 * });
 * const exampleVirtualNetwork = new azure.network.VirtualNetwork("example", {
 *     name: `${prefix}-vnet`,
 *     location: exampleResourceGroup.location,
 *     resourceGroupName: exampleResourceGroup.name,
 *     addressSpaces: ["10.88.0.0/16"],
 * });
 * const exampleSubnet = new azure.network.Subnet("example", {
 *     name: `${prefix}-delegated-subnet`,
 *     resourceGroupName: exampleResourceGroup.name,
 *     virtualNetworkName: exampleVirtualNetwork.name,
 *     addressPrefixes: ["10.88.2.0/24"],
 *     delegations: [{
 *         name: "testdelegation",
 *         serviceDelegation: {
 *             name: "Microsoft.Netapp/volumes",
 *             actions: [
 *                 "Microsoft.Network/networkinterfaces/*",
 *                 "Microsoft.Network/virtualNetworks/subnets/join/action",
 *             ],
 *         },
 *     }],
 * });
 * const example1 = new azure.network.Subnet("example1", {
 *     name: `${prefix}-hosts-subnet`,
 *     resourceGroupName: exampleResourceGroup.name,
 *     virtualNetworkName: exampleVirtualNetwork.name,
 *     addressPrefixes: ["10.88.1.0/24"],
 * });
 * const examplePlacementGroup = new azure.proximity.PlacementGroup("example", {
 *     name: `${prefix}-ppg`,
 *     location: exampleResourceGroup.location,
 *     resourceGroupName: exampleResourceGroup.name,
 * });
 * const exampleAvailabilitySet = new azure.compute.AvailabilitySet("example", {
 *     name: `${prefix}-avset`,
 *     location: exampleResourceGroup.location,
 *     resourceGroupName: exampleResourceGroup.name,
 *     proximityPlacementGroupId: examplePlacementGroup.id,
 * });
 * const exampleNetworkInterface = new azure.network.NetworkInterface("example", {
 *     name: `${prefix}-nic`,
 *     resourceGroupName: exampleResourceGroup.name,
 *     location: exampleResourceGroup.location,
 *     ipConfigurations: [{
 *         name: "internal",
 *         subnetId: example1.id,
 *         privateIpAddressAllocation: "Dynamic",
 *     }],
 * });
 * const exampleLinuxVirtualMachine = new azure.compute.LinuxVirtualMachine("example", {
 *     name: `${prefix}-vm`,
 *     resourceGroupName: exampleResourceGroup.name,
 *     location: exampleResourceGroup.location,
 *     size: "Standard_M8ms",
 *     adminUsername: adminUsername,
 *     adminPassword: adminPassword,
 *     disablePasswordAuthentication: false,
 *     proximityPlacementGroupId: examplePlacementGroup.id,
 *     availabilitySetId: exampleAvailabilitySet.id,
 *     networkInterfaceIds: [exampleNetworkInterface.id],
 *     sourceImageReference: {
 *         publisher: "Canonical",
 *         offer: "0001-com-ubuntu-server-jammy",
 *         sku: "22_04-lts",
 *         version: "latest",
 *     },
 *     osDisk: {
 *         storageAccountType: "Standard_LRS",
 *         caching: "ReadWrite",
 *     },
 * });
 * const exampleAccount = new azure.netapp.Account("example", {
 *     name: `${prefix}-netapp-account`,
 *     location: exampleResourceGroup.location,
 *     resourceGroupName: exampleResourceGroup.name,
 * }, {
 *     dependsOn: [
 *         exampleSubnet,
 *         example1,
 *     ],
 * });
 * const examplePool = new azure.netapp.Pool("example", {
 *     name: `${prefix}-netapp-pool`,
 *     location: exampleResourceGroup.location,
 *     resourceGroupName: exampleResourceGroup.name,
 *     accountName: exampleAccount.name,
 *     serviceLevel: "Standard",
 *     sizeInTb: 8,
 *     qosType: "Manual",
 * });
 * const exampleVolumeGroupSapHana = new azure.netapp.VolumeGroupSapHana("example", {
 *     name: `${prefix}-netapp-volumegroup`,
 *     location: exampleResourceGroup.location,
 *     resourceGroupName: exampleResourceGroup.name,
 *     accountName: exampleAccount.name,
 *     groupDescription: "Test volume group",
 *     applicationIdentifier: "TST",
 *     volumes: [
 *         {
 *             name: `${prefix}-netapp-volume-1`,
 *             volumePath: "my-unique-file-path-1",
 *             serviceLevel: "Standard",
 *             capacityPoolId: examplePool.id,
 *             subnetId: exampleSubnet.id,
 *             proximityPlacementGroupId: examplePlacementGroup.id,
 *             volumeSpecName: "data",
 *             storageQuotaInGb: 1024,
 *             throughputInMibps: 24,
 *             protocols: "NFSv4.1",
 *             securityStyle: "unix",
 *             snapshotDirectoryVisible: false,
 *             exportPolicyRules: [{
 *                 ruleIndex: 1,
 *                 allowedClients: "0.0.0.0/0",
 *                 nfsv3Enabled: false,
 *                 nfsv41Enabled: true,
 *                 unixReadOnly: false,
 *                 unixReadWrite: true,
 *                 rootAccessEnabled: false,
 *             }],
 *             tags: {
 *                 foo: "bar",
 *             },
 *         },
 *         {
 *             name: `${prefix}-netapp-volume-2`,
 *             volumePath: "my-unique-file-path-2",
 *             serviceLevel: "Standard",
 *             capacityPoolId: examplePool.id,
 *             subnetId: exampleSubnet.id,
 *             proximityPlacementGroupId: examplePlacementGroup.id,
 *             volumeSpecName: "log",
 *             storageQuotaInGb: 1024,
 *             throughputInMibps: 24,
 *             protocols: "NFSv4.1",
 *             securityStyle: "unix",
 *             snapshotDirectoryVisible: false,
 *             exportPolicyRules: [{
 *                 ruleIndex: 1,
 *                 allowedClients: "0.0.0.0/0",
 *                 nfsv3Enabled: false,
 *                 nfsv41Enabled: true,
 *                 unixReadOnly: false,
 *                 unixReadWrite: true,
 *                 rootAccessEnabled: false,
 *             }],
 *             tags: {
 *                 foo: "bar",
 *             },
 *         },
 *         {
 *             name: `${prefix}-netapp-volume-3`,
 *             volumePath: "my-unique-file-path-3",
 *             serviceLevel: "Standard",
 *             capacityPoolId: examplePool.id,
 *             subnetId: exampleSubnet.id,
 *             proximityPlacementGroupId: examplePlacementGroup.id,
 *             volumeSpecName: "shared",
 *             storageQuotaInGb: 1024,
 *             throughputInMibps: 24,
 *             protocols: "NFSv4.1",
 *             securityStyle: "unix",
 *             snapshotDirectoryVisible: false,
 *             exportPolicyRules: [{
 *                 ruleIndex: 1,
 *                 allowedClients: "0.0.0.0/0",
 *                 nfsv3Enabled: false,
 *                 nfsv41Enabled: true,
 *                 unixReadOnly: false,
 *                 unixReadWrite: true,
 *                 rootAccessEnabled: false,
 *             }],
 *         },
 *     ],
 * }, {
 *     dependsOn: [
 *         exampleLinuxVirtualMachine,
 *         examplePlacementGroup,
 *     ],
 * });
 * ```
 *
 * ### Example with Availability Zone and Customer-Managed Keys
 *
 * This example demonstrates using availability zones instead of proximity placement groups, with customer-managed key encryption and Standard network features.
 *
 * ```typescript
 * import * as pulumi from "@pulumi/pulumi";
 * import * as azure from "@pulumi/azure";
 *
 * const current = azure.core.getClientConfig({});
 * const example = new azure.core.ResourceGroup("example", {
 *     name: `${prefix}-resources`,
 *     location: location,
 * });
 * const exampleVirtualNetwork = new azure.network.VirtualNetwork("example", {
 *     name: `${prefix}-vnet`,
 *     location: example.location,
 *     resourceGroupName: example.name,
 *     addressSpaces: ["10.88.0.0/16"],
 * });
 * const exampleDelegated = new azure.network.Subnet("example_delegated", {
 *     name: `${prefix}-delegated-subnet`,
 *     resourceGroupName: example.name,
 *     virtualNetworkName: exampleVirtualNetwork.name,
 *     addressPrefixes: ["10.88.1.0/24"],
 *     delegations: [{
 *         name: "netapp",
 *         serviceDelegation: {
 *             name: "Microsoft.Netapp/volumes",
 *             actions: [
 *                 "Microsoft.Network/networkinterfaces/*",
 *                 "Microsoft.Network/virtualNetworks/subnets/join/action",
 *             ],
 *         },
 *     }],
 * });
 * const examplePrivateEndpoint = new azure.network.Subnet("example_private_endpoint", {
 *     name: `${prefix}-pe-subnet`,
 *     resourceGroupName: example.name,
 *     virtualNetworkName: exampleVirtualNetwork.name,
 *     addressPrefixes: ["10.88.2.0/24"],
 * });
 * const exampleAccount = new azure.netapp.Account("example", {
 *     name: `${prefix}-netapp-account`,
 *     location: example.location,
 *     resourceGroupName: example.name,
 *     identity: {
 *         type: "SystemAssigned",
 *     },
 * });
 * const exampleKeyVault = new azure.keyvault.KeyVault("example", {
 *     name: `${prefix}kv`,
 *     location: example.location,
 *     resourceGroupName: example.name,
 *     tenantId: current.then(current => current.tenantId),
 *     skuName: "standard",
 *     purgeProtectionEnabled: true,
 *     softDeleteRetentionDays: 7,
 *     enabledForDiskEncryption: true,
 *     enabledForDeployment: true,
 *     enabledForTemplateDeployment: true,
 *     accessPolicies: [
 *         {
 *             tenantId: current.then(current => current.tenantId),
 *             objectId: current.then(current => current.objectId),
 *             keyPermissions: [
 *                 "Get",
 *                 "Create",
 *                 "Delete",
 *                 "WrapKey",
 *                 "UnwrapKey",
 *                 "GetRotationPolicy",
 *                 "SetRotationPolicy",
 *             ],
 *         },
 *         {
 *             tenantId: exampleAccount.identity.apply(identity => identity?.tenantId),
 *             objectId: exampleAccount.identity.apply(identity => identity?.principalId),
 *             keyPermissions: [
 *                 "Get",
 *                 "Encrypt",
 *                 "Decrypt",
 *             ],
 *         },
 *     ],
 * });
 * const exampleKey = new azure.keyvault.Key("example", {
 *     name: `${prefix}-key`,
 *     keyVaultId: exampleKeyVault.id,
 *     keyType: "RSA",
 *     keySize: 2048,
 *     keyOpts: [
 *         "decrypt",
 *         "encrypt",
 *         "sign",
 *         "unwrapKey",
 *         "verify",
 *         "wrapKey",
 *     ],
 * });
 * const exampleAccountEncryption = new azure.netapp.AccountEncryption("example", {
 *     netappAccountId: exampleAccount.id,
 *     systemAssignedIdentityPrincipalId: exampleAccount.identity.apply(identity => identity?.principalId),
 *     encryptionKey: exampleKey.versionlessId,
 * });
 * const exampleEndpoint = new azure.privatelink.Endpoint("example", {
 *     name: `${prefix}-pe-kv`,
 *     location: example.location,
 *     resourceGroupName: example.name,
 *     subnetId: examplePrivateEndpoint.id,
 *     privateServiceConnection: {
 *         name: `${prefix}-pe-sc-kv`,
 *         privateConnectionResourceId: exampleKeyVault.id,
 *         isManualConnection: false,
 *         subresourceNames: ["Vault"],
 *     },
 * });
 * const examplePool = new azure.netapp.Pool("example", {
 *     name: `${prefix}-netapp-pool`,
 *     location: example.location,
 *     resourceGroupName: example.name,
 *     accountName: exampleAccount.name,
 *     serviceLevel: "Standard",
 *     sizeInTb: 8,
 *     qosType: "Manual",
 * }, {
 *     dependsOn: [exampleAccountEncryption],
 * });
 * const exampleVolumeGroupSapHana = new azure.netapp.VolumeGroupSapHana("example", {
 *     name: `${prefix}-netapp-volumegroup`,
 *     location: example.location,
 *     resourceGroupName: example.name,
 *     accountName: exampleAccount.name,
 *     groupDescription: "Test volume group with zone and CMK",
 *     applicationIdentifier: "TST",
 *     volumes: [
 *         {
 *             name: `${prefix}-netapp-volume-data`,
 *             volumePath: "my-unique-file-path-data",
 *             serviceLevel: "Standard",
 *             capacityPoolId: examplePool.id,
 *             subnetId: exampleDelegated.id,
 *             zone: "1",
 *             volumeSpecName: "data",
 *             storageQuotaInGb: 1024,
 *             throughputInMibps: 24,
 *             protocols: "NFSv4.1",
 *             securityStyle: "unix",
 *             snapshotDirectoryVisible: false,
 *             networkFeatures: "Standard",
 *             encryptionKeySource: "Microsoft.KeyVault",
 *             keyVaultPrivateEndpointId: exampleEndpoint.id,
 *             exportPolicyRules: [{
 *                 ruleIndex: 1,
 *                 allowedClients: "0.0.0.0/0",
 *                 nfsv3Enabled: false,
 *                 nfsv41Enabled: true,
 *                 unixReadOnly: false,
 *                 unixReadWrite: true,
 *                 rootAccessEnabled: false,
 *             }],
 *         },
 *         {
 *             name: `${prefix}-netapp-volume-log`,
 *             volumePath: "my-unique-file-path-log",
 *             serviceLevel: "Standard",
 *             capacityPoolId: examplePool.id,
 *             subnetId: exampleDelegated.id,
 *             zone: "1",
 *             volumeSpecName: "log",
 *             storageQuotaInGb: 1024,
 *             throughputInMibps: 24,
 *             protocols: "NFSv4.1",
 *             securityStyle: "unix",
 *             snapshotDirectoryVisible: false,
 *             networkFeatures: "Standard",
 *             encryptionKeySource: "Microsoft.KeyVault",
 *             keyVaultPrivateEndpointId: exampleEndpoint.id,
 *             exportPolicyRules: [{
 *                 ruleIndex: 1,
 *                 allowedClients: "0.0.0.0/0",
 *                 nfsv3Enabled: false,
 *                 nfsv41Enabled: true,
 *                 unixReadOnly: false,
 *                 unixReadWrite: true,
 *                 rootAccessEnabled: false,
 *             }],
 *         },
 *         {
 *             name: `${prefix}-netapp-volume-shared`,
 *             volumePath: "my-unique-file-path-shared",
 *             serviceLevel: "Standard",
 *             capacityPoolId: examplePool.id,
 *             subnetId: exampleDelegated.id,
 *             zone: "1",
 *             volumeSpecName: "shared",
 *             storageQuotaInGb: 1024,
 *             throughputInMibps: 24,
 *             protocols: "NFSv4.1",
 *             securityStyle: "unix",
 *             snapshotDirectoryVisible: false,
 *             networkFeatures: "Standard",
 *             encryptionKeySource: "Microsoft.KeyVault",
 *             keyVaultPrivateEndpointId: exampleEndpoint.id,
 *             exportPolicyRules: [{
 *                 ruleIndex: 1,
 *                 allowedClients: "0.0.0.0/0",
 *                 nfsv3Enabled: false,
 *                 nfsv41Enabled: true,
 *                 unixReadOnly: false,
 *                 unixReadWrite: true,
 *                 rootAccessEnabled: false,
 *             }],
 *         },
 *     ],
 * });
 * ```
 *
 * ## API Providers
 *
 * <!-- This section is generated, changes will be overwritten -->
 * This resource uses the following Azure API Providers:
 *
 * * `Microsoft.NetApp` - 2025-12-01
 *
 * ## Import
 *
 * Application Volume Groups can be imported using the `resource id`, e.g.
 *
 * ```sh
 * $ pulumi import azure:netapp/volumeGroupSapHana:VolumeGroupSapHana example /subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/mytest-rg/providers/Microsoft.NetApp/netAppAccounts/netapp-account-test/volumeGroups/netapp-volumegroup-test
 * ```
 */
class VolumeGroupSapHana extends pulumi.CustomResource {
    /**
     * Get an existing VolumeGroupSapHana 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 VolumeGroupSapHana(name, state, { ...opts, id: id });
    }
    /** @internal */
    static __pulumiType = 'azure:netapp/volumeGroupSapHana:VolumeGroupSapHana';
    /**
     * Returns true if the given object is an instance of VolumeGroupSapHana.  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'] === VolumeGroupSapHana.__pulumiType;
    }
    constructor(name, argsOrState, opts) {
        let resourceInputs = {};
        opts = opts || {};
        if (opts.id) {
            const state = argsOrState;
            resourceInputs["accountName"] = state?.accountName;
            resourceInputs["applicationIdentifier"] = state?.applicationIdentifier;
            resourceInputs["groupDescription"] = state?.groupDescription;
            resourceInputs["location"] = state?.location;
            resourceInputs["name"] = state?.name;
            resourceInputs["resourceGroupName"] = state?.resourceGroupName;
            resourceInputs["volumes"] = state?.volumes;
        }
        else {
            const args = argsOrState;
            if (args?.accountName === undefined && !opts.urn) {
                throw new Error("Missing required property 'accountName'");
            }
            if (args?.applicationIdentifier === undefined && !opts.urn) {
                throw new Error("Missing required property 'applicationIdentifier'");
            }
            if (args?.groupDescription === undefined && !opts.urn) {
                throw new Error("Missing required property 'groupDescription'");
            }
            if (args?.resourceGroupName === undefined && !opts.urn) {
                throw new Error("Missing required property 'resourceGroupName'");
            }
            if (args?.volumes === undefined && !opts.urn) {
                throw new Error("Missing required property 'volumes'");
            }
            resourceInputs["accountName"] = args?.accountName;
            resourceInputs["applicationIdentifier"] = args?.applicationIdentifier;
            resourceInputs["groupDescription"] = args?.groupDescription;
            resourceInputs["location"] = args?.location;
            resourceInputs["name"] = args?.name;
            resourceInputs["resourceGroupName"] = args?.resourceGroupName;
            resourceInputs["volumes"] = args?.volumes;
        }
        opts = pulumi.mergeOptions(utilities.resourceOptsDefaults(), opts);
        super(VolumeGroupSapHana.__pulumiType, name, resourceInputs, opts);
    }
}
exports.VolumeGroupSapHana = VolumeGroupSapHana;
//# sourceMappingURL=volumeGroupSapHana.js.map