Skip to content

/AWS1/IF_PZZ=>CREATEDATASETEXPORTJOB()

About CreateDatasetExportJob

Creates a job that exports data from your dataset to an Amazon S3 bucket. To allow Amazon Personalize to export the training data, you must specify an service-linked IAM role that gives Amazon Personalize PutObject permissions for your Amazon S3 bucket. For information, see Exporting a dataset in the Amazon Personalize developer guide.

Status

A dataset export job can be in one of the following states:

  • CREATE PENDING > CREATE IN_PROGRESS > ACTIVE -or- CREATE FAILED

To get the status of the export job, call DescribeDatasetExportJob, and specify the Amazon Resource Name (ARN) of the dataset export job. The dataset export is complete when the status shows as ACTIVE. If the status shows as CREATE FAILED, the response includes a failureReason key, which describes why the job failed.

Method Signature

IMPORTING

Required arguments:

iv_jobname TYPE /AWS1/PZZNAME /AWS1/PZZNAME

The name for the dataset export job.

iv_datasetarn TYPE /AWS1/PZZARN /AWS1/PZZARN

The Amazon Resource Name (ARN) of the dataset that contains the data to export.

iv_rolearn TYPE /AWS1/PZZROLEARN /AWS1/PZZROLEARN

The Amazon Resource Name (ARN) of the IAM service role that has permissions to add data to your output Amazon S3 bucket.

io_joboutput TYPE REF TO /AWS1/CL_PZZDSEXPORTJOBOUTPUT /AWS1/CL_PZZDSEXPORTJOBOUTPUT

The path to the Amazon S3 bucket where the job's output is stored.

Optional arguments:

iv_ingestionmode TYPE /AWS1/PZZINGESTIONMODE /AWS1/PZZINGESTIONMODE

The data to export, based on how you imported the data. You can choose to export only BULK data that you imported using a dataset import job, only PUT data that you imported incrementally (using the console, PutEvents, PutUsers and PutItems operations), or ALL for both types. The default value is PUT.

it_tags TYPE /AWS1/CL_PZZTAG=>TT_TAGS TT_TAGS

A list of tags to apply to the dataset export job.

RETURNING

oo_output TYPE REF TO /aws1/cl_pzzcreatedsexpjobrsp /AWS1/CL_PZZCREATEDSEXPJOBRSP

Domain /AWS1/RT_ACCOUNT_ID
Primitive Type NUMC

Examples

Syntax Example

This is an example of the syntax for calling the method. It includes every possible argument and initializes every possible value. The data provided is not necessarily semantically accurate (for example the value "string" may be provided for something that is intended to be an instance ID, or in some cases two arguments may be mutually exclusive). The syntax shows the ABAP syntax for creating the various data structures.

DATA(lo_result) = lo_client->/aws1/if_pzz~createdatasetexportjob(
  io_joboutput = new /aws1/cl_pzzdsexportjoboutput(
    io_s3datadestination = new /aws1/cl_pzzs3dataconfig(
      iv_kmskeyarn = |string|
      iv_path = |string|
    )
  )
  it_tags = VALUE /aws1/cl_pzztag=>tt_tags(
    (
      new /aws1/cl_pzztag(
        iv_tagkey = |string|
        iv_tagvalue = |string|
      )
    )
  )
  iv_datasetarn = |string|
  iv_ingestionmode = |string|
  iv_jobname = |string|
  iv_rolearn = |string|
).

This is an example of reading all possible response values

lo_result = lo_result.
IF lo_result IS NOT INITIAL.
  lv_arn = lo_result->get_datasetexportjobarn( ).
ENDIF.