Amazon Aurora tutorials and sample code
The Amazon documentation includes several tutorials that guide you through common Amazon Aurora use cases. Many of these tutorials show you how to use Amazon Aurora with other Amazon services. In addition, you can access sample code in GitHub.
You can find more tutorials at the Amazon Database Blog
Topics
Tutorials in this guide
The following tutorials in this guide show you how to perform common tasks with Amazon Aurora:
-
Tutorial: Create a VPC for use with a DB cluster (IPv4 only)
Learn how to include a DB cluster in a virtual private cloud (VPC) based on the Amazon VPC service. In this case, the VPC shares data with a web server that is running on an Amazon EC2 instance in the same VPC.
-
Tutorial: Create a VPC for use with a DB cluster (dual-stack mode)
Learn how to include a DB cluster in a virtual private cloud (VPC) based on the Amazon VPC service. In this case, the VPC shares data with an Amazon EC2 instance in the same VPC. In this tutorial, you create the VPC for this scenario that works with a database running in dual-stack mode.
-
Tutorial: Create a web server and an Amazon Aurora DB cluster
Learn how to install an Apache web server with PHP and create a MySQL database. The web server runs on an Amazon EC2 instance using Amazon Linux, and the MySQL database is an Aurora MySQL DB cluster. Both the Amazon EC2 instance and the DB cluster run in an Amazon VPC.
-
Tutorial: Restore an Amazon Aurora DB cluster from a DB cluster snapshot
Learn how to restore a DB cluster from a DB cluster snapshot.
-
Tutorial: Use tags to specify which Aurora DB clusters to stop
Learn how to use tags to specify which Aurora DB clusters to stop.
-
Tutorial: Log DB instance state changes using Amazon EventBridge
Learn how to log a DB instance state change using Amazon EventBridge and Amazon Lambda.
Tutorials in other Amazon guides
The following tutorials in other Amazon guides show you how to perform common tasks with Amazon Aurora:
Some of the tutorials use Amazon RDS DB instances, but they can be adapted to use Aurora DB clusters.
-
Tutorial: Aurora Serverless in the Amazon AppSync Developer Guide
Learn how to use Amazon AppSync to provide a data source for running SQL commands against Aurora Serverless DB clusters with the Data API enabled. You can use Amazon AppSync resolvers to run SQL statements against the Data API with GraphQL queries, mutations, and subscriptions.
-
Tutorial: Rotating a Secret for an Amazon Database in the Amazon Secrets Manager User Guide
Learn how to create a secret for an Amazon database and configure the secret to rotate on a schedule. You trigger one rotation manually, and then confirm that the new version of the secret continues to provide access.
-
Tutorial: Configuring a Lambda function to access Amazon RDS in an Amazon VPC in the Amazon Lambda Developer Guide
Learn how to create a Lambda function to access a database, create a table, add a few records, and retrieve the records from the table. You also learn how to invoke the Lambda function and verify the query results.
-
Tutorials and samples in the Amazon Elastic Beanstalk Developer Guide
Learn how to deploy applications that use Amazon RDS databases with Amazon Elastic Beanstalk.
-
Using Data from an Amazon RDS Database to Create an Amazon ML Datasource in the Amazon Machine Learning Developer Guide
Learn how to create an Amazon Machine Learning (Amazon ML) datasource object from data stored in a MySQL DB instance.
-
Manually Enabling Access to an Amazon RDS Instance in a VPC in the Amazon QuickSight User Guide
Learn how to enable Amazon QuickSight access to an Amazon RDS DB instance in a VPC.
Tutorials and sample code in GitHub
The following tutorials and sample code in GitHub show you how to perform common tasks with Amazon Aurora:
Some of the tutorials use Amazon RDS DB instances, but they can be adapted to use Aurora DB clusters.
-
Creating a Job Posting Site using Amazon Aurora and Amazon Translation Services
Learn how to create a web application that stores and queries data by using Amazon Aurora, Elastic Beanstalk, and SDK for Java 2.x. The application created in this Amazon tutorial is a job posting web application. This application lets an employer, an administrator, or human resources staff alert employees or the public about a job opening within a company.
-
Creating an Aurora Serverless v1 lending library
Learn how to create a lending library application where patrons can borrow and return books. The example uses Aurora Serverless v1 and Amazon SDK for Python (Boto3).
-
Learn how to create a Spring REST API that queries Aurora Serverless v1 data. It's for use by a React application using SDK for Java 2.x.
-
Learn how to create an application that uses the
RdsDataClient
of the Data API and Aurora Serverless v1 to track and report on work items. The example uses Amazon SDK for PHP. -
Learn how to create an application that uses the
RdsDataClient
of the Data API and Aurora Serverless v1 to track and report on work items. The example uses Amazon SDK for Python (Boto3).
Using this service with an Amazon SDK
Amazon software development kits (SDKs) are available for many popular programming languages. Each SDK provides an API, code examples, and documentation that make it easier for developers to build applications in their preferred language.
For examples specific to this service, see Code examples for Aurora using Amazon SDKs.