Skip to content

Commit

Permalink
feat(client-backup): AWS Backup - Features: Add VaultType to the outp…
Browse files Browse the repository at this point in the history
…ut of DescribeRecoveryPoint, ListRecoveryPointByBackupVault API and add ResourceType to the input of ListRestoreJobs API
  • Loading branch information
awstools committed Dec 6, 2023
1 parent 2a70f0c commit f1f4163
Show file tree
Hide file tree
Showing 7 changed files with 223 additions and 10 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -88,6 +88,7 @@ export interface DescribeRecoveryPointCommandOutput extends DescribeRecoveryPoin
* // CompositeMemberIdentifier: "STRING_VALUE",
* // IsParent: true || false,
* // ResourceName: "STRING_VALUE",
* // VaultType: "BACKUP_VAULT" || "LOGICALLY_AIR_GAPPED_BACKUP_VAULT",
* // };
*
* ```
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -101,6 +101,7 @@ export interface ListRecoveryPointsByBackupVaultCommandOutput
* // CompositeMemberIdentifier: "STRING_VALUE",
* // IsParent: true || false,
* // ResourceName: "STRING_VALUE",
* // VaultType: "BACKUP_VAULT" || "LOGICALLY_AIR_GAPPED_BACKUP_VAULT",
* // },
* // ],
* // };
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -49,6 +49,7 @@ export interface ListRestoreJobsCommandOutput extends ListRestoreJobsOutput, __M
* NextToken: "STRING_VALUE",
* MaxResults: Number("int"),
* ByAccountId: "STRING_VALUE",
* ByResourceType: "STRING_VALUE",
* ByCreatedBefore: new Date("TIMESTAMP"),
* ByCreatedAfter: new Date("TIMESTAMP"),
* ByStatus: "PENDING" || "RUNNING" || "COMPLETED" || "ABORTED" || "FAILED",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -37,10 +37,8 @@ export interface UpdateRegionSettingsCommandOutput extends __MetadataBearer {}

/**
* @public
* <p>Updates the current service opt-in settings for the Region. If service-opt-in is enabled
* for a service, Backup tries to protect that service's resources in this Region,
* when the resource is included in an on-demand backup or scheduled backup plan. Otherwise,
* Backup does not try to protect that service's resources in this Region. Use
* <p>Updates the current service opt-in settings for the Region.</p>
* <p>Use
* the <code>DescribeRegionSettings</code> API to determine the resource types that are
* supported.</p>
* @example
Expand Down
192 changes: 191 additions & 1 deletion clients/client-backup/src/models/models_0.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4192,6 +4192,12 @@ export interface DescribeRecoveryPointOutput {
* belongs to the specified backup.</p>
*/
ResourceName?: string;

/**
* @public
* <p>This is the type of vault in which the described recovery point is stored.</p>
*/
VaultType?: VaultType;
}

/**
Expand Down Expand Up @@ -5579,6 +5585,10 @@ export interface ListBackupJobsInput {
* </li>
* <li>
* <p>
* <code>CloudFormation</code> for CloudFormation</p>
* </li>
* <li>
* <p>
* <code>DocumentDB</code> for Amazon DocumentDB (with MongoDB compatibility)</p>
* </li>
* <li>
Expand Down Expand Up @@ -5607,10 +5617,18 @@ export interface ListBackupJobsInput {
* </li>
* <li>
* <p>
* <code>Redshift</code> for Amazon Redshift</p>
* </li>
* <li>
* <p>
* <code>RDS</code> for Amazon Relational Database Service</p>
* </li>
* <li>
* <p>
* <code>SAP HANA on Amazon EC2</code> for SAP HANA databases</p>
* </li>
* <li>
* <p>
* <code>Storage Gateway</code> for Storage Gateway</p>
* </li>
* <li>
Expand All @@ -5619,6 +5637,10 @@ export interface ListBackupJobsInput {
* </li>
* <li>
* <p>
* <code>Timestream</code> for Amazon Timestream</p>
* </li>
* <li>
* <p>
* <code>VirtualMachine</code> for virtual machines</p>
* </li>
* </ul>
Expand Down Expand Up @@ -6130,6 +6152,10 @@ export interface ListCopyJobsInput {
* </li>
* <li>
* <p>
* <code>CloudFormation</code> for CloudFormation</p>
* </li>
* <li>
* <p>
* <code>DocumentDB</code> for Amazon DocumentDB (with MongoDB compatibility)</p>
* </li>
* <li>
Expand Down Expand Up @@ -6158,10 +6184,18 @@ export interface ListCopyJobsInput {
* </li>
* <li>
* <p>
* <code>Redshift</code> for Amazon Redshift</p>
* </li>
* <li>
* <p>
* <code>RDS</code> for Amazon Relational Database Service</p>
* </li>
* <li>
* <p>
* <code>SAP HANA on Amazon EC2</code> for SAP HANA databases</p>
* </li>
* <li>
* <p>
* <code>Storage Gateway</code> for Storage Gateway</p>
* </li>
* <li>
Expand All @@ -6170,6 +6204,10 @@ export interface ListCopyJobsInput {
* </li>
* <li>
* <p>
* <code>Timestream</code> for Amazon Timestream</p>
* </li>
* <li>
* <p>
* <code>VirtualMachine</code> for virtual machines</p>
* </li>
* </ul>
Expand Down Expand Up @@ -6780,7 +6818,73 @@ export interface ListRecoveryPointsByBackupVaultInput {

/**
* @public
* <p>Returns only recovery points that match the specified resource type.</p>
* <p>Returns only recovery points that match the specified resource type(s):</p>
* <ul>
* <li>
* <p>
* <code>Aurora</code> for Amazon Aurora</p>
* </li>
* <li>
* <p>
* <code>CloudFormation</code> for CloudFormation</p>
* </li>
* <li>
* <p>
* <code>DocumentDB</code> for Amazon DocumentDB (with MongoDB compatibility)</p>
* </li>
* <li>
* <p>
* <code>DynamoDB</code> for Amazon DynamoDB</p>
* </li>
* <li>
* <p>
* <code>EBS</code> for Amazon Elastic Block Store</p>
* </li>
* <li>
* <p>
* <code>EC2</code> for Amazon Elastic Compute Cloud</p>
* </li>
* <li>
* <p>
* <code>EFS</code> for Amazon Elastic File System</p>
* </li>
* <li>
* <p>
* <code>FSx</code> for Amazon FSx</p>
* </li>
* <li>
* <p>
* <code>Neptune</code> for Amazon Neptune</p>
* </li>
* <li>
* <p>
* <code>Redshift</code> for Amazon Redshift</p>
* </li>
* <li>
* <p>
* <code>RDS</code> for Amazon Relational Database Service</p>
* </li>
* <li>
* <p>
* <code>SAP HANA on Amazon EC2</code> for SAP HANA databases</p>
* </li>
* <li>
* <p>
* <code>Storage Gateway</code> for Storage Gateway</p>
* </li>
* <li>
* <p>
* <code>S3</code> for Amazon S3</p>
* </li>
* <li>
* <p>
* <code>Timestream</code> for Amazon Timestream</p>
* </li>
* <li>
* <p>
* <code>VirtualMachine</code> for virtual machines</p>
* </li>
* </ul>
*/
ByResourceType?: string;

Expand Down Expand Up @@ -6987,6 +7091,12 @@ export interface RecoveryPointByBackupVault {
* belongs to the specified backup.</p>
*/
ResourceName?: string;

/**
* @public
* <p>This is the type of vault in which the described recovery point is stored.</p>
*/
VaultType?: VaultType;
}

/**
Expand Down Expand Up @@ -7357,6 +7467,79 @@ export interface ListRestoreJobsInput {
*/
ByAccountId?: string;

/**
* @public
* <p>Include this parameter to return only restore jobs for the
* specified resources:</p>
* <ul>
* <li>
* <p>
* <code>Aurora</code> for Amazon Aurora</p>
* </li>
* <li>
* <p>
* <code>CloudFormation</code> for CloudFormation</p>
* </li>
* <li>
* <p>
* <code>DocumentDB</code> for Amazon DocumentDB (with MongoDB compatibility)</p>
* </li>
* <li>
* <p>
* <code>DynamoDB</code> for Amazon DynamoDB</p>
* </li>
* <li>
* <p>
* <code>EBS</code> for Amazon Elastic Block Store</p>
* </li>
* <li>
* <p>
* <code>EC2</code> for Amazon Elastic Compute Cloud</p>
* </li>
* <li>
* <p>
* <code>EFS</code> for Amazon Elastic File System</p>
* </li>
* <li>
* <p>
* <code>FSx</code> for Amazon FSx</p>
* </li>
* <li>
* <p>
* <code>Neptune</code> for Amazon Neptune</p>
* </li>
* <li>
* <p>
* <code>Redshift</code> for Amazon Redshift</p>
* </li>
* <li>
* <p>
* <code>RDS</code> for Amazon Relational Database Service</p>
* </li>
* <li>
* <p>
* <code>SAP HANA on Amazon EC2</code> for SAP HANA databases</p>
* </li>
* <li>
* <p>
* <code>Storage Gateway</code> for Storage Gateway</p>
* </li>
* <li>
* <p>
* <code>S3</code> for Amazon S3</p>
* </li>
* <li>
* <p>
* <code>Timestream</code> for Amazon Timestream</p>
* </li>
* <li>
* <p>
* <code>VirtualMachine</code> for virtual machines</p>
* </li>
* </ul>
*/
ByResourceType?: string;

/**
* @public
* <p>Returns only restore jobs that were created before the specified date.</p>
Expand Down Expand Up @@ -8964,6 +9147,13 @@ export interface UpdateRegionSettingsInput {
/**
* @public
* <p>Updates the list of services along with the opt-in preferences for the Region.</p>
* <p>If resource assignments are only based on tags, then service opt-in settings are applied.
* If a resource type is explicitly assigned to a backup plan, such as Amazon S3,
* Amazon EC2, or Amazon RDS, it will be included in the
* backup even if the opt-in is not enabled for that particular service.
* If both a resource type and tags are specified in a resource assignment,
* the resource type specified in the backup plan takes priority over the
* tag condition. Service opt-in settings are disregarded in this situation.</p>
*/
ResourceTypeOptInPreference?: Record<string, boolean>;

Expand Down
3 changes: 3 additions & 0 deletions clients/client-backup/src/protocols/Aws_restJson1.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2524,6 +2524,7 @@ export const se_ListRestoreJobsCommand = async (
nextToken: [, input.NextToken!],
maxResults: [() => input.MaxResults !== void 0, () => input.MaxResults!.toString()],
accountId: [, input.ByAccountId!],
resourceType: [, input.ByResourceType!],
createdBefore: [
() => input.ByCreatedBefore !== void 0,
() => (input.ByCreatedBefore!.toISOString().split(".")[0] + "Z").toString(),
Expand Down Expand Up @@ -5043,6 +5044,7 @@ export const de_DescribeRecoveryPointCommand = async (
Status: __expectString,
StatusMessage: __expectString,
StorageClass: __expectString,
VaultType: __expectString,
});
Object.assign(contents, doc);
return contents;
Expand Down Expand Up @@ -9396,6 +9398,7 @@ const de_RecoveryPointByBackupVault = (output: any, context: __SerdeContext): Re
SourceBackupVaultArn: __expectString,
Status: __expectString,
StatusMessage: __expectString,
VaultType: __expectString,
}) as any;
};

Expand Down
Loading

0 comments on commit f1f4163

Please sign in to comment.