AWS Databases

AWS Database Migration Service (DMS) Overview

AWS Database Migration Service (DMS) helps you migrate databases to AWS easily and securely. The source database remains fully operational during the migration, minimizing downtime to applications. DMS can migrate your data to and from most widely used commercial and open-source databases.

Database Migration Service (DMS) support following use case types:

  1. Homogenous migrations such as Oracle to Oracle

  2. Heterogeneous migrations such as Oracle to Amazon Aurora or Microsoft SQL Server to MySQL.

Amazon ElastiCache Overview

Amazon ElastiCache is a fully managed, in-memory data store and cache in the cloud. It can provide sub-millisecond latency to power real-time applications.

The ElastiCache service improves the performance of web applications by allowing you to retrieve information from fast, managed, in-memory data stores. Using Amazon ElastiCache, you can add an in-memory layer to your infrastructure in a matter of minutes by using the AWS Management Console.

Amazon Relational Database Service (RDS) Overview

Amazon Relational Database Service (Amazon RDS) is a managed relational database service with a choice of six popular database engines, namely, Amazon Aurora, PostgreSQL, MySQL, MariaDB, Oracle, and Microsoft SQL Server. Amazon RDS is available on several database instance types - optimized for memory, performance or I/O.

DynamoDB Operations Overview

Will discuss the basic DynamoDB operations such as create table, and CRUD operations such as insert, read, update and delete.

 

Creating Table

Can create table using Management Console or CreateTable API.

 

Insert Data

Can use the PutItem or BatchWriteItem APIs.

PutItem API is idempotent.

 

[Lab] Working with DynamoDB Tables from AWS CLI

We will execute various example commands on the table we already created in previous lab. We will also delete and create the table again through command line.

This lab assumes you have followed previous labs and created a user with necessary permissions, installed awscli, created and setup profile in local, and created the table.

 

Find all commands available

aws dynamodb ?

 

DynamoDB APIs Overview

Following is the list of DynamoDB APIs:

  1. CreateTable

    1. Creates a table and specifies the primary index.

  2. UpdateTable

    1. Updates the provisioned throughput values for table.

  3. DeleteTable

    1. Deletes a table.

  4. DescribeTable

DynamoDB Data Model Overview – Table, Item, Attribute and Data Types

Data model for DynamoDB comprises of tables, items (rows) and attributes.

 

Table

A table is a collection of data items.

Table can have a single primary key called partition key or a composite key which contains both partition key and sort key.

 

Item (row)

An item is synonymous to a row in a traditional database.

DynamoDB - Introduction and Important Features

DynamoDB is a fully managed distributed NoSQL database service that can scale without limits. DynamoDB automatically partitions and re-partitions your data as your table size grows. DynamoDB is the most popular NoSQL cloud database according to Forrester, as of Jan 2017.

DynamoDB synchronously replicates data across three facilities in an AWS Region, for high availability, and unlike many NoSQL databases, even allows you to specify the read consistency for reads across these facilities. Default however is eventual consistency.