DAS-C01 · Question #1
A company has developed an Apache Hive script to batch process data stared in Amazon S3. The script needs to run once every day and store the output in Amazon S3. The company tested the script, and…
The correct answer is A. Create an AWS Lambda function to spin up an Amazon EMR cluster with a Hive execution step. The most cost-effective solution is to use an AWS Lambda function to trigger an Amazon EMR cluster with a Hive execution step (Option A). Since the job only needs to run once per day and completes in about 30 minutes, spinning up a transient EMR cluster means you only pay for…
Question
A company has developed an Apache Hive script to batch process data stared in Amazon S3. The script needs to run once every day and store the output in Amazon S3. The company tested the script, and it completes within 30 minutes on a small local three-node cluster. Which solution is the MOST cost-effective for scheduling and executing the script?
Options
- ACreate an AWS Lambda function to spin up an Amazon EMR cluster with a Hive execution step.
- BUse the AWS Management Console to spin up an Amazon EMR cluster with Python Hue. Hive,
- CCreate an AWS Glue job with the Hive script to perform the batch operation.
- DUse AWS Lambda layers and load the Hive runtime to AWS Lambda and copy the Hive script.
How the community answered
(54 responses)- A83% (45)
- B2% (1)
- C11% (6)
- D4% (2)
Explanation
The most cost-effective solution is to use an AWS Lambda function to trigger an Amazon EMR cluster with a Hive execution step (Option A). Since the job only needs to run once per day and completes in about 30 minutes, spinning up a transient EMR cluster means you only pay for those 30 minutes of compute. Lambda handles the scheduling and cluster creation automatically, and EMR terminates the cluster after the step completes. Option B requires manual intervention and keeps the cluster running. Option C is incorrect because AWS Glue does not natively support Hive scripts - it uses Apache Spark. Option D fails because Lambda has a maximum execution timeout of 15 minutes and does not have the memory or environment to run a full Hive workload.
Topics
Community Discussion
No community discussion yet for this question.