QuestionQ227

Data Ingestion and Transformation

A company must use an AWS Glue PySpark job to read particular data from an Amazon DynamoDB table. The company knows the partition-key values of the needed records. The AWS Glue PySpark job’s existing processing logic requires the data in DynamicFrame format. The company needs a solution that ensures the job reads only the specified data.

Which solution meets this requirement while using the MINIMUM number of read capacity units (RCUs)?

  • A Use the AWS Glue DynamoDB ETL connector to read the DynamoDB table. Use the filter option to read the required partition key.
  • B Perform a query on the DynamoDB table in the AWS Glue job by using only the sort key in the key condition expression. Load the data into a DynamicFrame.
  • C Perform a scan on the DynamoDB table in the Aws Glue job. Put the data into a DynamicFrame. Filter the DynamicFrame on the partition key.
  • D Perform a query on the DynamoDB table in the AWS Glue job. Use the partition key in the key condition expression. Put the data into a DynamicFrame.
Explanation

A DynamoDB Query must specify a partition-key value in its key condition expression and reads only items associated with that key value; a sort-key condition is optional. This avoids reading unrelated table items, unlike a Scan followed by filtering. The queried results can be placed in a DynamicFrame for the existing AWS Glue processing logic.

Learn more

Community Discussion

No comments yet. Be the first to start the discussion!