alicloud logo
Alibaba Cloud v3.29.0, Jan 20 23

alicloud.rds.getCrossRegionBackups

This data source provides the Rds Parameter Groups of the current Alibaba Cloud user.

NOTE: Available in v1.196.0+.

Example Usage

Basic Usage

using System.Collections.Generic;
using Pulumi;
using AliCloud = Pulumi.AliCloud;

return await Deployment.RunAsync(() => 
{
    var backups = AliCloud.Rds.GetCrossRegionBackups.Invoke(new()
    {
        DbInstanceId = "example_value",
        StartTime = "2022-12-01T00:00:00Z",
        EndTime = "2022-12-16T00:00:00Z",
    });

    return new Dictionary<string, object?>
    {
        ["firstRdsCrossRegionBackups"] = backups.Apply(getCrossRegionBackupsResult => getCrossRegionBackupsResult.Backups[0]?.Id),
    };
});
package main

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

func main() {
	pulumi.Run(func(ctx *pulumi.Context) error {
		backups, err := rds.GetCrossRegionBackups(ctx, &rds.GetCrossRegionBackupsArgs{
			DbInstanceId: "example_value",
			StartTime:    pulumi.StringRef("2022-12-01T00:00:00Z"),
			EndTime:      pulumi.StringRef("2022-12-16T00:00:00Z"),
		}, nil)
		if err != nil {
			return err
		}
		ctx.Export("firstRdsCrossRegionBackups", backups.Backups[0].Id)
		return nil
	})
}
package generated_program;

import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.alicloud.rds.RdsFunctions;
import com.pulumi.alicloud.rds.inputs.GetCrossRegionBackupsArgs;
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 backups = RdsFunctions.getCrossRegionBackups(GetCrossRegionBackupsArgs.builder()
            .dbInstanceId("example_value")
            .startTime("2022-12-01T00:00:00Z")
            .endTime("2022-12-16T00:00:00Z")
            .build());

        ctx.export("firstRdsCrossRegionBackups", backups.applyValue(getCrossRegionBackupsResult -> getCrossRegionBackupsResult.backups()[0].id()));
    }
}
import pulumi
import pulumi_alicloud as alicloud

backups = alicloud.rds.get_cross_region_backups(db_instance_id="example_value",
    start_time="2022-12-01T00:00:00Z",
    end_time="2022-12-16T00:00:00Z")
pulumi.export("firstRdsCrossRegionBackups", backups.backups[0].id)
import * as pulumi from "@pulumi/pulumi";
import * as alicloud from "@pulumi/alicloud";

const backups = alicloud.rds.getCrossRegionBackups({
    dbInstanceId: "example_value",
    startTime: "2022-12-01T00:00:00Z",
    endTime: "2022-12-16T00:00:00Z",
});
export const firstRdsCrossRegionBackups = backups.then(backups => backups.backups?.[0]?.id);
variables:
  backups:
    fn::invoke:
      Function: alicloud:rds:getCrossRegionBackups
      Arguments:
        dbInstanceId: example_value
        startTime: 2022-12-01T00:00:00Z
        endTime: 2022-12-16T00:00:00Z
outputs:
  firstRdsCrossRegionBackups: ${backups.backups[0].id}

Using getCrossRegionBackups

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 getCrossRegionBackups(args: GetCrossRegionBackupsArgs, opts?: InvokeOptions): Promise<GetCrossRegionBackupsResult>
function getCrossRegionBackupsOutput(args: GetCrossRegionBackupsOutputArgs, opts?: InvokeOptions): Output<GetCrossRegionBackupsResult>
def get_cross_region_backups(backup_id: Optional[str] = None,
                             cross_backup_id: Optional[str] = None,
                             cross_backup_region: Optional[str] = None,
                             db_instance_id: Optional[str] = None,
                             end_time: Optional[str] = None,
                             ids: Optional[Sequence[str]] = None,
                             output_file: Optional[str] = None,
                             resource_group_id: Optional[str] = None,
                             start_time: Optional[str] = None,
                             opts: Optional[InvokeOptions] = None) -> GetCrossRegionBackupsResult
def get_cross_region_backups_output(backup_id: Optional[pulumi.Input[str]] = None,
                             cross_backup_id: Optional[pulumi.Input[str]] = None,
                             cross_backup_region: Optional[pulumi.Input[str]] = None,
                             db_instance_id: Optional[pulumi.Input[str]] = None,
                             end_time: Optional[pulumi.Input[str]] = None,
                             ids: Optional[pulumi.Input[Sequence[pulumi.Input[str]]]] = None,
                             output_file: Optional[pulumi.Input[str]] = None,
                             resource_group_id: Optional[pulumi.Input[str]] = None,
                             start_time: Optional[pulumi.Input[str]] = None,
                             opts: Optional[InvokeOptions] = None) -> Output[GetCrossRegionBackupsResult]
func GetCrossRegionBackups(ctx *Context, args *GetCrossRegionBackupsArgs, opts ...InvokeOption) (*GetCrossRegionBackupsResult, error)
func GetCrossRegionBackupsOutput(ctx *Context, args *GetCrossRegionBackupsOutputArgs, opts ...InvokeOption) GetCrossRegionBackupsResultOutput

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

public static class GetCrossRegionBackups 
{
    public static Task<GetCrossRegionBackupsResult> InvokeAsync(GetCrossRegionBackupsArgs args, InvokeOptions? opts = null)
    public static Output<GetCrossRegionBackupsResult> Invoke(GetCrossRegionBackupsInvokeArgs args, InvokeOptions? opts = null)
}
public static CompletableFuture<GetCrossRegionBackupsResult> getCrossRegionBackups(GetCrossRegionBackupsArgs args, InvokeOptions options)
// Output-based functions aren't available in Java yet
fn::invoke:
  function: alicloud:rds/getCrossRegionBackups:getCrossRegionBackups
  arguments:
    # arguments dictionary

The following arguments are supported:

DbInstanceId string

The db instance id.

BackupId string

The ID of the cross-region data backup file.

CrossBackupId string

The ID of the cross-region data backup file.

CrossBackupRegion string

The ID of the destination region where the cross-region data backup file of the instance is stored.

EndTime string

The end of the time range to query. Specify the time in the ISO 8601 standard in the yyyy-MM-ddTHH:mm:ssZ format. The time must be in UTC.

Ids List<string>

A list of Cross Region Backup IDs.

OutputFile string
ResourceGroupId string

The ID of the resource group.

StartTime string

The beginning of the time range to query. Specify the time in the ISO 8601 standard in the yyyy-MM-ddTHH:mm:ssZ format. The time must be in UTC.

DbInstanceId string

The db instance id.

BackupId string

The ID of the cross-region data backup file.

CrossBackupId string

The ID of the cross-region data backup file.

CrossBackupRegion string

The ID of the destination region where the cross-region data backup file of the instance is stored.

EndTime string

The end of the time range to query. Specify the time in the ISO 8601 standard in the yyyy-MM-ddTHH:mm:ssZ format. The time must be in UTC.

Ids []string

A list of Cross Region Backup IDs.

OutputFile string
ResourceGroupId string

The ID of the resource group.

StartTime string

The beginning of the time range to query. Specify the time in the ISO 8601 standard in the yyyy-MM-ddTHH:mm:ssZ format. The time must be in UTC.

dbInstanceId String

The db instance id.

backupId String

The ID of the cross-region data backup file.

crossBackupId String

The ID of the cross-region data backup file.

crossBackupRegion String

The ID of the destination region where the cross-region data backup file of the instance is stored.

endTime String

The end of the time range to query. Specify the time in the ISO 8601 standard in the yyyy-MM-ddTHH:mm:ssZ format. The time must be in UTC.

ids List<String>

A list of Cross Region Backup IDs.

outputFile String
resourceGroupId String

The ID of the resource group.

startTime String

The beginning of the time range to query. Specify the time in the ISO 8601 standard in the yyyy-MM-ddTHH:mm:ssZ format. The time must be in UTC.

dbInstanceId string

The db instance id.

backupId string

The ID of the cross-region data backup file.

crossBackupId string

The ID of the cross-region data backup file.

crossBackupRegion string

The ID of the destination region where the cross-region data backup file of the instance is stored.

endTime string

The end of the time range to query. Specify the time in the ISO 8601 standard in the yyyy-MM-ddTHH:mm:ssZ format. The time must be in UTC.

ids string[]

A list of Cross Region Backup IDs.

outputFile string
resourceGroupId string

The ID of the resource group.

startTime string

The beginning of the time range to query. Specify the time in the ISO 8601 standard in the yyyy-MM-ddTHH:mm:ssZ format. The time must be in UTC.

db_instance_id str

The db instance id.

backup_id str

The ID of the cross-region data backup file.

cross_backup_id str

The ID of the cross-region data backup file.

cross_backup_region str

The ID of the destination region where the cross-region data backup file of the instance is stored.

end_time str

The end of the time range to query. Specify the time in the ISO 8601 standard in the yyyy-MM-ddTHH:mm:ssZ format. The time must be in UTC.

ids Sequence[str]

A list of Cross Region Backup IDs.

output_file str
resource_group_id str

The ID of the resource group.

start_time str

The beginning of the time range to query. Specify the time in the ISO 8601 standard in the yyyy-MM-ddTHH:mm:ssZ format. The time must be in UTC.

dbInstanceId String

The db instance id.

backupId String

The ID of the cross-region data backup file.

crossBackupId String

The ID of the cross-region data backup file.

crossBackupRegion String

The ID of the destination region where the cross-region data backup file of the instance is stored.

endTime String

The end of the time range to query. Specify the time in the ISO 8601 standard in the yyyy-MM-ddTHH:mm:ssZ format. The time must be in UTC.

ids List<String>

A list of Cross Region Backup IDs.

outputFile String
resourceGroupId String

The ID of the resource group.

startTime String

The beginning of the time range to query. Specify the time in the ISO 8601 standard in the yyyy-MM-ddTHH:mm:ssZ format. The time must be in UTC.

getCrossRegionBackups Result

The following output properties are available:

Backups List<Pulumi.AliCloud.Rds.Outputs.GetCrossRegionBackupsBackup>
DbInstanceId string
Id string

The provider-assigned unique ID for this managed resource.

Ids List<string>
BackupId string
CrossBackupId string
CrossBackupRegion string
EndTime string
OutputFile string
ResourceGroupId string
StartTime string
Backups []GetCrossRegionBackupsBackup
DbInstanceId string
Id string

The provider-assigned unique ID for this managed resource.

Ids []string
BackupId string
CrossBackupId string
CrossBackupRegion string
EndTime string
OutputFile string
ResourceGroupId string
StartTime string
backups List<GetCrossRegionBackupsBackup>
dbInstanceId String
id String

The provider-assigned unique ID for this managed resource.

ids List<String>
backupId String
crossBackupId String
crossBackupRegion String
endTime String
outputFile String
resourceGroupId String
startTime String
backups GetCrossRegionBackupsBackup[]
dbInstanceId string
id string

The provider-assigned unique ID for this managed resource.

ids string[]
backupId string
crossBackupId string
crossBackupRegion string
endTime string
outputFile string
resourceGroupId string
startTime string
backups Sequence[GetCrossRegionBackupsBackup]
db_instance_id str
id str

The provider-assigned unique ID for this managed resource.

ids Sequence[str]
backup_id str
cross_backup_id str
cross_backup_region str
end_time str
output_file str
resource_group_id str
start_time str
backups List<Property Map>
dbInstanceId String
id String

The provider-assigned unique ID for this managed resource.

ids List<String>
backupId String
crossBackupId String
crossBackupRegion String
endTime String
outputFile String
resourceGroupId String
startTime String

Supporting Types

GetCrossRegionBackupsBackup

BackupEndTime string

The time when the cross-region data backup file was generated.

BackupMethod string

The method that is used to generate the cross-region data backup file. Valid values: L - logical backup. P - physical backup.

BackupSetScale string

The level at which the cross-region data backup file is generated. 0 - instance-level backup. 1 - database-level backup.

BackupSetStatus int

TThe status of the cross-region data backup. Valid values: 0 - The cross-region data backup is successful. 1 - The cross-region data backup failed.

BackupStartTime string

The time when the cross-region data backup started.

BackupType string

The type of the cross-region data backup. Valid values:F: full data backup F - full data backup. I - incremental data backup.

Category string

The RDS edition of the instance. Valid values: Basic - Basic Edition. HighAvailability - High-availability Edition. Finance - Enterprise Edition. This edition is supported only by the China site (aliyun.com).

ConsistentTime string

The point in time that is indicated by the data in the cross-region data backup file.

CrossBackupDownloadLink string

The external URL from which you can download the cross-region data backup file.

CrossBackupId string

The ID of the cross-region data backup file.

CrossBackupRegion string

The ID of the destination region where the cross-region data backup file of the instance is stored.

CrossBackupSetFile string

The name of the compressed package that contains the cross-region data backup file.

CrossBackupSetLocation string

The location where the cross-region data backup file is stored.

CrossBackupSetSize int

The size of the cross-region data backup file. Unit: bytes.

DbInstanceStorageType string

The storage type.

Engine string

The engine of the database.

EngineVersion string

The version of the database engine.

Id string

The ID of the cross-region data backup file.

InstanceId int

The ID of the instance. This parameter is used to determine whether the instance that generates the cross-region data backup file is a primary or secondary instance.

RecoveryBeginTime string

The start time to which data can be restored. The time follows the ISO 8601 standard in the yyyy-MM-ddTHH:mm:ssZ format. The time is displayed in UTC.

RecoveryEndTime string

The end time to which data can be restored. The time follows the ISO 8601 standard in the yyyy-MM-ddTHH:mm:ssZ format. The time is displayed in UTC.

RestoreRegions List<string>

An array that consists of the regions to which the cross-region data backup file can be restored.

BackupEndTime string

The time when the cross-region data backup file was generated.

BackupMethod string

The method that is used to generate the cross-region data backup file. Valid values: L - logical backup. P - physical backup.

BackupSetScale string

The level at which the cross-region data backup file is generated. 0 - instance-level backup. 1 - database-level backup.

BackupSetStatus int

TThe status of the cross-region data backup. Valid values: 0 - The cross-region data backup is successful. 1 - The cross-region data backup failed.

BackupStartTime string

The time when the cross-region data backup started.

BackupType string

The type of the cross-region data backup. Valid values:F: full data backup F - full data backup. I - incremental data backup.

Category string

The RDS edition of the instance. Valid values: Basic - Basic Edition. HighAvailability - High-availability Edition. Finance - Enterprise Edition. This edition is supported only by the China site (aliyun.com).

ConsistentTime string

The point in time that is indicated by the data in the cross-region data backup file.

CrossBackupDownloadLink string

The external URL from which you can download the cross-region data backup file.

CrossBackupId string

The ID of the cross-region data backup file.

CrossBackupRegion string

The ID of the destination region where the cross-region data backup file of the instance is stored.

CrossBackupSetFile string

The name of the compressed package that contains the cross-region data backup file.

CrossBackupSetLocation string

The location where the cross-region data backup file is stored.

CrossBackupSetSize int

The size of the cross-region data backup file. Unit: bytes.

DbInstanceStorageType string

The storage type.

Engine string

The engine of the database.

EngineVersion string

The version of the database engine.

Id string

The ID of the cross-region data backup file.

InstanceId int

The ID of the instance. This parameter is used to determine whether the instance that generates the cross-region data backup file is a primary or secondary instance.

RecoveryBeginTime string

The start time to which data can be restored. The time follows the ISO 8601 standard in the yyyy-MM-ddTHH:mm:ssZ format. The time is displayed in UTC.

RecoveryEndTime string

The end time to which data can be restored. The time follows the ISO 8601 standard in the yyyy-MM-ddTHH:mm:ssZ format. The time is displayed in UTC.

RestoreRegions []string

An array that consists of the regions to which the cross-region data backup file can be restored.

backupEndTime String

The time when the cross-region data backup file was generated.

backupMethod String

The method that is used to generate the cross-region data backup file. Valid values: L - logical backup. P - physical backup.

backupSetScale String

The level at which the cross-region data backup file is generated. 0 - instance-level backup. 1 - database-level backup.

backupSetStatus Integer

TThe status of the cross-region data backup. Valid values: 0 - The cross-region data backup is successful. 1 - The cross-region data backup failed.

backupStartTime String

The time when the cross-region data backup started.

backupType String

The type of the cross-region data backup. Valid values:F: full data backup F - full data backup. I - incremental data backup.

category String

The RDS edition of the instance. Valid values: Basic - Basic Edition. HighAvailability - High-availability Edition. Finance - Enterprise Edition. This edition is supported only by the China site (aliyun.com).

consistentTime String

The point in time that is indicated by the data in the cross-region data backup file.

crossBackupDownloadLink String

The external URL from which you can download the cross-region data backup file.

crossBackupId String

The ID of the cross-region data backup file.

crossBackupRegion String

The ID of the destination region where the cross-region data backup file of the instance is stored.

crossBackupSetFile String

The name of the compressed package that contains the cross-region data backup file.

crossBackupSetLocation String

The location where the cross-region data backup file is stored.

crossBackupSetSize Integer

The size of the cross-region data backup file. Unit: bytes.

dbInstanceStorageType String

The storage type.

engine String

The engine of the database.

engineVersion String

The version of the database engine.

id String

The ID of the cross-region data backup file.

instanceId Integer

The ID of the instance. This parameter is used to determine whether the instance that generates the cross-region data backup file is a primary or secondary instance.

recoveryBeginTime String

The start time to which data can be restored. The time follows the ISO 8601 standard in the yyyy-MM-ddTHH:mm:ssZ format. The time is displayed in UTC.

recoveryEndTime String

The end time to which data can be restored. The time follows the ISO 8601 standard in the yyyy-MM-ddTHH:mm:ssZ format. The time is displayed in UTC.

restoreRegions List<String>

An array that consists of the regions to which the cross-region data backup file can be restored.

backupEndTime string

The time when the cross-region data backup file was generated.

backupMethod string

The method that is used to generate the cross-region data backup file. Valid values: L - logical backup. P - physical backup.

backupSetScale string

The level at which the cross-region data backup file is generated. 0 - instance-level backup. 1 - database-level backup.

backupSetStatus number

TThe status of the cross-region data backup. Valid values: 0 - The cross-region data backup is successful. 1 - The cross-region data backup failed.

backupStartTime string

The time when the cross-region data backup started.

backupType string

The type of the cross-region data backup. Valid values:F: full data backup F - full data backup. I - incremental data backup.

category string

The RDS edition of the instance. Valid values: Basic - Basic Edition. HighAvailability - High-availability Edition. Finance - Enterprise Edition. This edition is supported only by the China site (aliyun.com).

consistentTime string

The point in time that is indicated by the data in the cross-region data backup file.

crossBackupDownloadLink string

The external URL from which you can download the cross-region data backup file.

crossBackupId string

The ID of the cross-region data backup file.

crossBackupRegion string

The ID of the destination region where the cross-region data backup file of the instance is stored.

crossBackupSetFile string

The name of the compressed package that contains the cross-region data backup file.

crossBackupSetLocation string

The location where the cross-region data backup file is stored.

crossBackupSetSize number

The size of the cross-region data backup file. Unit: bytes.

dbInstanceStorageType string

The storage type.

engine string

The engine of the database.

engineVersion string

The version of the database engine.

id string

The ID of the cross-region data backup file.

instanceId number

The ID of the instance. This parameter is used to determine whether the instance that generates the cross-region data backup file is a primary or secondary instance.

recoveryBeginTime string

The start time to which data can be restored. The time follows the ISO 8601 standard in the yyyy-MM-ddTHH:mm:ssZ format. The time is displayed in UTC.

recoveryEndTime string

The end time to which data can be restored. The time follows the ISO 8601 standard in the yyyy-MM-ddTHH:mm:ssZ format. The time is displayed in UTC.

restoreRegions string[]

An array that consists of the regions to which the cross-region data backup file can be restored.

backup_end_time str

The time when the cross-region data backup file was generated.

backup_method str

The method that is used to generate the cross-region data backup file. Valid values: L - logical backup. P - physical backup.

backup_set_scale str

The level at which the cross-region data backup file is generated. 0 - instance-level backup. 1 - database-level backup.

backup_set_status int

TThe status of the cross-region data backup. Valid values: 0 - The cross-region data backup is successful. 1 - The cross-region data backup failed.

backup_start_time str

The time when the cross-region data backup started.

backup_type str

The type of the cross-region data backup. Valid values:F: full data backup F - full data backup. I - incremental data backup.

category str

The RDS edition of the instance. Valid values: Basic - Basic Edition. HighAvailability - High-availability Edition. Finance - Enterprise Edition. This edition is supported only by the China site (aliyun.com).

consistent_time str

The point in time that is indicated by the data in the cross-region data backup file.

cross_backup_download_link str

The external URL from which you can download the cross-region data backup file.

cross_backup_id str

The ID of the cross-region data backup file.

cross_backup_region str

The ID of the destination region where the cross-region data backup file of the instance is stored.

cross_backup_set_file str

The name of the compressed package that contains the cross-region data backup file.

cross_backup_set_location str

The location where the cross-region data backup file is stored.

cross_backup_set_size int

The size of the cross-region data backup file. Unit: bytes.

db_instance_storage_type str

The storage type.

engine str

The engine of the database.

engine_version str

The version of the database engine.

id str

The ID of the cross-region data backup file.

instance_id int

The ID of the instance. This parameter is used to determine whether the instance that generates the cross-region data backup file is a primary or secondary instance.

recovery_begin_time str

The start time to which data can be restored. The time follows the ISO 8601 standard in the yyyy-MM-ddTHH:mm:ssZ format. The time is displayed in UTC.

recovery_end_time str

The end time to which data can be restored. The time follows the ISO 8601 standard in the yyyy-MM-ddTHH:mm:ssZ format. The time is displayed in UTC.

restore_regions Sequence[str]

An array that consists of the regions to which the cross-region data backup file can be restored.

backupEndTime String

The time when the cross-region data backup file was generated.

backupMethod String

The method that is used to generate the cross-region data backup file. Valid values: L - logical backup. P - physical backup.

backupSetScale String

The level at which the cross-region data backup file is generated. 0 - instance-level backup. 1 - database-level backup.

backupSetStatus Number

TThe status of the cross-region data backup. Valid values: 0 - The cross-region data backup is successful. 1 - The cross-region data backup failed.

backupStartTime String

The time when the cross-region data backup started.

backupType String

The type of the cross-region data backup. Valid values:F: full data backup F - full data backup. I - incremental data backup.

category String

The RDS edition of the instance. Valid values: Basic - Basic Edition. HighAvailability - High-availability Edition. Finance - Enterprise Edition. This edition is supported only by the China site (aliyun.com).

consistentTime String

The point in time that is indicated by the data in the cross-region data backup file.

crossBackupDownloadLink String

The external URL from which you can download the cross-region data backup file.

crossBackupId String

The ID of the cross-region data backup file.

crossBackupRegion String

The ID of the destination region where the cross-region data backup file of the instance is stored.

crossBackupSetFile String

The name of the compressed package that contains the cross-region data backup file.

crossBackupSetLocation String

The location where the cross-region data backup file is stored.

crossBackupSetSize Number

The size of the cross-region data backup file. Unit: bytes.

dbInstanceStorageType String

The storage type.

engine String

The engine of the database.

engineVersion String

The version of the database engine.

id String

The ID of the cross-region data backup file.

instanceId Number

The ID of the instance. This parameter is used to determine whether the instance that generates the cross-region data backup file is a primary or secondary instance.

recoveryBeginTime String

The start time to which data can be restored. The time follows the ISO 8601 standard in the yyyy-MM-ddTHH:mm:ssZ format. The time is displayed in UTC.

recoveryEndTime String

The end time to which data can be restored. The time follows the ISO 8601 standard in the yyyy-MM-ddTHH:mm:ssZ format. The time is displayed in UTC.

restoreRegions List<String>

An array that consists of the regions to which the cross-region data backup file can be restored.

Package Details

Repository
Alibaba Cloud pulumi/pulumi-alicloud
License
Apache-2.0
Notes

This Pulumi package is based on the alicloud Terraform Provider.