TimestreamInfluxDB / Client / restore_from_db_backup

restore_from_db_backup

TimestreamInfluxDB.Client.restore_from_db_backup(**kwargs)

Restores a Timestream for InfluxDB resource from a backup. By default, a new resource is created. You can optionally restore to the same resource using the REPLACE_EXISTING restore mode.

See also: AWS API Documentation

Request Syntax

response = client.restore_from_db_backup(
    name='string',
    dbBackupId='string',
    restoreToTime=datetime(2015, 1, 1),
    restoreMode='NEW_RESOURCE'|'REPLACE_EXISTING',
    vpcSubnetIds=[
        'string',
    ],
    vpcSecurityGroupIds=[
        'string',
    ],
    publiclyAccessible=True|False,
    logDeliveryConfiguration={
        's3Configuration': {
            'bucketName': 'string',
            'enabled': True|False
        }
    },
    maintenanceSchedule={
        'timezone': 'string',
        'preferredMaintenanceWindow': 'string'
    },
    tags={
        'string': 'string'
    },
    port=123,
    networkType='IPV4'|'DUAL',
    deploymentType='SINGLE_AZ'|'WITH_MULTIAZ_STANDBY'|'MULTI_NODE_READ_REPLICAS',
    dbBackupConfigurations=[
        {
            'type': 'HOURLY'|'DAILY'|'WEEKLY'|'MONTHLY'|'CUSTOM_SCHEDULE'|'CONTINUOUS',
            'retentionDays': 123,
            'enabled': True|False,
            'customSchedule': 'string'
        },
    ],
    kmsKeyId='string'
)
Parameters:
  • name (string) –

    [REQUIRED]

    The name of the new resource to create from the restore. If restoring to an existing resource, the name must match the existing resource name.

  • dbBackupId (string) –

    [REQUIRED]

    The identifier of the backup to restore from.

  • restoreToTime (datetime) – The point in time to restore to, for continuous backups. Must be within the backup’s retention window.

  • restoreMode (string) – Specifies whether to restore to a new resource or replace the existing resource. Valid values are NEW_RESOURCE (default) and REPLACE_EXISTING.

  • vpcSubnetIds (list) –

    A list of VPC subnet IDs for the restored resource. If not specified, the restored resource uses the same subnets as the backup.

    • (string) –

  • vpcSecurityGroupIds (list) –

    A list of VPC security group IDs for the restored resource. If not specified, the restored resource uses the same security groups as the backup.

    • (string) –

  • publiclyAccessible (boolean) – Specifies whether the restored resource is publicly accessible.

  • logDeliveryConfiguration (dict) –

    Configuration for sending InfluxDB engine logs to the specified S3 bucket for the restored resource.

    • s3Configuration (dict) – [REQUIRED]

      Configuration for S3 bucket log delivery.

      • bucketName (string) – [REQUIRED]

        The name of the S3 bucket to deliver logs to.

      • enabled (boolean) – [REQUIRED]

        Indicates whether log delivery to the S3 bucket is enabled.

  • maintenanceSchedule (dict) –

    The maintenance schedule for the restored resource.

    • timezone (string) – [REQUIRED]

      The IANA timezone identifier for the maintenance window. Format: Region/City or UTC. For example, America/New_York or UTC.

    • preferredMaintenanceWindow (string) – [REQUIRED]

      The preferred maintenance window in the format ddd:HH:MM-ddd:HH:MM (UTC). Day must be one of: Mon, Tue, Wed, Thu, Fri, Sat, Sun. For example, Sun:02:00-Sun:06:00. Provide an empty string to let the system choose a window.

  • tags (dict) –

    A list of key-value pairs to associate with the restored resource.

    • (string) –

      • (string) –

  • port (integer) – The port number on which the restored InfluxDB resource accepts connections.

  • networkType (string) – Specifies the network type of the restored resource. Valid values are IPV4 and DUAL.

  • deploymentType (string) – Specifies the deployment type of the restored resource. Valid values are SINGLE_AZ, WITH_MULTIAZ_STANDBY, and MULTI_NODE_READ_REPLICAS.

  • dbBackupConfigurations (list) –

    A list of backup configurations to apply to the restored resource.

    • (dict) –

      Specifies the configuration for an automated backup schedule.

      • type (string) – [REQUIRED]

        The type of automated backup schedule. Valid values are HOURLY, DAILY, WEEKLY, MONTHLY, CUSTOM_SCHEDULE, and CONTINUOUS.

      • retentionDays (integer) – [REQUIRED]

        The number of days to retain automated backups. Valid values are 1 to 365.

      • enabled (boolean) – [REQUIRED]

        Specifies whether this backup configuration is enabled.

      • customSchedule (string) –

        A custom cron schedule expression for the backup. Required when type is CUSTOM_SCHEDULE.

  • kmsKeyId (string) – The Amazon Web Services KMS key identifier to use for encryption of the restored resource. Can be a key ID, key ARN, alias name, or alias ARN.

Return type:

dict

Returns:

Response Syntax

{
    'restoredDbResourceId': 'string',
    'restoreStatus': 'RESTORING',
    'resourceType': 'DB_INSTANCE'|'DB_CLUSTER',
    'engineType': 'INFLUXDB_V2'|'INFLUXDB_V3_CORE'|'INFLUXDB_V3_ENTERPRISE',
    'deploymentType': 'SINGLE_AZ'|'WITH_MULTIAZ_STANDBY'|'MULTI_NODE_READ_REPLICAS'
}

Response Structure

  • (dict) –

    • restoredDbResourceId (string) –

      The identifier of the restored DB resource.

    • restoreStatus (string) –

      The status of the restore operation.

    • resourceType (string) –

      The type of the restored resource. Valid values are DB_INSTANCE and DB_CLUSTER.

    • engineType (string) –

      The engine type of the restored resource.

    • deploymentType (string) –

      The deployment type of the restored resource.

Exceptions