![JAR search and dependency download from the Maven repository](/logo.png)
com.pulumi.azure.dataprotection.kotlin.BackupPolicyPostgresqlFlexibleServer.kt Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of pulumi-azure-kotlin Show documentation
Show all versions of pulumi-azure-kotlin Show documentation
Build cloud applications and infrastructure by combining the safety and reliability of infrastructure as code with the power of the Kotlin programming language.
@file:Suppress("NAME_SHADOWING", "DEPRECATION")
package com.pulumi.azure.dataprotection.kotlin
import com.pulumi.azure.dataprotection.kotlin.outputs.BackupPolicyPostgresqlFlexibleServerDefaultRetentionRule
import com.pulumi.azure.dataprotection.kotlin.outputs.BackupPolicyPostgresqlFlexibleServerRetentionRule
import com.pulumi.core.Output
import com.pulumi.kotlin.KotlinCustomResource
import com.pulumi.kotlin.PulumiTagMarker
import com.pulumi.kotlin.ResourceMapper
import com.pulumi.kotlin.options.CustomResourceOptions
import com.pulumi.kotlin.options.CustomResourceOptionsBuilder
import com.pulumi.resources.Resource
import kotlin.Boolean
import kotlin.String
import kotlin.Suppress
import kotlin.Unit
import kotlin.collections.List
import com.pulumi.azure.dataprotection.kotlin.outputs.BackupPolicyPostgresqlFlexibleServerDefaultRetentionRule.Companion.toKotlin as backupPolicyPostgresqlFlexibleServerDefaultRetentionRuleToKotlin
import com.pulumi.azure.dataprotection.kotlin.outputs.BackupPolicyPostgresqlFlexibleServerRetentionRule.Companion.toKotlin as backupPolicyPostgresqlFlexibleServerRetentionRuleToKotlin
/**
* Builder for [BackupPolicyPostgresqlFlexibleServer].
*/
@PulumiTagMarker
public class BackupPolicyPostgresqlFlexibleServerResourceBuilder internal constructor() {
public var name: String? = null
public var args: BackupPolicyPostgresqlFlexibleServerArgs =
BackupPolicyPostgresqlFlexibleServerArgs()
public var opts: CustomResourceOptions = CustomResourceOptions()
/**
* @param name The _unique_ name of the resulting resource.
*/
public fun name(`value`: String) {
this.name = value
}
/**
* @param block The arguments to use to populate this resource's properties.
*/
public suspend fun args(block: suspend BackupPolicyPostgresqlFlexibleServerArgsBuilder.() -> Unit) {
val builder = BackupPolicyPostgresqlFlexibleServerArgsBuilder()
block(builder)
this.args = builder.build()
}
/**
* @param block A bag of options that control this resource's behavior.
*/
public suspend fun opts(block: suspend CustomResourceOptionsBuilder.() -> Unit) {
this.opts = com.pulumi.kotlin.options.CustomResourceOptions.opts(block)
}
internal fun build(): BackupPolicyPostgresqlFlexibleServer {
val builtJavaResource =
com.pulumi.azure.dataprotection.BackupPolicyPostgresqlFlexibleServer(
this.name,
this.args.toJava(),
this.opts.toJava(),
)
return BackupPolicyPostgresqlFlexibleServer(builtJavaResource)
}
}
/**
* Manages a Backup Policy to back up PostgreSQL Flexible Server.
* ## Example Usage
*
* ```typescript
* import * as pulumi from "@pulumi/pulumi";
* import * as azure from "@pulumi/azure";
* const example = new azure.core.ResourceGroup("example", {
* name: "example-resources",
* location: "West Europe",
* });
* const exampleBackupVault = new azure.dataprotection.BackupVault("example", {
* name: "example-backup-vault",
* resourceGroupName: example.name,
* location: example.location,
* datastoreType: "VaultStore",
* redundancy: "LocallyRedundant",
* identity: {
* type: "SystemAssigned",
* },
* });
* const exampleBackupPolicyPostgresqlFlexibleServer = new azure.dataprotection.BackupPolicyPostgresqlFlexibleServer("example", {
* name: "example-backup-policy",
* vaultId: exampleBackupVault.id,
* backupRepeatingTimeIntervals: ["R/2021-05-23T02:30:00+00:00/P1W"],
* timeZone: "India Standard Time",
* defaultRetentionRule: {
* lifeCycles: [{
* duration: "P4M",
* dataStoreType: "VaultStore",
* }],
* },
* retentionRules: [
* {
* name: "weekly",
* lifeCycles: [{
* duration: "P6M",
* dataStoreType: "VaultStore",
* }],
* priority: 20,
* criteria: {
* absoluteCriteria: "FirstOfWeek",
* },
* },
* {
* name: "thursday",
* lifeCycles: [{
* duration: "P1W",
* dataStoreType: "VaultStore",
* }],
* priority: 25,
* criteria: {
* daysOfWeeks: ["Thursday"],
* scheduledBackupTimes: ["2021-05-23T02:30:00Z"],
* },
* },
* {
* name: "monthly",
* lifeCycles: [{
* duration: "P1D",
* dataStoreType: "VaultStore",
* }],
* priority: 15,
* criteria: {
* weeksOfMonths: [
* "First",
* "Last",
* ],
* daysOfWeeks: ["Tuesday"],
* scheduledBackupTimes: ["2021-05-23T02:30:00Z"],
* },
* },
* ],
* });
* ```
* ```python
* import pulumi
* import pulumi_azure as azure
* example = azure.core.ResourceGroup("example",
* name="example-resources",
* location="West Europe")
* example_backup_vault = azure.dataprotection.BackupVault("example",
* name="example-backup-vault",
* resource_group_name=example.name,
* location=example.location,
* datastore_type="VaultStore",
* redundancy="LocallyRedundant",
* identity={
* "type": "SystemAssigned",
* })
* example_backup_policy_postgresql_flexible_server = azure.dataprotection.BackupPolicyPostgresqlFlexibleServer("example",
* name="example-backup-policy",
* vault_id=example_backup_vault.id,
* backup_repeating_time_intervals=["R/2021-05-23T02:30:00+00:00/P1W"],
* time_zone="India Standard Time",
* default_retention_rule={
* "life_cycles": [{
* "duration": "P4M",
* "data_store_type": "VaultStore",
* }],
* },
* retention_rules=[
* {
* "name": "weekly",
* "life_cycles": [{
* "duration": "P6M",
* "data_store_type": "VaultStore",
* }],
* "priority": 20,
* "criteria": {
* "absolute_criteria": "FirstOfWeek",
* },
* },
* {
* "name": "thursday",
* "life_cycles": [{
* "duration": "P1W",
* "data_store_type": "VaultStore",
* }],
* "priority": 25,
* "criteria": {
* "days_of_weeks": ["Thursday"],
* "scheduled_backup_times": ["2021-05-23T02:30:00Z"],
* },
* },
* {
* "name": "monthly",
* "life_cycles": [{
* "duration": "P1D",
* "data_store_type": "VaultStore",
* }],
* "priority": 15,
* "criteria": {
* "weeks_of_months": [
* "First",
* "Last",
* ],
* "days_of_weeks": ["Tuesday"],
* "scheduled_backup_times": ["2021-05-23T02:30:00Z"],
* },
* },
* ])
* ```
* ```csharp
* using System.Collections.Generic;
* using System.Linq;
* using Pulumi;
* using Azure = Pulumi.Azure;
* return await Deployment.RunAsync(() =>
* {
* var example = new Azure.Core.ResourceGroup("example", new()
* {
* Name = "example-resources",
* Location = "West Europe",
* });
* var exampleBackupVault = new Azure.DataProtection.BackupVault("example", new()
* {
* Name = "example-backup-vault",
* ResourceGroupName = example.Name,
* Location = example.Location,
* DatastoreType = "VaultStore",
* Redundancy = "LocallyRedundant",
* Identity = new Azure.DataProtection.Inputs.BackupVaultIdentityArgs
* {
* Type = "SystemAssigned",
* },
* });
* var exampleBackupPolicyPostgresqlFlexibleServer = new Azure.DataProtection.BackupPolicyPostgresqlFlexibleServer("example", new()
* {
* Name = "example-backup-policy",
* VaultId = exampleBackupVault.Id,
* BackupRepeatingTimeIntervals = new[]
* {
* "R/2021-05-23T02:30:00+00:00/P1W",
* },
* TimeZone = "India Standard Time",
* DefaultRetentionRule = new Azure.DataProtection.Inputs.BackupPolicyPostgresqlFlexibleServerDefaultRetentionRuleArgs
* {
* LifeCycles = new[]
* {
* new Azure.DataProtection.Inputs.BackupPolicyPostgresqlFlexibleServerDefaultRetentionRuleLifeCycleArgs
* {
* Duration = "P4M",
* DataStoreType = "VaultStore",
* },
* },
* },
* RetentionRules = new[]
* {
* new Azure.DataProtection.Inputs.BackupPolicyPostgresqlFlexibleServerRetentionRuleArgs
* {
* Name = "weekly",
* LifeCycles = new[]
* {
* new Azure.DataProtection.Inputs.BackupPolicyPostgresqlFlexibleServerRetentionRuleLifeCycleArgs
* {
* Duration = "P6M",
* DataStoreType = "VaultStore",
* },
* },
* Priority = 20,
* Criteria = new Azure.DataProtection.Inputs.BackupPolicyPostgresqlFlexibleServerRetentionRuleCriteriaArgs
* {
* AbsoluteCriteria = "FirstOfWeek",
* },
* },
* new Azure.DataProtection.Inputs.BackupPolicyPostgresqlFlexibleServerRetentionRuleArgs
* {
* Name = "thursday",
* LifeCycles = new[]
* {
* new Azure.DataProtection.Inputs.BackupPolicyPostgresqlFlexibleServerRetentionRuleLifeCycleArgs
* {
* Duration = "P1W",
* DataStoreType = "VaultStore",
* },
* },
* Priority = 25,
* Criteria = new Azure.DataProtection.Inputs.BackupPolicyPostgresqlFlexibleServerRetentionRuleCriteriaArgs
* {
* DaysOfWeeks = new[]
* {
* "Thursday",
* },
* ScheduledBackupTimes = new[]
* {
* "2021-05-23T02:30:00Z",
* },
* },
* },
* new Azure.DataProtection.Inputs.BackupPolicyPostgresqlFlexibleServerRetentionRuleArgs
* {
* Name = "monthly",
* LifeCycles = new[]
* {
* new Azure.DataProtection.Inputs.BackupPolicyPostgresqlFlexibleServerRetentionRuleLifeCycleArgs
* {
* Duration = "P1D",
* DataStoreType = "VaultStore",
* },
* },
* Priority = 15,
* Criteria = new Azure.DataProtection.Inputs.BackupPolicyPostgresqlFlexibleServerRetentionRuleCriteriaArgs
* {
* WeeksOfMonths = new[]
* {
* "First",
* "Last",
* },
* DaysOfWeeks = new[]
* {
* "Tuesday",
* },
* ScheduledBackupTimes = new[]
* {
* "2021-05-23T02:30:00Z",
* },
* },
* },
* },
* });
* });
* ```
* ```go
* package main
* import (
* "github.com/pulumi/pulumi-azure/sdk/v5/go/azure/core"
* "github.com/pulumi/pulumi-azure/sdk/v5/go/azure/dataprotection"
* "github.com/pulumi/pulumi/sdk/v3/go/pulumi"
* )
* func main() {
* pulumi.Run(func(ctx *pulumi.Context) error {
* example, err := core.NewResourceGroup(ctx, "example", &core.ResourceGroupArgs{
* Name: pulumi.String("example-resources"),
* Location: pulumi.String("West Europe"),
* })
* if err != nil {
* return err
* }
* exampleBackupVault, err := dataprotection.NewBackupVault(ctx, "example", &dataprotection.BackupVaultArgs{
* Name: pulumi.String("example-backup-vault"),
* ResourceGroupName: example.Name,
* Location: example.Location,
* DatastoreType: pulumi.String("VaultStore"),
* Redundancy: pulumi.String("LocallyRedundant"),
* Identity: &dataprotection.BackupVaultIdentityArgs{
* Type: pulumi.String("SystemAssigned"),
* },
* })
* if err != nil {
* return err
* }
* _, err = dataprotection.NewBackupPolicyPostgresqlFlexibleServer(ctx, "example", &dataprotection.BackupPolicyPostgresqlFlexibleServerArgs{
* Name: pulumi.String("example-backup-policy"),
* VaultId: exampleBackupVault.ID(),
* BackupRepeatingTimeIntervals: pulumi.StringArray{
* pulumi.String("R/2021-05-23T02:30:00+00:00/P1W"),
* },
* TimeZone: pulumi.String("India Standard Time"),
* DefaultRetentionRule: &dataprotection.BackupPolicyPostgresqlFlexibleServerDefaultRetentionRuleArgs{
* LifeCycles: dataprotection.BackupPolicyPostgresqlFlexibleServerDefaultRetentionRuleLifeCycleArray{
* &dataprotection.BackupPolicyPostgresqlFlexibleServerDefaultRetentionRuleLifeCycleArgs{
* Duration: pulumi.String("P4M"),
* DataStoreType: pulumi.String("VaultStore"),
* },
* },
* },
* RetentionRules: dataprotection.BackupPolicyPostgresqlFlexibleServerRetentionRuleArray{
* &dataprotection.BackupPolicyPostgresqlFlexibleServerRetentionRuleArgs{
* Name: pulumi.String("weekly"),
* LifeCycles: dataprotection.BackupPolicyPostgresqlFlexibleServerRetentionRuleLifeCycleArray{
* &dataprotection.BackupPolicyPostgresqlFlexibleServerRetentionRuleLifeCycleArgs{
* Duration: pulumi.String("P6M"),
* DataStoreType: pulumi.String("VaultStore"),
* },
* },
* Priority: pulumi.Int(20),
* Criteria: &dataprotection.BackupPolicyPostgresqlFlexibleServerRetentionRuleCriteriaArgs{
* AbsoluteCriteria: pulumi.String("FirstOfWeek"),
* },
* },
* &dataprotection.BackupPolicyPostgresqlFlexibleServerRetentionRuleArgs{
* Name: pulumi.String("thursday"),
* LifeCycles: dataprotection.BackupPolicyPostgresqlFlexibleServerRetentionRuleLifeCycleArray{
* &dataprotection.BackupPolicyPostgresqlFlexibleServerRetentionRuleLifeCycleArgs{
* Duration: pulumi.String("P1W"),
* DataStoreType: pulumi.String("VaultStore"),
* },
* },
* Priority: pulumi.Int(25),
* Criteria: &dataprotection.BackupPolicyPostgresqlFlexibleServerRetentionRuleCriteriaArgs{
* DaysOfWeeks: pulumi.StringArray{
* pulumi.String("Thursday"),
* },
* ScheduledBackupTimes: pulumi.StringArray{
* pulumi.String("2021-05-23T02:30:00Z"),
* },
* },
* },
* &dataprotection.BackupPolicyPostgresqlFlexibleServerRetentionRuleArgs{
* Name: pulumi.String("monthly"),
* LifeCycles: dataprotection.BackupPolicyPostgresqlFlexibleServerRetentionRuleLifeCycleArray{
* &dataprotection.BackupPolicyPostgresqlFlexibleServerRetentionRuleLifeCycleArgs{
* Duration: pulumi.String("P1D"),
* DataStoreType: pulumi.String("VaultStore"),
* },
* },
* Priority: pulumi.Int(15),
* Criteria: &dataprotection.BackupPolicyPostgresqlFlexibleServerRetentionRuleCriteriaArgs{
* WeeksOfMonths: pulumi.StringArray{
* pulumi.String("First"),
* pulumi.String("Last"),
* },
* DaysOfWeeks: pulumi.StringArray{
* pulumi.String("Tuesday"),
* },
* ScheduledBackupTimes: pulumi.StringArray{
* pulumi.String("2021-05-23T02:30:00Z"),
* },
* },
* },
* },
* })
* if err != nil {
* return err
* }
* return nil
* })
* }
* ```
* ```java
* package generated_program;
* import com.pulumi.Context;
* import com.pulumi.Pulumi;
* import com.pulumi.core.Output;
* import com.pulumi.azure.core.ResourceGroup;
* import com.pulumi.azure.core.ResourceGroupArgs;
* import com.pulumi.azure.dataprotection.BackupVault;
* import com.pulumi.azure.dataprotection.BackupVaultArgs;
* import com.pulumi.azure.dataprotection.inputs.BackupVaultIdentityArgs;
* import com.pulumi.azure.dataprotection.BackupPolicyPostgresqlFlexibleServer;
* import com.pulumi.azure.dataprotection.BackupPolicyPostgresqlFlexibleServerArgs;
* import com.pulumi.azure.dataprotection.inputs.BackupPolicyPostgresqlFlexibleServerDefaultRetentionRuleArgs;
* import com.pulumi.azure.dataprotection.inputs.BackupPolicyPostgresqlFlexibleServerRetentionRuleArgs;
* import com.pulumi.azure.dataprotection.inputs.BackupPolicyPostgresqlFlexibleServerRetentionRuleCriteriaArgs;
* 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 example = new ResourceGroup("example", ResourceGroupArgs.builder()
* .name("example-resources")
* .location("West Europe")
* .build());
* var exampleBackupVault = new BackupVault("exampleBackupVault", BackupVaultArgs.builder()
* .name("example-backup-vault")
* .resourceGroupName(example.name())
* .location(example.location())
* .datastoreType("VaultStore")
* .redundancy("LocallyRedundant")
* .identity(BackupVaultIdentityArgs.builder()
* .type("SystemAssigned")
* .build())
* .build());
* var exampleBackupPolicyPostgresqlFlexibleServer = new BackupPolicyPostgresqlFlexibleServer("exampleBackupPolicyPostgresqlFlexibleServer", BackupPolicyPostgresqlFlexibleServerArgs.builder()
* .name("example-backup-policy")
* .vaultId(exampleBackupVault.id())
* .backupRepeatingTimeIntervals("R/2021-05-23T02:30:00+00:00/P1W")
* .timeZone("India Standard Time")
* .defaultRetentionRule(BackupPolicyPostgresqlFlexibleServerDefaultRetentionRuleArgs.builder()
* .lifeCycles(BackupPolicyPostgresqlFlexibleServerDefaultRetentionRuleLifeCycleArgs.builder()
* .duration("P4M")
* .dataStoreType("VaultStore")
* .build())
* .build())
* .retentionRules(
* BackupPolicyPostgresqlFlexibleServerRetentionRuleArgs.builder()
* .name("weekly")
* .lifeCycles(BackupPolicyPostgresqlFlexibleServerRetentionRuleLifeCycleArgs.builder()
* .duration("P6M")
* .dataStoreType("VaultStore")
* .build())
* .priority(20)
* .criteria(BackupPolicyPostgresqlFlexibleServerRetentionRuleCriteriaArgs.builder()
* .absoluteCriteria("FirstOfWeek")
* .build())
* .build(),
* BackupPolicyPostgresqlFlexibleServerRetentionRuleArgs.builder()
* .name("thursday")
* .lifeCycles(BackupPolicyPostgresqlFlexibleServerRetentionRuleLifeCycleArgs.builder()
* .duration("P1W")
* .dataStoreType("VaultStore")
* .build())
* .priority(25)
* .criteria(BackupPolicyPostgresqlFlexibleServerRetentionRuleCriteriaArgs.builder()
* .daysOfWeeks("Thursday")
* .scheduledBackupTimes("2021-05-23T02:30:00Z")
* .build())
* .build(),
* BackupPolicyPostgresqlFlexibleServerRetentionRuleArgs.builder()
* .name("monthly")
* .lifeCycles(BackupPolicyPostgresqlFlexibleServerRetentionRuleLifeCycleArgs.builder()
* .duration("P1D")
* .dataStoreType("VaultStore")
* .build())
* .priority(15)
* .criteria(BackupPolicyPostgresqlFlexibleServerRetentionRuleCriteriaArgs.builder()
* .weeksOfMonths(
* "First",
* "Last")
* .daysOfWeeks("Tuesday")
* .scheduledBackupTimes("2021-05-23T02:30:00Z")
* .build())
* .build())
* .build());
* }
* }
* ```
* ```yaml
* resources:
* example:
* type: azure:core:ResourceGroup
* properties:
* name: example-resources
* location: West Europe
* exampleBackupVault:
* type: azure:dataprotection:BackupVault
* name: example
* properties:
* name: example-backup-vault
* resourceGroupName: ${example.name}
* location: ${example.location}
* datastoreType: VaultStore
* redundancy: LocallyRedundant
* identity:
* type: SystemAssigned
* exampleBackupPolicyPostgresqlFlexibleServer:
* type: azure:dataprotection:BackupPolicyPostgresqlFlexibleServer
* name: example
* properties:
* name: example-backup-policy
* vaultId: ${exampleBackupVault.id}
* backupRepeatingTimeIntervals:
* - R/2021-05-23T02:30:00+00:00/P1W
* timeZone: India Standard Time
* defaultRetentionRule:
* lifeCycles:
* - duration: P4M
* dataStoreType: VaultStore
* retentionRules:
* - name: weekly
* lifeCycles:
* - duration: P6M
* dataStoreType: VaultStore
* priority: 20
* criteria:
* absoluteCriteria: FirstOfWeek
* - name: thursday
* lifeCycles:
* - duration: P1W
* dataStoreType: VaultStore
* priority: 25
* criteria:
* daysOfWeeks:
* - Thursday
* scheduledBackupTimes:
* - 2021-05-23T02:30:00Z
* - name: monthly
* lifeCycles:
* - duration: P1D
* dataStoreType: VaultStore
* priority: 15
* criteria:
* weeksOfMonths:
* - First
* - Last
* daysOfWeeks:
* - Tuesday
* scheduledBackupTimes:
* - 2021-05-23T02:30:00Z
* ```
*
* ## Import
* Backup Policy PostgreSQL Flexible Server's can be imported using the `resource id`, e.g.
* ```sh
* $ pulumi import azure:dataprotection/backupPolicyPostgresqlFlexibleServer:BackupPolicyPostgresqlFlexibleServer example /subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/group1/providers/Microsoft.DataProtection/backupVaults/vault1/backupPolicies/backupPolicy1
* ```
*/
public class BackupPolicyPostgresqlFlexibleServer internal constructor(
override val javaResource: com.pulumi.azure.dataprotection.BackupPolicyPostgresqlFlexibleServer,
) : KotlinCustomResource(javaResource, BackupPolicyPostgresqlFlexibleServerMapper) {
/**
* Specifies a list of repeating time interval. It supports weekly back. It should follow `ISO 8601` repeating time interval format. Changing this forces a new resource to be created.
*/
public val backupRepeatingTimeIntervals: Output>
get() = javaResource.backupRepeatingTimeIntervals().applyValue({ args0 ->
args0.map({ args0 ->
args0
})
})
/**
* A `default_retention_rule` block as defined below. Changing this forces a new resource to be created.
*/
public val defaultRetentionRule: Output
get() = javaResource.defaultRetentionRule().applyValue({ args0 ->
args0.let({ args0 ->
backupPolicyPostgresqlFlexibleServerDefaultRetentionRuleToKotlin(args0)
})
})
/**
* Specifies the name of the Backup Policy for the PostgreSQL Flexible Server. Changing this forces a new resource to be created.
*/
public val name: Output
get() = javaResource.name().applyValue({ args0 -> args0 })
/**
* One or more `retention_rule` blocks as defined below. Changing this forces a new resource to be created.
*/
public val retentionRules: Output>?
get() = javaResource.retentionRules().applyValue({ args0 ->
args0.map({ args0 ->
args0.map({ args0 ->
args0.let({ args0 ->
backupPolicyPostgresqlFlexibleServerRetentionRuleToKotlin(args0)
})
})
}).orElse(null)
})
/**
* Specifies the Time Zone which should be used by the backup schedule. Changing this forces a new resource to be created.
*/
public val timeZone: Output?
get() = javaResource.timeZone().applyValue({ args0 -> args0.map({ args0 -> args0 }).orElse(null) })
/**
* The ID of the Backup Vault where the Backup Policy PostgreSQL Flexible Server should exist. Changing this forces a new resource to be created.
*/
public val vaultId: Output
get() = javaResource.vaultId().applyValue({ args0 -> args0 })
}
public object BackupPolicyPostgresqlFlexibleServerMapper :
ResourceMapper {
override fun supportsMappingOfType(javaResource: Resource): Boolean =
com.pulumi.azure.dataprotection.BackupPolicyPostgresqlFlexibleServer::class == javaResource::class
override fun map(javaResource: Resource): BackupPolicyPostgresqlFlexibleServer =
BackupPolicyPostgresqlFlexibleServer(
javaResource as
com.pulumi.azure.dataprotection.BackupPolicyPostgresqlFlexibleServer,
)
}
/**
* @see [BackupPolicyPostgresqlFlexibleServer].
* @param name The _unique_ name of the resulting resource.
* @param block Builder for [BackupPolicyPostgresqlFlexibleServer].
*/
public suspend fun backupPolicyPostgresqlFlexibleServer(
name: String,
block: suspend BackupPolicyPostgresqlFlexibleServerResourceBuilder.() -> Unit,
): BackupPolicyPostgresqlFlexibleServer {
val builder = BackupPolicyPostgresqlFlexibleServerResourceBuilder()
builder.name(name)
block(builder)
return builder.build()
}
/**
* @see [BackupPolicyPostgresqlFlexibleServer].
* @param name The _unique_ name of the resulting resource.
*/
public fun backupPolicyPostgresqlFlexibleServer(name: String): BackupPolicyPostgresqlFlexibleServer {
val builder = BackupPolicyPostgresqlFlexibleServerResourceBuilder()
builder.name(name)
return builder.build()
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy