All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.pulumi.azurenative.workloads.ACSSBackupConnection Maven / Gradle / Ivy

There is a newer version: 2.78.0
Show newest version
// *** WARNING: this file was generated by pulumi-java-gen. ***
// *** Do not edit by hand unless you're certain you know what you are doing! ***

package com.pulumi.azurenative.workloads;

import com.pulumi.azurenative.Utilities;
import com.pulumi.azurenative.workloads.ACSSBackupConnectionArgs;
import com.pulumi.azurenative.workloads.outputs.ConnectorErrorDefinitionResponse;
import com.pulumi.azurenative.workloads.outputs.HanaBackupDataResponse;
import com.pulumi.azurenative.workloads.outputs.SqlBackupDataResponse;
import com.pulumi.azurenative.workloads.outputs.SystemDataResponse;
import com.pulumi.azurenative.workloads.outputs.VMBackupDataResponse;
import com.pulumi.core.Alias;
import com.pulumi.core.Output;
import com.pulumi.core.annotations.Export;
import com.pulumi.core.annotations.ResourceType;
import com.pulumi.core.internal.Codegen;
import java.lang.Object;
import java.lang.String;
import java.util.List;
import java.util.Map;
import java.util.Optional;
import javax.annotation.Nullable;

/**
 * Define the backup connection resource of virtual instance for SAP..
 * Azure REST API version: 2023-10-01-preview.
 * 
 * ## Example Usage
 * ### Create a HANA backup connection with a new backup policy.
 * 
 * 
 * {@code
 * package generated_program;
 * 
 * import com.pulumi.Context;
 * import com.pulumi.Pulumi;
 * import com.pulumi.core.Output;
 * import com.pulumi.azurenative.workloads.ACSSBackupConnection;
 * import com.pulumi.azurenative.workloads.ACSSBackupConnectionArgs;
 * import java.util.List;
 * import java.util.ArrayList;
 * import java.util.Map;
 * import java.io.File;
 * import java.nio.file.Files;
 * import java.nio.file.Paths;
 * 
 * public class App {
 *     public static void main(String[] args) {
 *         Pulumi.run(App::stack);
 *     }
 * 
 *     public static void stack(Context ctx) {
 *         var acssBackupConnection = new ACSSBackupConnection("acssBackupConnection", ACSSBackupConnectionArgs.builder()
 *             .backupData(HanaBackupDataArgs.builder()
 *                 .backupPolicy(DBBackupPolicyPropertiesArgs.builder()
 *                     .backupManagementType("AzureWorkload")
 *                     .name("defaultHanaPolicy")
 *                     .protectedItemsCount(0)
 *                     .settings(SettingsArgs.builder()
 *                         .isCompression(false)
 *                         .issqlcompression(false)
 *                         .timeZone("UTC")
 *                         .build())
 *                     .subProtectionPolicy(                    
 *                         SubProtectionPolicyArgs.builder()
 *                             .policyType("Full")
 *                             .retentionPolicy(LongTermRetentionPolicyArgs.builder()
 *                                 .monthlySchedule(MonthlyRetentionScheduleArgs.builder()
 *                                     .retentionDuration(RetentionDurationArgs.builder()
 *                                         .count(60)
 *                                         .durationType("Months")
 *                                         .build())
 *                                     .retentionScheduleFormatType("Weekly")
 *                                     .retentionScheduleWeekly(WeeklyRetentionFormatArgs.builder()
 *                                         .daysOfTheWeek("Sunday")
 *                                         .weeksOfTheMonth("First")
 *                                         .build())
 *                                     .retentionTimes("2022-11-29T19:30:00.000Z")
 *                                     .build())
 *                                 .retentionPolicyType("LongTermRetentionPolicy")
 *                                 .weeklySchedule(WeeklyRetentionScheduleArgs.builder()
 *                                     .daysOfTheWeek("Sunday")
 *                                     .retentionDuration(RetentionDurationArgs.builder()
 *                                         .count(104)
 *                                         .durationType("Weeks")
 *                                         .build())
 *                                     .retentionTimes("2022-11-29T19:30:00.000Z")
 *                                     .build())
 *                                 .yearlySchedule(YearlyRetentionScheduleArgs.builder()
 *                                     .monthsOfYear("January")
 *                                     .retentionDuration(RetentionDurationArgs.builder()
 *                                         .count(10)
 *                                         .durationType("Years")
 *                                         .build())
 *                                     .retentionScheduleFormatType("Weekly")
 *                                     .retentionScheduleWeekly(WeeklyRetentionFormatArgs.builder()
 *                                         .daysOfTheWeek("Sunday")
 *                                         .weeksOfTheMonth("First")
 *                                         .build())
 *                                     .retentionTimes("2022-11-29T19:30:00.000Z")
 *                                     .build())
 *                                 .build())
 *                             .schedulePolicy(SimpleSchedulePolicyArgs.builder()
 *                                 .schedulePolicyType("SimpleSchedulePolicy")
 *                                 .scheduleRunDays("Sunday")
 *                                 .scheduleRunFrequency("Weekly")
 *                                 .scheduleRunTimes("2022-11-29T19:30:00.000Z")
 *                                 .build())
 *                             .tieringPolicy(Map.of("ArchivedRP", Map.of("tieringMode", "DoNotTier")))
 *                             .build(),
 *                         SubProtectionPolicyArgs.builder()
 *                             .policyType("Differential")
 *                             .retentionPolicy(SimpleRetentionPolicyArgs.builder()
 *                                 .retentionDuration(RetentionDurationArgs.builder()
 *                                     .count(30)
 *                                     .durationType("Days")
 *                                     .build())
 *                                 .retentionPolicyType("SimpleRetentionPolicy")
 *                                 .build())
 *                             .schedulePolicy(SimpleSchedulePolicyArgs.builder()
 *                                 .schedulePolicyType("SimpleSchedulePolicy")
 *                                 .scheduleRunDays("Monday")
 *                                 .scheduleRunFrequency("Weekly")
 *                                 .scheduleRunTimes("2022-09-29T02:00:00Z")
 *                                 .scheduleWeeklyFrequency(0)
 *                                 .build())
 *                             .build(),
 *                         SubProtectionPolicyArgs.builder()
 *                             .policyType("Log")
 *                             .retentionPolicy(SimpleRetentionPolicyArgs.builder()
 *                                 .retentionDuration(RetentionDurationArgs.builder()
 *                                     .count(20)
 *                                     .durationType("Days")
 *                                     .build())
 *                                 .retentionPolicyType("SimpleRetentionPolicy")
 *                                 .build())
 *                             .schedulePolicy(LogSchedulePolicyArgs.builder()
 *                                 .scheduleFrequencyInMins(120)
 *                                 .schedulePolicyType("LogSchedulePolicy")
 *                                 .build())
 *                             .build())
 *                     .workLoadType("SAPHanaDatabase")
 *                     .build())
 *                 .backupType("HANA")
 *                 .dbInstanceSnapshotBackupPolicy(DBBackupPolicyPropertiesArgs.builder()
 *                     .backupManagementType("AzureWorkload")
 *                     .name("defaultDbInstanceSnapshotPolicy")
 *                     .settings(SettingsArgs.builder()
 *                         .isCompression(false)
 *                         .issqlcompression(false)
 *                         .timeZone("UTC")
 *                         .build())
 *                     .subProtectionPolicy(SubProtectionPolicyArgs.builder()
 *                         .policyType("SnapshotFull")
 *                         .schedulePolicy(SimpleSchedulePolicyArgs.builder()
 *                             .schedulePolicyType("SimpleSchedulePolicy")
 *                             .scheduleRunFrequency("Daily")
 *                             .scheduleRunTimes("2023-09-18T06:30:00.000Z")
 *                             .build())
 *                         .snapshotBackupAdditionalDetails(SnapshotBackupAdditionalDetailsArgs.builder()
 *                             .instantRPDetails("test-rg")
 *                             .instantRpRetentionRangeInDays(1)
 *                             .userAssignedManagedIdentityDetails(UserAssignedManagedIdentityDetailsArgs.builder()
 *                                 .identityArmId("/subscriptions/6d875e77-e412-4d7d-9af4-8895278b4443/resourcegroups/test-rg/providers/Microsoft.ManagedIdentity/userAssignedIdentities/testMsi")
 *                                 .identityName("testMsi")
 *                                 .userAssignedIdentityProperties(UserAssignedIdentityPropertiesArgs.builder()
 *                                     .clientId("c3a877cf-51f8-4031-8f17-ab562d1e7737")
 *                                     .principalId("2f5834bd-4b86-4d85-a8df-6dd829a6418c")
 *                                     .build())
 *                                 .build())
 *                             .build())
 *                         .build())
 *                     .workLoadType("SAPHanaDBInstance")
 *                     .build())
 *                 .hdbuserstoreKeyName("abcd")
 *                 .instanceNumber("00")
 *                 .recoveryServicesVault(NewRecoveryServicesVaultArgs.builder()
 *                     .name("test-vault")
 *                     .resourceGroup("test-rg")
 *                     .vaultType("New")
 *                     .build())
 *                 .sslConfiguration(SSLConfigurationArgs.builder()
 *                     .sslCryptoProvider("commoncrypto")
 *                     .sslHostNameInCertificate("hostname")
 *                     .sslKeyStore("sapsrv.pse")
 *                     .sslTrustStore("sapsrv.pse")
 *                     .build())
 *                 .build())
 *             .backupName("dbBackup")
 *             .connectorName("C1")
 *             .location("westcentralus")
 *             .resourceGroupName("test-rg")
 *             .tags()
 *             .build());
 * 
 *     }
 * }
 * 
 * }
 * 
* ### Create a SQL backup connection with a new backup policy. * *
 * {@code
 * package generated_program;
 * 
 * import com.pulumi.Context;
 * import com.pulumi.Pulumi;
 * import com.pulumi.core.Output;
 * import com.pulumi.azurenative.workloads.ACSSBackupConnection;
 * import com.pulumi.azurenative.workloads.ACSSBackupConnectionArgs;
 * import java.util.List;
 * import java.util.ArrayList;
 * import java.util.Map;
 * import java.io.File;
 * import java.nio.file.Files;
 * import java.nio.file.Paths;
 * 
 * public class App {
 *     public static void main(String[] args) {
 *         Pulumi.run(App::stack);
 *     }
 * 
 *     public static void stack(Context ctx) {
 *         var acssBackupConnection = new ACSSBackupConnection("acssBackupConnection", ACSSBackupConnectionArgs.builder()
 *             .backupData(HanaBackupDataArgs.builder()
 *                 .backupPolicy(DBBackupPolicyPropertiesArgs.builder()
 *                     .backupManagementType("AzureWorkload")
 *                     .name("defaultSqlPolicy")
 *                     .protectedItemsCount(0)
 *                     .settings(SettingsArgs.builder()
 *                         .isCompression(true)
 *                         .issqlcompression(true)
 *                         .timeZone("UTC")
 *                         .build())
 *                     .subProtectionPolicy(                    
 *                         SubProtectionPolicyArgs.builder()
 *                             .policyType("Full")
 *                             .retentionPolicy(LongTermRetentionPolicyArgs.builder()
 *                                 .monthlySchedule(MonthlyRetentionScheduleArgs.builder()
 *                                     .retentionDuration(RetentionDurationArgs.builder()
 *                                         .count(60)
 *                                         .durationType("Months")
 *                                         .build())
 *                                     .retentionScheduleFormatType("Weekly")
 *                                     .retentionScheduleWeekly(WeeklyRetentionFormatArgs.builder()
 *                                         .daysOfTheWeek("Sunday")
 *                                         .weeksOfTheMonth("First")
 *                                         .build())
 *                                     .retentionTimes("2022-11-29T19:30:00.000Z")
 *                                     .build())
 *                                 .retentionPolicyType("LongTermRetentionPolicy")
 *                                 .weeklySchedule(WeeklyRetentionScheduleArgs.builder()
 *                                     .daysOfTheWeek("Sunday")
 *                                     .retentionDuration(RetentionDurationArgs.builder()
 *                                         .count(104)
 *                                         .durationType("Weeks")
 *                                         .build())
 *                                     .retentionTimes("2022-11-29T19:30:00.000Z")
 *                                     .build())
 *                                 .yearlySchedule(YearlyRetentionScheduleArgs.builder()
 *                                     .monthsOfYear("January")
 *                                     .retentionDuration(RetentionDurationArgs.builder()
 *                                         .count(10)
 *                                         .durationType("Years")
 *                                         .build())
 *                                     .retentionScheduleFormatType("Weekly")
 *                                     .retentionScheduleWeekly(WeeklyRetentionFormatArgs.builder()
 *                                         .daysOfTheWeek("Sunday")
 *                                         .weeksOfTheMonth("First")
 *                                         .build())
 *                                     .retentionTimes("2022-11-29T19:30:00.000Z")
 *                                     .build())
 *                                 .build())
 *                             .schedulePolicy(SimpleSchedulePolicyArgs.builder()
 *                                 .schedulePolicyType("SimpleSchedulePolicy")
 *                                 .scheduleRunDays("Sunday")
 *                                 .scheduleRunFrequency("Weekly")
 *                                 .scheduleRunTimes("2022-11-29T19:30:00.000Z")
 *                                 .build())
 *                             .tieringPolicy(Map.of("ArchivedRP", Map.ofEntries(
 *                                 Map.entry("duration", 45),
 *                                 Map.entry("durationType", "Days"),
 *                                 Map.entry("tieringMode", "TierAfter")
 *                             )))
 *                             .build(),
 *                         SubProtectionPolicyArgs.builder()
 *                             .policyType("Differential")
 *                             .retentionPolicy(SimpleRetentionPolicyArgs.builder()
 *                                 .retentionDuration(RetentionDurationArgs.builder()
 *                                     .count(30)
 *                                     .durationType("Days")
 *                                     .build())
 *                                 .retentionPolicyType("SimpleRetentionPolicy")
 *                                 .build())
 *                             .schedulePolicy(SimpleSchedulePolicyArgs.builder()
 *                                 .schedulePolicyType("SimpleSchedulePolicy")
 *                                 .scheduleRunDays("Monday")
 *                                 .scheduleRunFrequency("Weekly")
 *                                 .scheduleRunTimes("2022-09-29T02:00:00Z")
 *                                 .scheduleWeeklyFrequency(0)
 *                                 .build())
 *                             .build(),
 *                         SubProtectionPolicyArgs.builder()
 *                             .policyType("Log")
 *                             .retentionPolicy(SimpleRetentionPolicyArgs.builder()
 *                                 .retentionDuration(RetentionDurationArgs.builder()
 *                                     .count(20)
 *                                     .durationType("Days")
 *                                     .build())
 *                                 .retentionPolicyType("SimpleRetentionPolicy")
 *                                 .build())
 *                             .schedulePolicy(LogSchedulePolicyArgs.builder()
 *                                 .scheduleFrequencyInMins(120)
 *                                 .schedulePolicyType("LogSchedulePolicy")
 *                                 .build())
 *                             .build())
 *                     .workLoadType("SQLDataBase")
 *                     .build())
 *                 .backupType("SQL")
 *                 .recoveryServicesVault(NewRecoveryServicesVaultArgs.builder()
 *                     .name("test-vault")
 *                     .resourceGroup("test-rg")
 *                     .vaultType("New")
 *                     .build())
 *                 .build())
 *             .backupName("dbBackup")
 *             .connectorName("C1")
 *             .location("westcentralus")
 *             .resourceGroupName("test-rg")
 *             .tags()
 *             .build());
 * 
 *     }
 * }
 * 
 * }
 * 
* ### Create a VM backup connection with a new backup policy with tieringPolicy. * *
 * {@code
 * package generated_program;
 * 
 * import com.pulumi.Context;
 * import com.pulumi.Pulumi;
 * import com.pulumi.core.Output;
 * import com.pulumi.azurenative.workloads.ACSSBackupConnection;
 * import com.pulumi.azurenative.workloads.ACSSBackupConnectionArgs;
 * import java.util.List;
 * import java.util.ArrayList;
 * import java.util.Map;
 * import java.io.File;
 * import java.nio.file.Files;
 * import java.nio.file.Paths;
 * 
 * public class App {
 *     public static void main(String[] args) {
 *         Pulumi.run(App::stack);
 *     }
 * 
 *     public static void stack(Context ctx) {
 *         var acssBackupConnection = new ACSSBackupConnection("acssBackupConnection", ACSSBackupConnectionArgs.builder()
 *             .backupData(VMBackupDataArgs.builder()
 *                 .backupPolicy(VMBackupPolicyPropertiesArgs.builder()
 *                     .backupManagementType("AzureIaasVM")
 *                     .instantRPDetails(InstantRPAdditionalDetailsArgs.builder()
 *                         .azureBackupRGNamePrefix("dasas")
 *                         .azureBackupRGNameSuffix("a")
 *                         .build())
 *                     .instantRpRetentionRangeInDays(2)
 *                     .name("defaultVmPolicy")
 *                     .policyType("V1")
 *                     .protectedItemsCount(0)
 *                     .retentionPolicy(LongTermRetentionPolicyArgs.builder()
 *                         .dailySchedule(DailyRetentionScheduleArgs.builder()
 *                             .retentionDuration(RetentionDurationArgs.builder()
 *                                 .count(30)
 *                                 .durationType("Days")
 *                                 .build())
 *                             .retentionTimes("2022-11-29T19:30:00.000Z")
 *                             .build())
 *                         .monthlySchedule(MonthlyRetentionScheduleArgs.builder()
 *                             .retentionDuration(RetentionDurationArgs.builder()
 *                                 .count(60)
 *                                 .durationType("Months")
 *                                 .build())
 *                             .retentionScheduleFormatType("Weekly")
 *                             .retentionScheduleWeekly(WeeklyRetentionFormatArgs.builder()
 *                                 .daysOfTheWeek("Sunday")
 *                                 .weeksOfTheMonth("First")
 *                                 .build())
 *                             .retentionTimes("2022-11-29T19:30:00.000Z")
 *                             .build())
 *                         .retentionPolicyType("LongTermRetentionPolicy")
 *                         .weeklySchedule(WeeklyRetentionScheduleArgs.builder()
 *                             .daysOfTheWeek("Sunday")
 *                             .retentionDuration(RetentionDurationArgs.builder()
 *                                 .count(12)
 *                                 .durationType("Weeks")
 *                                 .build())
 *                             .retentionTimes("2022-11-29T19:30:00.000Z")
 *                             .build())
 *                         .yearlySchedule(YearlyRetentionScheduleArgs.builder()
 *                             .monthsOfYear("January")
 *                             .retentionDuration(RetentionDurationArgs.builder()
 *                                 .count(10)
 *                                 .durationType("Years")
 *                                 .build())
 *                             .retentionScheduleFormatType("Weekly")
 *                             .retentionScheduleWeekly(WeeklyRetentionFormatArgs.builder()
 *                                 .daysOfTheWeek("Sunday")
 *                                 .weeksOfTheMonth("First")
 *                                 .build())
 *                             .retentionTimes("2022-11-29T19:30:00.000Z")
 *                             .build())
 *                         .build())
 *                     .schedulePolicy(SimpleSchedulePolicyArgs.builder()
 *                         .schedulePolicyType("SimpleSchedulePolicy")
 *                         .scheduleRunFrequency("Daily")
 *                         .scheduleRunTimes("2022-11-29T19:30:00.000Z")
 *                         .build())
 *                     .tieringPolicy(Map.of("ArchivedRP", Map.ofEntries(
 *                         Map.entry("duration", 3),
 *                         Map.entry("durationType", "Months"),
 *                         Map.entry("tieringMode", "TierAfter")
 *                     )))
 *                     .timeZone("UTC")
 *                     .build())
 *                 .backupType("VM")
 *                 .diskExclusionProperties(DiskExclusionPropertiesArgs.builder()
 *                     .diskLunList()
 *                     .isInclusionList(true)
 *                     .build())
 *                 .recoveryServicesVault(NewRecoveryServicesVaultArgs.builder()
 *                     .name("test-vault")
 *                     .resourceGroup("test-rg")
 *                     .vaultType("New")
 *                     .build())
 *                 .build())
 *             .backupName("vmBackup")
 *             .connectorName("C1")
 *             .location("westcentralus")
 *             .resourceGroupName("test-rg")
 *             .tags()
 *             .build());
 * 
 *     }
 * }
 * 
 * }
 * 
* ### Create a db backup connection with a new backup policy. * *
 * {@code
 * package generated_program;
 * 
 * import com.pulumi.Context;
 * import com.pulumi.Pulumi;
 * import com.pulumi.core.Output;
 * import com.pulumi.azurenative.workloads.ACSSBackupConnection;
 * import com.pulumi.azurenative.workloads.ACSSBackupConnectionArgs;
 * import java.util.List;
 * import java.util.ArrayList;
 * import java.util.Map;
 * import java.io.File;
 * import java.nio.file.Files;
 * import java.nio.file.Paths;
 * 
 * public class App {
 *     public static void main(String[] args) {
 *         Pulumi.run(App::stack);
 *     }
 * 
 *     public static void stack(Context ctx) {
 *         var acssBackupConnection = new ACSSBackupConnection("acssBackupConnection", ACSSBackupConnectionArgs.builder()
 *             .backupData(HanaBackupDataArgs.builder()
 *                 .backupPolicy(DBBackupPolicyPropertiesArgs.builder()
 *                     .backupManagementType("AzureWorkload")
 *                     .name("defaultDbPolicy")
 *                     .protectedItemsCount(0)
 *                     .settings(SettingsArgs.builder()
 *                         .isCompression(false)
 *                         .issqlcompression(false)
 *                         .timeZone("UTC")
 *                         .build())
 *                     .subProtectionPolicy(                    
 *                         SubProtectionPolicyArgs.builder()
 *                             .policyType("Full")
 *                             .retentionPolicy(LongTermRetentionPolicyArgs.builder()
 *                                 .dailySchedule(DailyRetentionScheduleArgs.builder()
 *                                     .retentionDuration(RetentionDurationArgs.builder()
 *                                         .count(30)
 *                                         .durationType("Days")
 *                                         .build())
 *                                     .retentionTimes("2018-01-10T18:30:00Z")
 *                                     .build())
 *                                 .retentionPolicyType("LongTermRetentionPolicy")
 *                                 .build())
 *                             .schedulePolicy(SimpleSchedulePolicyArgs.builder()
 *                                 .schedulePolicyType("SimpleSchedulePolicy")
 *                                 .scheduleRunFrequency("Daily")
 *                                 .scheduleRunTimes("2018-01-10T18:30:00Z")
 *                                 .scheduleWeeklyFrequency(0)
 *                                 .build())
 *                             .build(),
 *                         SubProtectionPolicyArgs.builder()
 *                             .policyType("Log")
 *                             .retentionPolicy(SimpleRetentionPolicyArgs.builder()
 *                                 .retentionDuration(RetentionDurationArgs.builder()
 *                                     .count(30)
 *                                     .durationType("Days")
 *                                     .build())
 *                                 .retentionPolicyType("SimpleRetentionPolicy")
 *                                 .build())
 *                             .schedulePolicy(LogSchedulePolicyArgs.builder()
 *                                 .scheduleFrequencyInMins(60)
 *                                 .schedulePolicyType("LogSchedulePolicy")
 *                                 .build())
 *                             .build())
 *                     .workLoadType("SQLDataBase")
 *                     .build())
 *                 .backupType("SQL")
 *                 .recoveryServicesVault(ExistingRecoveryServicesVaultArgs.builder()
 *                     .id("/subscriptions/6d875e77-e412-4d7d-9af4-8895278b4443/resourceGroups/test-rg/providers/Microsoft.RecoveryServices/vaults/test-vault")
 *                     .vaultType("Existing")
 *                     .build())
 *                 .build())
 *             .backupName("dbBackup")
 *             .connectorName("C1")
 *             .location("westcentralus")
 *             .resourceGroupName("test-rg")
 *             .tags()
 *             .build());
 * 
 *     }
 * }
 * 
 * }
 * 
* ### Create a db backup connection with an existing backup policy. * *
 * {@code
 * package generated_program;
 * 
 * import com.pulumi.Context;
 * import com.pulumi.Pulumi;
 * import com.pulumi.core.Output;
 * import com.pulumi.azurenative.workloads.ACSSBackupConnection;
 * import com.pulumi.azurenative.workloads.ACSSBackupConnectionArgs;
 * import java.util.List;
 * import java.util.ArrayList;
 * import java.util.Map;
 * import java.io.File;
 * import java.nio.file.Files;
 * import java.nio.file.Paths;
 * 
 * public class App {
 *     public static void main(String[] args) {
 *         Pulumi.run(App::stack);
 *     }
 * 
 *     public static void stack(Context ctx) {
 *         var acssBackupConnection = new ACSSBackupConnection("acssBackupConnection", ACSSBackupConnectionArgs.builder()
 *             .backupData(HanaBackupDataArgs.builder()
 *                 .backupPolicy(DBBackupPolicyPropertiesArgs.builder()
 *                     .name("defaultDbPolicy")
 *                     .build())
 *                 .backupType("SQL")
 *                 .recoveryServicesVault(ExistingRecoveryServicesVaultArgs.builder()
 *                     .id("/subscriptions/6d875e77-e412-4d7d-9af4-8895278b4443/resourceGroups/test-rg/providers/Microsoft.RecoveryServices/vaults/test-vault")
 *                     .vaultType("Existing")
 *                     .build())
 *                 .build())
 *             .backupName("dbBackup")
 *             .connectorName("C1")
 *             .location("westcentralus")
 *             .resourceGroupName("test-rg")
 *             .tags()
 *             .build());
 * 
 *     }
 * }
 * 
 * }
 * 
* ### Create a vm backup connection with a new backup policy. * *
 * {@code
 * package generated_program;
 * 
 * import com.pulumi.Context;
 * import com.pulumi.Pulumi;
 * import com.pulumi.core.Output;
 * import com.pulumi.azurenative.workloads.ACSSBackupConnection;
 * import com.pulumi.azurenative.workloads.ACSSBackupConnectionArgs;
 * import java.util.List;
 * import java.util.ArrayList;
 * import java.util.Map;
 * import java.io.File;
 * import java.nio.file.Files;
 * import java.nio.file.Paths;
 * 
 * public class App {
 *     public static void main(String[] args) {
 *         Pulumi.run(App::stack);
 *     }
 * 
 *     public static void stack(Context ctx) {
 *         var acssBackupConnection = new ACSSBackupConnection("acssBackupConnection", ACSSBackupConnectionArgs.builder()
 *             .backupData(VMBackupDataArgs.builder()
 *                 .backupPolicy(VMBackupPolicyPropertiesArgs.builder()
 *                     .backupManagementType("AzureIaasVM")
 *                     .instantRPDetails()
 *                     .instantRpRetentionRangeInDays(2)
 *                     .name("defaultVmPolicy")
 *                     .protectedItemsCount(0)
 *                     .retentionPolicy(LongTermRetentionPolicyArgs.builder()
 *                         .dailySchedule(DailyRetentionScheduleArgs.builder()
 *                             .retentionDuration(RetentionDurationArgs.builder()
 *                                 .count(30)
 *                                 .durationType("Days")
 *                                 .build())
 *                             .retentionTimes("2018-01-10T18:30:00Z")
 *                             .build())
 *                         .retentionPolicyType("LongTermRetentionPolicy")
 *                         .build())
 *                     .schedulePolicy(SimpleSchedulePolicyArgs.builder()
 *                         .schedulePolicyType("SimpleSchedulePolicy")
 *                         .scheduleRunFrequency("Daily")
 *                         .scheduleRunTimes("2018-01-10T18:30:00Z")
 *                         .scheduleWeeklyFrequency(0)
 *                         .build())
 *                     .build())
 *                 .backupType("VM")
 *                 .diskExclusionProperties(DiskExclusionPropertiesArgs.builder()
 *                     .diskLunList()
 *                     .isInclusionList(true)
 *                     .build())
 *                 .recoveryServicesVault(NewRecoveryServicesVaultArgs.builder()
 *                     .name("test-vault")
 *                     .resourceGroup("test-rg")
 *                     .vaultType("New")
 *                     .build())
 *                 .build())
 *             .backupName("vmBackup")
 *             .connectorName("C1")
 *             .location("westcentralus")
 *             .resourceGroupName("test-rg")
 *             .tags()
 *             .build());
 * 
 *     }
 * }
 * 
 * }
 * 
* ### Create a vm backup connection with an existing backup policy. * *
 * {@code
 * package generated_program;
 * 
 * import com.pulumi.Context;
 * import com.pulumi.Pulumi;
 * import com.pulumi.core.Output;
 * import com.pulumi.azurenative.workloads.ACSSBackupConnection;
 * import com.pulumi.azurenative.workloads.ACSSBackupConnectionArgs;
 * import java.util.List;
 * import java.util.ArrayList;
 * import java.util.Map;
 * import java.io.File;
 * import java.nio.file.Files;
 * import java.nio.file.Paths;
 * 
 * public class App {
 *     public static void main(String[] args) {
 *         Pulumi.run(App::stack);
 *     }
 * 
 *     public static void stack(Context ctx) {
 *         var acssBackupConnection = new ACSSBackupConnection("acssBackupConnection", ACSSBackupConnectionArgs.builder()
 *             .backupData(VMBackupDataArgs.builder()
 *                 .backupPolicy(VMBackupPolicyPropertiesArgs.builder()
 *                     .name("defaultVmPolicy")
 *                     .build())
 *                 .backupType("VM")
 *                 .diskExclusionProperties(DiskExclusionPropertiesArgs.builder()
 *                     .diskLunList()
 *                     .isInclusionList(true)
 *                     .build())
 *                 .recoveryServicesVault(ExistingRecoveryServicesVaultArgs.builder()
 *                     .id("/subscriptions/6d875e77-e412-4d7d-9af4-8895278b4443/resourceGroups/test-rg/providers/Microsoft.RecoveryServices/vaults/test-vault")
 *                     .vaultType("Existing")
 *                     .build())
 *                 .build())
 *             .backupName("vmBackup")
 *             .connectorName("C1")
 *             .location("westcentralus")
 *             .resourceGroupName("test-rg")
 *             .tags()
 *             .build());
 * 
 *     }
 * }
 * 
 * }
 * 
* * ## Import * * An existing resource can be imported using its type token, name, and identifier, e.g. * * ```sh * $ pulumi import azure-native:workloads:ACSSBackupConnection db1 /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Workloads/connectors/{connectorName}/acssBackups/{backupName} * ``` * */ @ResourceType(type="azure-native:workloads:ACSSBackupConnection") public class ACSSBackupConnection extends com.pulumi.resources.CustomResource { /** * Information about the recovery services vault and backup policy used for backup. * */ @Export(name="backupData", refs={Object.class}, tree="[0]") private Output backupData; /** * @return Information about the recovery services vault and backup policy used for backup. * */ public Output> backupData() { return Codegen.optional(this.backupData); } /** * Defines the errors related to backup connection resource of virtual instance for SAP. * */ @Export(name="errors", refs={ConnectorErrorDefinitionResponse.class}, tree="[0]") private Output errors; /** * @return Defines the errors related to backup connection resource of virtual instance for SAP. * */ public Output errors() { return this.errors; } /** * The geo-location where the resource lives * */ @Export(name="location", refs={String.class}, tree="[0]") private Output location; /** * @return The geo-location where the resource lives * */ public Output location() { return this.location; } /** * The name of the resource * */ @Export(name="name", refs={String.class}, tree="[0]") private Output name; /** * @return The name of the resource * */ public Output name() { return this.name; } /** * Defines the provisioning states. * */ @Export(name="provisioningState", refs={String.class}, tree="[0]") private Output provisioningState; /** * @return Defines the provisioning states. * */ public Output provisioningState() { return this.provisioningState; } /** * Azure Resource Manager metadata containing createdBy and modifiedBy information. * */ @Export(name="systemData", refs={SystemDataResponse.class}, tree="[0]") private Output systemData; /** * @return Azure Resource Manager metadata containing createdBy and modifiedBy information. * */ public Output systemData() { return this.systemData; } /** * Resource tags. * */ @Export(name="tags", refs={Map.class,String.class}, tree="[0,1,1]") private Output> tags; /** * @return Resource tags. * */ public Output>> tags() { return Codegen.optional(this.tags); } /** * The type of the resource. E.g. "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts" * */ @Export(name="type", refs={String.class}, tree="[0]") private Output type; /** * @return The type of the resource. E.g. "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts" * */ public Output type() { return this.type; } /** * * @param name The _unique_ name of the resulting resource. */ public ACSSBackupConnection(java.lang.String name) { this(name, ACSSBackupConnectionArgs.Empty); } /** * * @param name The _unique_ name of the resulting resource. * @param args The arguments to use to populate this resource's properties. */ public ACSSBackupConnection(java.lang.String name, ACSSBackupConnectionArgs args) { this(name, args, null); } /** * * @param name The _unique_ name of the resulting resource. * @param args The arguments to use to populate this resource's properties. * @param options A bag of options that control this resource's behavior. */ public ACSSBackupConnection(java.lang.String name, ACSSBackupConnectionArgs args, @Nullable com.pulumi.resources.CustomResourceOptions options) { super("azure-native:workloads:ACSSBackupConnection", name, makeArgs(args, options), makeResourceOptions(options, Codegen.empty()), false); } private ACSSBackupConnection(java.lang.String name, Output id, @Nullable com.pulumi.resources.CustomResourceOptions options) { super("azure-native:workloads:ACSSBackupConnection", name, null, makeResourceOptions(options, id), false); } private static ACSSBackupConnectionArgs makeArgs(ACSSBackupConnectionArgs args, @Nullable com.pulumi.resources.CustomResourceOptions options) { if (options != null && options.getUrn().isPresent()) { return null; } return args == null ? ACSSBackupConnectionArgs.Empty : args; } private static com.pulumi.resources.CustomResourceOptions makeResourceOptions(@Nullable com.pulumi.resources.CustomResourceOptions options, @Nullable Output id) { var defaultOptions = com.pulumi.resources.CustomResourceOptions.builder() .version(Utilities.getVersion()) .aliases(List.of( Output.of(Alias.builder().type("azure-native:workloads/v20231001preview:ACSSBackupConnection").build()) )) .build(); return com.pulumi.resources.CustomResourceOptions.merge(defaultOptions, options, id); } /** * Get an existing Host 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 options Optional settings to control the behavior of the CustomResource. */ public static ACSSBackupConnection get(java.lang.String name, Output id, @Nullable com.pulumi.resources.CustomResourceOptions options) { return new ACSSBackupConnection(name, id, options); } }




© 2015 - 2024 Weber Informatics LLC | Privacy Policy