Skip to content

aws.glacier.list_jobs

Example SQL Queries

SELECT * FROM
aws.glacier.list_jobs
WHERE
"account_id" = 'VALUE'
AND "vault_name" = 'VALUE';

Description

This operation lists jobs for a vault, including jobs that are in-progress and jobs that have recently finished. The List Job operation returns a list of these jobs sorted by job initiation time.

Amazon Glacier retains recently completed jobs for a period before deleting them; however, it eventually removes completed jobs. The output of completed jobs can be retrieved. Retaining completed jobs for a period of time after they have completed enables you to get a job output in the event you miss the job completion notification or your first attempt to download it fails. For example, suppose you start an archive retrieval job to download an archive. After the job completes, you start to download the archive but encounter a network error. In this scenario, you can retry and download the archive while the job exists.

The List Jobs operation supports pagination. You should always check the response Marker field. If there are no more jobs to list, the Marker field is set to null. If there are more jobs to list, the Marker field is set to a non-null value, which you can use to continue the pagination of the list. To return a list of jobs that begins at a specific job, set the marker request parameter to the Marker value for that job that you obtained from a previous List Jobs request.

You can set a maximum limit for the number of jobs returned in the response by specifying the limit parameter in the request. The default limit is 50. The number of jobs returned might be fewer than the limit, but the number of returned jobs never exceeds the limit.

Additionally, you can filter the jobs list returned by specifying the optional statuscode parameter or completed parameter, or both. Using the statuscode parameter, you can specify to return only jobs that match either the InProgress, Succeeded, or Failed status. Using the completed parameter, you can specify to return only jobs that were completed (true) or jobs that were not completed (false).

For more information about using this operation, see the documentation for the underlying REST API List Jobs.

Table Definition

Column NameColumn Data Type
account_id Required Input Column

The AccountId value is the AWS account ID of the account that owns the vault. You can either specify an AWS account ID or optionally a single '-' (hyphen), in which case Amazon S3 Glacier uses the AWS account ID associated with the credentials used to sign the request. If you use an account ID, do not include any hyphens ('-') in the ID.

VARCHAR
vault_name Required Input Column

The name of the vault.

VARCHAR
statuscode Input Column

The type of job status to return. You can specify the following values: InProgress, Succeeded, or Failed.

VARCHAR
_aws_profile Input Column

The AWS profile defines the AWS identity used. It can be defined via credentials or by assuming a IAM role.

STRUCT(
"type" VARCHAR,
"name" VARCHAR,
"account_id" VARCHAR,
"via_profile_name" VARCHAR,
"assumed_role_arn" VARCHAR,
"organization" STRUCT(
"account_name" VARCHAR,
"id" VARCHAR,
"tags" STRUCT(
"key" VARCHAR,
"value" VARCHAR
)[],
"master_account" STRUCT(
"id" VARCHAR,
"email" VARCHAR
),
"parents" STRUCT(
"type" VARCHAR,
"id" VARCHAR,
"name" VARCHAR,
"tags" STRUCT(
"key" VARCHAR,
"value" VARCHAR
)[]
)[]
)
)
Show child fields
_aws_profile.account_id

The AWS account id

_aws_profile.assumed_role_arn

The ARN of the assumed role

_aws_profile.name

The unique name of the profile.

_aws_profile.organization

Information about this profile's membership in the AWS organization.

Show child fields
_aws_profile.organization.account_name

The name of account speciifed by the organization

_aws_profile.organization.id

The organization id

_aws_profile.organization.master_account
Show child fields
_aws_profile.organization.master_account.email

The organization master account email address

_aws_profile.organization.master_account.id

The organization master account id

_aws_profile.organization.parents[]
Show child fields
_aws_profile.organization.parents[].id

The id of the parent

_aws_profile.organization.parents[].name

The name of the parent

_aws_profile.organization.parents[].tags[]
Show child fields
_aws_profile.organization.parents[].tags[].key
_aws_profile.organization.parents[].tags[].value
_aws_profile.organization.parents[].type

The type of parent can be an organization unit or a root

_aws_profile.organization.tags[]
Show child fields
_aws_profile.organization.tags[].key
_aws_profile.organization.tags[].value
_aws_profile.type

The type of profile, either 'credentials' or 'assumed_role'

_aws_profile.via_profile_name

This IAM role for this profile is assumed by first utilizing another profile with this name to obtain credentials.

_aws_region Input Column

The AWS region to use.

VARCHAR
_input_completed Input Column
VARCHAR
action

The job type. This value is either ArchiveRetrieval, InventoryRetrieval, or Select.

VARCHAR
archive_id

The archive ID requested for a select job or archive retrieval. Otherwise, this field is null.

VARCHAR
archive_sha256_tree_hash

The SHA256 tree hash of the entire archive for an archive retrieval. For inventory retrieval or select jobs, this field is null.

VARCHAR
archive_size_in_bytes

For an archive retrieval job, this value is the size in bytes of the archive being requested for download. For an inventory retrieval or select job, this value is null.

BIGINT
completed

The job status. When a job is completed, you get the job's output using Get Job Output (GET output).

BOOLEAN
completion_date

The UTC time that the job request completed. While the job is in progress, the value is null.

VARCHAR
creation_date

The UTC date when the job was created. This value is a string representation of ISO 8601 date format, for example "2012-03-20T17:03:43.221Z".

VARCHAR
inventory_retrieval_parameters

Parameters used for range inventory retrieval.

STRUCT(
"format" VARCHAR,
"start_date" VARCHAR,
"end_date" VARCHAR,
"limit" VARCHAR,
"marker" VARCHAR
)
Show child fields
inventory_retrieval_parameters.end_date

The end of the date range in UTC for vault inventory retrieval that includes archives created before this date. This value should be a string in the ISO 8601 date format, for example 2013-03-20T17:03:43Z.

inventory_retrieval_parameters.format

The output format for the vault inventory list, which is set by the InitiateJob request when initiating a job to retrieve a vault inventory. Valid values are CSV and JSON.

inventory_retrieval_parameters.limit

The maximum number of inventory items returned per vault inventory retrieval request. This limit is set when initiating the job with the a InitiateJob request.

inventory_retrieval_parameters.marker

An opaque string that represents where to continue pagination of the vault inventory retrieval results. You use the marker in a new InitiateJob request to obtain additional inventory items. If there are no more inventory items, this value is null. For more information, see Range Inventory Retrieval.

inventory_retrieval_parameters.start_date

The start of the date range in Universal Coordinated Time (UTC) for vault inventory retrieval that includes archives created on or after this date. This value should be a string in the ISO 8601 date format, for example 2013-03-20T17:03:43Z.

inventory_size_in_bytes

For an inventory retrieval job, this value is the size in bytes of the inventory requested for download. For an archive retrieval or select job, this value is null.

BIGINT
job_description

The job description provided when initiating the job.

VARCHAR
job_id

An opaque string that identifies an Amazon S3 Glacier job.

VARCHAR
job_output_path

Contains the job output location.

VARCHAR
output_location

Contains the location where the data from the select job is stored.

STRUCT(
"s3" STRUCT(
"bucket_name" VARCHAR,
"prefix" VARCHAR,
"encryption" STRUCT(
"encryption_type" VARCHAR,
"kms_key_id" VARCHAR,
"kms_context" VARCHAR
),
"canned_acl" VARCHAR,
"access_control_list" STRUCT(
"grantee" STRUCT(
"type" VARCHAR,
"display_name" VARCHAR,
"uri" VARCHAR,
"id" VARCHAR,
"email_address" VARCHAR
),
"permission" VARCHAR
)[],
"tagging" MAP(VARCHAR, VARCHAR),
"user_metadata" MAP(VARCHAR, VARCHAR),
"storage_class" VARCHAR
)
)
Show child fields
output_location.s3

Describes an S3 location that will receive the results of the job request.

Show child fields
output_location.s3.access_control_list[]
Show child fields
output_location.s3.access_control_list[].grantee

The grantee.

Show child fields
output_location.s3.access_control_list[].grantee.display_name

Screen name of the grantee.

output_location.s3.access_control_list[].grantee.email_address

Email address of the grantee.

output_location.s3.access_control_list[].grantee.id

The canonical user ID of the grantee.

output_location.s3.access_control_list[].grantee.type

Type of grantee

output_location.s3.access_control_list[].grantee.uri

URI of the grantee group.

output_location.s3.access_control_list[].permission

Specifies the permission given to the grantee.

output_location.s3.bucket_name

The name of the Amazon S3 bucket where the job results are stored.

output_location.s3.canned_acl

The canned access control list (ACL) to apply to the job results.

output_location.s3.encryption

Contains information about the encryption used to store the job results in Amazon S3.

Show child fields
output_location.s3.encryption.encryption_type

The server-side encryption algorithm used when storing job results in Amazon S3, for example AES256 or aws:kms.

output_location.s3.encryption.kms_context

Optional. If the encryption type is aws:kms, you can use this value to specify the encryption context for the job results.

output_location.s3.encryption.kms_key_id

The AWS KMS key ID to use for object encryption. All GET and PUT requests for an object protected by AWS KMS fail if not made by using Secure Sockets Layer (SSL) or Signature Version 4.

output_location.s3.prefix

The prefix that is prepended to the results for this request.

output_location.s3.storage_class

The storage class used to store the job results.

output_location.s3.tagging

The tag-set that is applied to the job results.

output_location.s3.user_metadata

A map of metadata to store with the job results in Amazon S3.

retrieval_byte_range

The retrieved byte range for archive retrieval jobs in the form StartByteValue-EndByteValue. If no range was specified in the archive retrieval, then the whole archive is retrieved. In this case, StartByteValue equals 0 and EndByteValue equals the size of the archive minus 1. For inventory retrieval or select jobs, this field is null.

VARCHAR
select_parameters

Contains the parameters used for a select.

STRUCT(
"input_serialization" STRUCT(
"csv" STRUCT(
"file_header_info" VARCHAR,
"comments" VARCHAR,
"quote_escape_character" VARCHAR,
"record_delimiter" VARCHAR,
"field_delimiter" VARCHAR,
"quote_character" VARCHAR
)
),
"expression_type" VARCHAR,
"expression" VARCHAR,
"output_serialization" STRUCT(
"csv" STRUCT(
"quote_fields" VARCHAR,
"quote_escape_character" VARCHAR,
"record_delimiter" VARCHAR,
"field_delimiter" VARCHAR,
"quote_character" VARCHAR
)
)
)
Show child fields
select_parameters.expression

The expression that is used to select the object.

select_parameters.expression_type

The type of the provided expression, for example SQL.

select_parameters.input_serialization

Describes the serialization format of the object.

Show child fields
select_parameters.input_serialization.csv

Describes the serialization of a CSV-encoded object.

Show child fields
select_parameters.input_serialization.csv.comments

A single character used to indicate that a row should be ignored when the character is present at the start of that row.

select_parameters.input_serialization.csv.field_delimiter

A value used to separate individual fields from each other within a record.

select_parameters.input_serialization.csv.file_header_info

Describes the first line of input. Valid values are None, Ignore, and Use.

select_parameters.input_serialization.csv.quote_character

A value used as an escape character where the field delimiter is part of the value.

select_parameters.input_serialization.csv.quote_escape_character

A single character used for escaping the quotation-mark character inside an already escaped value.

select_parameters.input_serialization.csv.record_delimiter

A value used to separate individual records from each other.

select_parameters.output_serialization

Describes how the results of the select job are serialized.

Show child fields
select_parameters.output_serialization.csv

Describes the serialization of CSV-encoded query results.

Show child fields
select_parameters.output_serialization.csv.field_delimiter

A value used to separate individual fields from each other within a record.

select_parameters.output_serialization.csv.quote_character

A value used as an escape character where the field delimiter is part of the value.

select_parameters.output_serialization.csv.quote_escape_character

A single character used for escaping the quotation-mark character inside an already escaped value.

select_parameters.output_serialization.csv.quote_fields

A value that indicates whether all output fields should be contained within quotation marks.

select_parameters.output_serialization.csv.record_delimiter

A value used to separate individual records from each other.

sha256_tree_hash

For an archive retrieval job, this value is the checksum of the archive. Otherwise, this value is null.

The SHA256 tree hash value for the requested range of an archive. If the InitiateJob request for an archive specified a tree-hash aligned range, then this field returns a value.

If the whole archive is retrieved, this value is the same as the ArchiveSHA256TreeHash value.

This field is null for the following:

  • Archive retrieval jobs that specify a range that is not tree-hash aligned

  • Archival jobs that specify a range that is equal to the whole archive, when the job status is InProgress

  • Inventory jobs

  • Select jobs

VARCHAR
sns_topic

An Amazon SNS topic that receives notification.

VARCHAR
status_code

The status code can be InProgress, Succeeded, or Failed, and indicates the status of the job.

VARCHAR
status_message

A friendly message that describes the job status.

VARCHAR
tier

The tier to use for a select or an archive retrieval. Valid values are Expedited, Standard, or Bulk. Standard is the default.

VARCHAR
vault_arn

The Amazon Resource Name (ARN) of the vault from which an archive retrieval was requested.

VARCHAR