DEA-C01 Question 148
Select 2Your company is building a data lake on AWS to store and analyze large volumes of structured and unstructured data. For long-term storage, you decide to use Amazon S3. However, your data analysis team has reported slow query performance when analyzing the data using Amazon Athena. What steps can you take to optimize the data in Amazon S3 for faster query performance with Athena?
- A
Partition the data in S3 based on frequently queried attributes.
- B
Compress the data using a columnar format such as Parquet or ORC.
- C
Enable Amazon S3 Transfer Acceleration to reduce query latency.
- D
Use Amazon S3 Intelligent-Tiering to automatically optimize storage costs.
- E
Store the data in multiple S3 buckets to distribute the queries.
Show answer and explanation
Correct answers: A, B
Explanation
To optimize query performance in Amazon Athena, it is critical to reduce the amount of data scanned during queries. Partitioning the data allows Athena to scan only relevant parts of the dataset based on query predicates. Using columnar formats like Parquet or ORC further reduces the amount of data scanned and improves performance by storing data in a more query-efficient structure. Other options, like S3 Transfer Acceleration or Intelligent-Tiering, address different AWS use cases and do not influence Athena query performance.
- A. Correct.
Partitioning the data in S3 based on frequently queried attributes will reduce the amount of data scanned by Athena queries, improving performance and reducing costs.
- B. Correct.
Compressing the data using columnar formats like Parquet or ORC significantly improves query performance because these formats are optimized for analytical queries and reduce the amount of data scanned.
- C. Incorrect.
Amazon S3 Transfer Acceleration is designed to speed up data uploads and downloads over long distances, but it does not improve query performance in Athena.
- D. Incorrect.
Amazon S3 Intelligent-Tiering is a storage class for cost optimization based on access patterns. It does not directly improve query performance in Athena.
- E. Incorrect.
Storing data in multiple S3 buckets does not inherently improve query performance and may complicate data management.