Athena Federated Query with Amazon RDS
Athena Federated Query with Amazon RDS

CLOUD LABS

Athena Federated Query with Amazon RDS

In this Cloud Lab, you’ll launch an Aurora MySQL instance in Amazon RDS and connect it with an EC2 instance to insert some records in our database. You’ll then use Amazon Athena to run federated queries and fetch data from our database.

10 Tasks

intermediate

1hr 30m

Certificate of Completion

Desktop OnlyDevice is not compatible.
No Setup Required
Amazon Web Services

Learning Objectives

An understanding of Amazon Athena with basic features
Hands-on experience setting up an RDS Instance
Hands-on experience creating a MySQL data source in Athena
The ability to execute federated query using Amazon Athena

Technologies
AWS logoAWS
Athena
RDS
Aurora MySQL
Lambda logoLambda
S3 logoS3
Cloud Lab Overview

Amazon Athena is an interactive query service that simplifies the process of querying data stored in different locations. The queries in Athena are based on metadata, which is data about the underlying data in a database. Athena supports federated queries, allowing it to work with distributed data sources. This is done by creating connectors in AWS Lambda.

In this Cloud Lab, you’ll provision an EC2 instance and an Aurora DB cluster with a MySQL-compatible database. You’ll also create a spill bucket in S3 and an IAM role. After that, you’ll deploy a connector using a Lambda application and then use your Aurora DB cluster as a data source in Athena. Finally, you’ll execute queries in a query editor provided by Athena to fetch data from your database.

After completing this Cloud Lab, you’ll be able to work with Amazon RDS and Athena to create database instances and execute federated queries using the query editor.

The following is the high-level architecture diagram of the infrastructure you’ll create in this Cloud Lab:

Architecture diagram
Architecture diagram
Cloud Lab Tasks
1.Introduction
Getting Started
2.Create the Required Resources
Create a Bucket and a Role
Launch an EC2 Instance
3.Create a Database in RDS
Create an RDS Instance
Connect EC2 with RDS
Create a VPC Endpoint
4.Federated Queries in Athena
Create a Data Source
Run a Federated Query
5.Conclusion
Clean Up
Wrap Up
Labs Rules Apply
Stay within resource usage requirements.
Do not engage in cryptocurrency mining.
Do not engage in or encourage activity that is illegal.

Relevant Courses

Use the following content to review prerequisites or explore specific concepts in detail.

Trusted by 1.4 million developers working at companies including

Don’t take our word for it. See what our developers have to say.

Your method is simple, straight to the point and I can practice with it everywhere, even from my phone, that's something I have never had in other learning platforms.

Felipe Matheus
TestimonialsImg

I highly recommend Educative. The courses are well organized and easy to understand.

Adina Ong
TestimonialsImg

I prefer Educative courses because they have a nice mix of text & images. I find that with full video courses, it can often be too easy to go into passive learning mode.

Clifford Fajardo
TestimonialsImg

I prefer Educative courses because they have a nice mix of text & images. I find that with full video courses, it can often be too easy to go into passive learning mode.

Clifford Fajardo
TestimonialsImg
Don’t take our word for it. See what our developers have to say.

Your method is simple, straight to the point and I can practice with it everywhere, even from my phone, that's something I have never had in other learning platforms.

Felipe Matheus
TestimonialsImg

I highly recommend Educative. The courses are well organized and easy to understand.

Adina Ong
TestimonialsImg

I prefer Educative courses because they have a nice mix of text & images. I find that with full video courses, it can often be too easy to go into passive learning mode.

Clifford Fajardo
TestimonialsImg

Get access to Educative Cloud Labs

Course Footer Image
Course Footer Image