copy_jobs
Creates, updates, deletes, gets or lists a copy_jobs resource.
Overview
| Name | copy_jobs |
| Type | Resource |
| Id | aws.backup.copy_jobs |
Fields
The following fields are returned by SELECT queries:
- describe_copy_job
- list_copy_jobs
| Name | Datatype | Description |
|---|---|---|
account_id | string | The account ID that owns the copy job. (pattern: <code>^[0-9]{12}$</code>) |
backup_size_in_bytes | integer (int64) | The size, in bytes, of a copy job. |
child_jobs_in_state | object | This returns the statistics of the included child (nested) copy jobs. |
completion_date | string (date-time) | The date and time a copy job is completed, in Unix format and Coordinated Universal Time (UTC). The value of CompletionDate is accurate to milliseconds. For example, the value 1516925490.087 represents Friday, January 26, 2018 12:11:30.087 AM. |
composite_member_identifier | string | The identifier of a resource within a composite group, such as nested (child) recovery point belonging to a composite (parent) stack. The ID is transferred from the logical ID within a stack. |
copy_job_id | string | Uniquely identifies a copy job. |
created_by | object | Contains information about the backup plan and rule that Backup used to initiate the recovery point backup. |
created_by_backup_job_id | string | The backup job ID that initiated this copy job. Only applicable to scheduled copy jobs and automatic copy jobs to logically air-gapped vault. |
creation_date | string (date-time) | The date and time a copy job is created, in Unix format and Coordinated Universal Time (UTC). The value of CreationDate is accurate to milliseconds. For example, the value 1516925490.087 represents Friday, January 26, 2018 12:11:30.087 AM. |
destination_backup_vault_arn | string | An Amazon Resource Name (ARN) that uniquely identifies a destination copy vault; for example, arn:aws:backup:us-east-1:123456789012:backup-vault:aBackupVault. |
destination_encryption_key_arn | string | The Amazon Resource Name (ARN) of the KMS key used to encrypt the copied backup in the destination vault. This can be a customer-managed key or an Amazon Web Services managed key. |
destination_recovery_point_arn | string | An ARN that uniquely identifies a destination recovery point; for example, arn:aws:backup:us-east-1:123456789012:recovery-point:1EB3B5E7-9EB0-435A-A80B-108B488B0D45. |
destination_recovery_point_lifecycle | object | Specifies the time period, in days, before a recovery point transitions to cold storage or is deleted. Backups transitioned to cold storage must be stored in cold storage for a minimum of 90 days. Therefore, on the console, the retention setting must be 90 days greater than the transition to cold after days setting. The transition to cold after days setting can't be changed after a backup has been transitioned to cold. Resource types that can transition to cold storage are listed in the Feature availability by resource table. Backup ignores this expression for other resource types. To remove the existing lifecycle and retention periods and keep your recovery points indefinitely, specify -1 for MoveToColdStorageAfterDays and DeleteAfterDays. |
destination_vault_lock_state | string | The lock state of the destination backup vault. For logically air-gapped vaults, this indicates whether the vault is locked in compliance mode. Valid values include LOCKED and UNLOCKED. |
destination_vault_type | string | The type of destination backup vault where the copied recovery point is stored. Valid values are BACKUP_VAULT for standard backup vaults and LOGICALLY_AIR_GAPPED_BACKUP_VAULT for logically air-gapped vaults. |
iam_role_arn | string | Specifies the IAM role ARN used to copy the target recovery point; for example, arn:aws:iam::123456789012:role/S3Access. |
is_parent | boolean | This is a boolean value indicating this is a parent (composite) copy job. |
message_category | string | This parameter is the job count for the specified message category. Example strings may include AccessDenied, SUCCESS, AGGREGATE_ALL, and InvalidParameters. See Monitoring for a list of MessageCategory strings. The the value ANY returns count of all message categories. AGGREGATE_ALL aggregates job counts for all message categories and returns the sum |
number_of_child_jobs | integer (int64) | The number of child (nested) copy jobs. |
parent_job_id | string | This uniquely identifies a request to Backup to copy a resource. The return will be the parent (composite) job ID. |
resource_arn | string | The Amazon Web Services resource to be copied; for example, an Amazon Elastic Block Store (Amazon EBS) volume or an Amazon Relational Database Service (Amazon RDS) database. |
resource_name | string | The non-unique name of the resource that belongs to the specified backup. |
resource_type | string | The type of Amazon Web Services resource to be copied; for example, an Amazon Elastic Block Store (Amazon EBS) volume or an Amazon Relational Database Service (Amazon RDS) database. (pattern: <code>^[a-zA-Z0-9-_.]{1,50}$</code>) |
source_backup_vault_arn | string | An Amazon Resource Name (ARN) that uniquely identifies a source copy vault; for example, arn:aws:backup:us-east-1:123456789012:backup-vault:aBackupVault. |
source_recovery_point_arn | string | An ARN that uniquely identifies a source recovery point; for example, arn:aws:backup:us-east-1:123456789012:recovery-point:1EB3B5E7-9EB0-435A-A80B-108B488B0D45. |
state | string | The current state of a copy job. (CREATED, RUNNING, COMPLETED, FAILED, PARTIAL) |
status_message | string | A detailed message explaining the status of the job to copy a resource. |
| Name | Datatype | Description |
|---|---|---|
account_id | string | The account ID that owns the copy job. (pattern: <code>^[0-9]{12}$</code>) |
backup_size_in_bytes | integer (int64) | The size, in bytes, of a copy job. |
child_jobs_in_state | object | This returns the statistics of the included child (nested) copy jobs. |
completion_date | string (date-time) | The date and time a copy job is completed, in Unix format and Coordinated Universal Time (UTC). The value of CompletionDate is accurate to milliseconds. For example, the value 1516925490.087 represents Friday, January 26, 2018 12:11:30.087 AM. |
composite_member_identifier | string | The identifier of a resource within a composite group, such as nested (child) recovery point belonging to a composite (parent) stack. The ID is transferred from the logical ID within a stack. |
copy_job_id | string | Uniquely identifies a copy job. |
created_by | object | Contains information about the backup plan and rule that Backup used to initiate the recovery point backup. |
created_by_backup_job_id | string | The backup job ID that initiated this copy job. Only applicable to scheduled copy jobs and automatic copy jobs to logically air-gapped vault. |
creation_date | string (date-time) | The date and time a copy job is created, in Unix format and Coordinated Universal Time (UTC). The value of CreationDate is accurate to milliseconds. For example, the value 1516925490.087 represents Friday, January 26, 2018 12:11:30.087 AM. |
destination_backup_vault_arn | string | An Amazon Resource Name (ARN) that uniquely identifies a destination copy vault; for example, arn:aws:backup:us-east-1:123456789012:backup-vault:aBackupVault. |
destination_encryption_key_arn | string | The Amazon Resource Name (ARN) of the KMS key used to encrypt the copied backup in the destination vault. This can be a customer-managed key or an Amazon Web Services managed key. |
destination_recovery_point_arn | string | An ARN that uniquely identifies a destination recovery point; for example, arn:aws:backup:us-east-1:123456789012:recovery-point:1EB3B5E7-9EB0-435A-A80B-108B488B0D45. |
destination_recovery_point_lifecycle | object | Specifies the time period, in days, before a recovery point transitions to cold storage or is deleted. Backups transitioned to cold storage must be stored in cold storage for a minimum of 90 days. Therefore, on the console, the retention setting must be 90 days greater than the transition to cold after days setting. The transition to cold after days setting can't be changed after a backup has been transitioned to cold. Resource types that can transition to cold storage are listed in the Feature availability by resource table. Backup ignores this expression for other resource types. To remove the existing lifecycle and retention periods and keep your recovery points indefinitely, specify -1 for MoveToColdStorageAfterDays and DeleteAfterDays. |
destination_vault_lock_state | string | The lock state of the destination backup vault. For logically air-gapped vaults, this indicates whether the vault is locked in compliance mode. Valid values include LOCKED and UNLOCKED. |
destination_vault_type | string | The type of destination backup vault where the copied recovery point is stored. Valid values are BACKUP_VAULT for standard backup vaults and LOGICALLY_AIR_GAPPED_BACKUP_VAULT for logically air-gapped vaults. |
iam_role_arn | string | Specifies the IAM role ARN used to copy the target recovery point; for example, arn:aws:iam::123456789012:role/S3Access. |
is_parent | boolean | This is a boolean value indicating this is a parent (composite) copy job. |
message_category | string | This parameter is the job count for the specified message category. Example strings may include AccessDenied, SUCCESS, AGGREGATE_ALL, and InvalidParameters. See Monitoring for a list of MessageCategory strings. The the value ANY returns count of all message categories. AGGREGATE_ALL aggregates job counts for all message categories and returns the sum |
number_of_child_jobs | integer (int64) | The number of child (nested) copy jobs. |
parent_job_id | string | This uniquely identifies a request to Backup to copy a resource. The return will be the parent (composite) job ID. |
resource_arn | string | The Amazon Web Services resource to be copied; for example, an Amazon Elastic Block Store (Amazon EBS) volume or an Amazon Relational Database Service (Amazon RDS) database. |
resource_name | string | The non-unique name of the resource that belongs to the specified backup. |
resource_type | string | The type of Amazon Web Services resource to be copied; for example, an Amazon Elastic Block Store (Amazon EBS) volume or an Amazon Relational Database Service (Amazon RDS) database. (pattern: <code>^[a-zA-Z0-9-_.]{1,50}$</code>) |
source_backup_vault_arn | string | An Amazon Resource Name (ARN) that uniquely identifies a source copy vault; for example, arn:aws:backup:us-east-1:123456789012:backup-vault:aBackupVault. |
source_recovery_point_arn | string | An ARN that uniquely identifies a source recovery point; for example, arn:aws:backup:us-east-1:123456789012:recovery-point:1EB3B5E7-9EB0-435A-A80B-108B488B0D45. |
state | string | The current state of a copy job. (CREATED, RUNNING, COMPLETED, FAILED, PARTIAL) |
status_message | string | A detailed message explaining the status of the job to copy a resource. |
Methods
The following methods are available for this resource:
| Name | Accessible by | Required Params | Optional Params | Description |
|---|---|---|---|---|
describe_copy_job | select | copy_job_id, region | Returns metadata associated with creating a copy of a resource. | |
list_copy_jobs | select | region | nextToken, maxResults, resourceArn, state, createdBefore, createdAfter, resourceType, destinationVaultArn, accountId, completeBefore, completeAfter, parentJobId, messageCategory, sourceRecoveryPointArn | Returns metadata about your copy jobs. |
Parameters
Parameters can be passed in the WHERE clause of a query. Check the Methods section to see which parameters are required or optional for each operation.
| Name | Datatype | Description |
|---|---|---|
copy_job_id | string | Uniquely identifies a copy job. |
region | string | AWS region (default: us-east-1) |
accountId | string | The account ID to list the jobs from. Returns only copy jobs associated with the specified account ID. |
completeAfter | string (date-time) | Returns only copy jobs completed after a date expressed in Unix format and Coordinated Universal Time (UTC). |
completeBefore | string (date-time) | Returns only copy jobs completed before a date expressed in Unix format and Coordinated Universal Time (UTC). |
createdAfter | string (date-time) | Returns only copy jobs that were created after the specified date. |
createdBefore | string (date-time) | Returns only copy jobs that were created before the specified date. |
destinationVaultArn | string | An Amazon Resource Name (ARN) that uniquely identifies a source backup vault to copy from; for example, arn:aws:backup:us-east-1:123456789012:backup-vault:aBackupVault. |
maxResults | integer | The maximum number of items to be returned. |
messageCategory | string | This is an optional parameter that can be used to filter out jobs with a MessageCategory which matches the value you input. Example strings may include AccessDenied, SUCCESS, AGGREGATE_ALL, and INVALIDPARAMETERS. View Monitoring for a list of accepted strings. The the value ANY returns count of all message categories. AGGREGATE_ALL aggregates job counts for all message categories and returns the sum. |
nextToken | string | The next item following a partial list of returned items. For example, if a request is made to return MaxResults number of items, NextToken allows you to return more items in your list starting at the location pointed to by the next token. |
parentJobId | string | This is a filter to list child (nested) jobs based on parent job ID. |
resourceArn | string | Returns only copy jobs that match the specified resource Amazon Resource Name (ARN). |
resourceType | string | Returns only backup jobs for the specified resources: Aurora for Amazon Aurora CloudFormation for CloudFormation DocumentDB for Amazon DocumentDB (with MongoDB compatibility) DynamoDB for Amazon DynamoDB EBS for Amazon Elastic Block Store EC2 for Amazon Elastic Compute Cloud EFS for Amazon Elastic File System EKS for Amazon Elastic Kubernetes Service FSx for Amazon FSx Neptune for Amazon Neptune RDS for Amazon Relational Database Service Redshift for Amazon Redshift S3 for Amazon Simple Storage Service (Amazon S3) SAP HANA on Amazon EC2 for SAP HANA databases on Amazon Elastic Compute Cloud instances Storage Gateway for Storage Gateway Timestream for Amazon Timestream VirtualMachine for VMware virtual machines |
sourceRecoveryPointArn | string | Filters copy jobs by the specified source recovery point ARN. |
state | string | Returns only copy jobs that are in the specified state. |
SELECT examples
- describe_copy_job
- list_copy_jobs
Returns metadata associated with creating a copy of a resource.
SELECT
account_id,
backup_size_in_bytes,
child_jobs_in_state,
completion_date,
composite_member_identifier,
copy_job_id,
created_by,
created_by_backup_job_id,
creation_date,
destination_backup_vault_arn,
destination_encryption_key_arn,
destination_recovery_point_arn,
destination_recovery_point_lifecycle,
destination_vault_lock_state,
destination_vault_type,
iam_role_arn,
is_parent,
message_category,
number_of_child_jobs,
parent_job_id,
resource_arn,
resource_name,
resource_type,
source_backup_vault_arn,
source_recovery_point_arn,
state,
status_message
FROM aws.backup.copy_jobs
WHERE copy_job_id = '{{ copy_job_id }}' -- required
AND region = '{{ region }}' -- required
;
Returns metadata about your copy jobs.
SELECT
account_id,
backup_size_in_bytes,
child_jobs_in_state,
completion_date,
composite_member_identifier,
copy_job_id,
created_by,
created_by_backup_job_id,
creation_date,
destination_backup_vault_arn,
destination_encryption_key_arn,
destination_recovery_point_arn,
destination_recovery_point_lifecycle,
destination_vault_lock_state,
destination_vault_type,
iam_role_arn,
is_parent,
message_category,
number_of_child_jobs,
parent_job_id,
resource_arn,
resource_name,
resource_type,
source_backup_vault_arn,
source_recovery_point_arn,
state,
status_message
FROM aws.backup.copy_jobs
WHERE region = '{{ region }}' -- required
AND nextToken = '{{ nextToken }}'
AND maxResults = '{{ maxResults }}'
AND resourceArn = '{{ resourceArn }}'
AND state = '{{ state }}'
AND createdBefore = '{{ createdBefore }}'
AND createdAfter = '{{ createdAfter }}'
AND resourceType = '{{ resourceType }}'
AND destinationVaultArn = '{{ destinationVaultArn }}'
AND accountId = '{{ accountId }}'
AND completeBefore = '{{ completeBefore }}'
AND completeAfter = '{{ completeAfter }}'
AND parentJobId = '{{ parentJobId }}'
AND messageCategory = '{{ messageCategory }}'
AND sourceRecoveryPointArn = '{{ sourceRecoveryPointArn }}'
;