Alibaba Cloud

v3.28.0 published on Tuesday, Aug 16, 2022 by Pulumi

getHanaBackupPlans

This data source provides the Hbr Hana Backup Plans of the current Alibaba Cloud user.

NOTE: Available in v1.179.0+.

Example Usage

using Pulumi;
using AliCloud = Pulumi.AliCloud;

class MyStack : Stack
{
    public MyStack()
    {
        var ids = Output.Create(AliCloud.Hbr.GetHanaBackupPlans.InvokeAsync(new AliCloud.Hbr.GetHanaBackupPlansArgs
        {
            ClusterId = "example_value",
            Ids = 
            {
                "example_value-1",
                "example_value-2",
            },
        }));
        this.HbrHanaBackupPlanId1 = ids.Apply(ids => ids.Plans?[0]?.Id);
    }

    [Output("hbrHanaBackupPlanId1")]
    public Output<string> HbrHanaBackupPlanId1 { get; set; }
}
package main

import (
	"github.com/pulumi/pulumi-alicloud/sdk/v3/go/alicloud/hbr"
	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)

func main() {
	pulumi.Run(func(ctx *pulumi.Context) error {
		ids, err := hbr.GetHanaBackupPlans(ctx, &hbr.GetHanaBackupPlansArgs{
			ClusterId: "example_value",
			Ids: []string{
				"example_value-1",
				"example_value-2",
			},
		}, nil)
		if err != nil {
			return err
		}
		ctx.Export("hbrHanaBackupPlanId1", ids.Plans[0].Id)
		return nil
	})
}
package generated_program;

import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.alicloud.hbr.HbrFunctions;
import com.pulumi.alicloud.hbr.inputs.GetHanaBackupPlansArgs;
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) {
        final var ids = HbrFunctions.getHanaBackupPlans(GetHanaBackupPlansArgs.builder()
            .clusterId("example_value")
            .ids(            
                "example_value-1",
                "example_value-2")
            .build());

        ctx.export("hbrHanaBackupPlanId1", ids.applyValue(getHanaBackupPlansResult -> getHanaBackupPlansResult.plans()[0].id()));
    }
}
import pulumi
import pulumi_alicloud as alicloud

ids = alicloud.hbr.get_hana_backup_plans(cluster_id="example_value",
    ids=[
        "example_value-1",
        "example_value-2",
    ])
pulumi.export("hbrHanaBackupPlanId1", ids.plans[0].id)
import * as pulumi from "@pulumi/pulumi";
import * as alicloud from "@pulumi/alicloud";

const ids = alicloud.hbr.getHanaBackupPlans({
    clusterId: "example_value",
    ids: [
        "example_value-1",
        "example_value-2",
    ],
});
export const hbrHanaBackupPlanId1 = ids.then(ids => ids.plans?[0]?.id);
variables:
  ids:
    Fn::Invoke:
      Function: alicloud:hbr:getHanaBackupPlans
      Arguments:
        clusterId: example_value
        ids:
          - example_value-1
          - example_value-2
outputs:
  hbrHanaBackupPlanId1: ${ids.plans[0].id}

Using getHanaBackupPlans

Two invocation forms are available. The direct form accepts plain arguments and either blocks until the result value is available, or returns a Promise-wrapped result. The output form accepts Input-wrapped arguments and returns an Output-wrapped result.

function getHanaBackupPlans(args: GetHanaBackupPlansArgs, opts?: InvokeOptions): Promise<GetHanaBackupPlansResult>
function getHanaBackupPlansOutput(args: GetHanaBackupPlansOutputArgs, opts?: InvokeOptions): Output<GetHanaBackupPlansResult>
def get_hana_backup_plans(cluster_id: Optional[str] = None,
                          database_name: Optional[str] = None,
                          ids: Optional[Sequence[str]] = None,
                          name_regex: Optional[str] = None,
                          output_file: Optional[str] = None,
                          page_number: Optional[int] = None,
                          page_size: Optional[int] = None,
                          vault_id: Optional[str] = None,
                          opts: Optional[InvokeOptions] = None) -> GetHanaBackupPlansResult
def get_hana_backup_plans_output(cluster_id: Optional[pulumi.Input[str]] = None,
                          database_name: Optional[pulumi.Input[str]] = None,
                          ids: Optional[pulumi.Input[Sequence[pulumi.Input[str]]]] = None,
                          name_regex: Optional[pulumi.Input[str]] = None,
                          output_file: Optional[pulumi.Input[str]] = None,
                          page_number: Optional[pulumi.Input[int]] = None,
                          page_size: Optional[pulumi.Input[int]] = None,
                          vault_id: Optional[pulumi.Input[str]] = None,
                          opts: Optional[InvokeOptions] = None) -> Output[GetHanaBackupPlansResult]
func GetHanaBackupPlans(ctx *Context, args *GetHanaBackupPlansArgs, opts ...InvokeOption) (*GetHanaBackupPlansResult, error)
func GetHanaBackupPlansOutput(ctx *Context, args *GetHanaBackupPlansOutputArgs, opts ...InvokeOption) GetHanaBackupPlansResultOutput

> Note: This function is named GetHanaBackupPlans in the Go SDK.

public static class GetHanaBackupPlans 
{
    public static Task<GetHanaBackupPlansResult> InvokeAsync(GetHanaBackupPlansArgs args, InvokeOptions? opts = null)
    public static Output<GetHanaBackupPlansResult> Invoke(GetHanaBackupPlansInvokeArgs args, InvokeOptions? opts = null)
}
public static CompletableFuture<GetHanaBackupPlansResult> getHanaBackupPlans(GetHanaBackupPlansArgs args, InvokeOptions options)
// Output-based functions aren't available in Java yet
Fn::Invoke:
  Function: alicloud:hbr/getHanaBackupPlans:getHanaBackupPlans
  Arguments:
    # Arguments dictionary

The following arguments are supported:

ClusterId string

The ID of the SAP HANA instance.

DatabaseName string

The name of the database.

Ids List<string>

A list of Hana Backup Plan IDs.

NameRegex string

A regex string to filter results by Hana Backup Plan name.

OutputFile string
PageNumber int
PageSize int
VaultId string

The ID of the backup vault.

ClusterId string

The ID of the SAP HANA instance.

DatabaseName string

The name of the database.

Ids []string

A list of Hana Backup Plan IDs.

NameRegex string

A regex string to filter results by Hana Backup Plan name.

OutputFile string
PageNumber int
PageSize int
VaultId string

The ID of the backup vault.

clusterId String

The ID of the SAP HANA instance.

databaseName String

The name of the database.

ids List<String>

A list of Hana Backup Plan IDs.

nameRegex String

A regex string to filter results by Hana Backup Plan name.

outputFile String
pageNumber Integer
pageSize Integer
vaultId String

The ID of the backup vault.

clusterId string

The ID of the SAP HANA instance.

databaseName string

The name of the database.

ids string[]

A list of Hana Backup Plan IDs.

nameRegex string

A regex string to filter results by Hana Backup Plan name.

outputFile string
pageNumber number
pageSize number
vaultId string

The ID of the backup vault.

cluster_id str

The ID of the SAP HANA instance.

database_name str

The name of the database.

ids Sequence[str]

A list of Hana Backup Plan IDs.

name_regex str

A regex string to filter results by Hana Backup Plan name.

output_file str
page_number int
page_size int
vault_id str

The ID of the backup vault.

clusterId String

The ID of the SAP HANA instance.

databaseName String

The name of the database.

ids List<String>

A list of Hana Backup Plan IDs.

nameRegex String

A regex string to filter results by Hana Backup Plan name.

outputFile String
pageNumber Number
pageSize Number
vaultId String

The ID of the backup vault.

getHanaBackupPlans Result

The following output properties are available:

ClusterId string
Id string

The provider-assigned unique ID for this managed resource.

Ids List<string>
Names List<string>
Plans List<Pulumi.AliCloud.Hbr.Outputs.GetHanaBackupPlansPlan>
DatabaseName string
NameRegex string
OutputFile string
PageNumber int
PageSize int
VaultId string
ClusterId string
Id string

The provider-assigned unique ID for this managed resource.

Ids []string
Names []string
Plans []GetHanaBackupPlansPlan
DatabaseName string
NameRegex string
OutputFile string
PageNumber int
PageSize int
VaultId string
clusterId String
id String

The provider-assigned unique ID for this managed resource.

ids List<String>
names List<String>
plans List<GetHanaBackupPlansPlan>
databaseName String
nameRegex String
outputFile String
pageNumber Integer
pageSize Integer
vaultId String
clusterId string
id string

The provider-assigned unique ID for this managed resource.

ids string[]
names string[]
plans GetHanaBackupPlansPlan[]
databaseName string
nameRegex string
outputFile string
pageNumber number
pageSize number
vaultId string
cluster_id str
id str

The provider-assigned unique ID for this managed resource.

ids Sequence[str]
names Sequence[str]
plans Sequence[GetHanaBackupPlansPlan]
database_name str
name_regex str
output_file str
page_number int
page_size int
vault_id str
clusterId String
id String

The provider-assigned unique ID for this managed resource.

ids List<String>
names List<String>
plans List<Property Map>
databaseName String
nameRegex String
outputFile String
pageNumber Number
pageSize Number
vaultId String

Supporting Types

GetHanaBackupPlansPlan

BackupPrefix string

The backup prefix.

BackupType string

The backup type.

ClusterId string

The ID of the SAP HANA instance.

DatabaseName string

The name of the database.

Id string

The ID of the resource.

PageTotal string
PlanId string

The ID of the backup plan.

PlanName string

The name of the backup plan.

Schedule string

The backup policy.

Status string

The status of the resource.

VaultId string

The ID of the backup vault.

BackupPrefix string

The backup prefix.

BackupType string

The backup type.

ClusterId string

The ID of the SAP HANA instance.

DatabaseName string

The name of the database.

Id string

The ID of the resource.

PageTotal string
PlanId string

The ID of the backup plan.

PlanName string

The name of the backup plan.

Schedule string

The backup policy.

Status string

The status of the resource.

VaultId string

The ID of the backup vault.

backupPrefix String

The backup prefix.

backupType String

The backup type.

clusterId String

The ID of the SAP HANA instance.

databaseName String

The name of the database.

id String

The ID of the resource.

pageTotal String
planId String

The ID of the backup plan.

planName String

The name of the backup plan.

schedule String

The backup policy.

status String

The status of the resource.

vaultId String

The ID of the backup vault.

backupPrefix string

The backup prefix.

backupType string

The backup type.

clusterId string

The ID of the SAP HANA instance.

databaseName string

The name of the database.

id string

The ID of the resource.

pageTotal string
planId string

The ID of the backup plan.

planName string

The name of the backup plan.

schedule string

The backup policy.

status string

The status of the resource.

vaultId string

The ID of the backup vault.

backup_prefix str

The backup prefix.

backup_type str

The backup type.

cluster_id str

The ID of the SAP HANA instance.

database_name str

The name of the database.

id str

The ID of the resource.

page_total str
plan_id str

The ID of the backup plan.

plan_name str

The name of the backup plan.

schedule str

The backup policy.

status str

The status of the resource.

vault_id str

The ID of the backup vault.

backupPrefix String

The backup prefix.

backupType String

The backup type.

clusterId String

The ID of the SAP HANA instance.

databaseName String

The name of the database.

id String

The ID of the resource.

pageTotal String
planId String

The ID of the backup plan.

planName String

The name of the backup plan.

schedule String

The backup policy.

status String

The status of the resource.

vaultId String

The ID of the backup vault.

Package Details

Repository
https://github.com/pulumi/pulumi-alicloud
License
Apache-2.0
Notes

This Pulumi package is based on the alicloud Terraform Provider.