AWSome Day 2018
Scale-out your Database
AWSome Day - Torino 2018
Walter Dal Mut
Solution Architect - AWS Certified
SysOps Administrator - AWS Certified
@walterdalmut
walter.dalmut@corley.it
corley.it
Scalability and cost optimization with Container Services
RDS
Replication
DynamoDB
Summary
AWS RDS
Relational Database Service
(Oracle/Mysql/Postgres/etc…)
Interesting features
➢ Read-replicas (1 click)
➢ Multi-AZ deployments (1 click)
➢ Configuration versioning
➢ Scale-up & reconfiguration (1 click)
➢ Maintenance Windows
➢ Continuous Data Protection
Why we are interested in Scale-Out databases?
We need more resources
➢ Single hard drives has limits
➢ Networks too
➢ and so on...
We want to ensure
SERVICE availability
NOT SERVER
availability
Relational Databases works
(typically) with replication,
which kind of replications?
How many kinds of
replications?
Synchronous Replication
➢ a process that writes data to the
primary and secondaries at the SAME
time
○ expensive process
○ ensure data consistency
Asynchronous Replication
➢ a process that writes data to the
primary and on all secondaries at
different times
○ LAG (measure data discordance)
Thanks to RDS we can achieve
both Sync and Async
replication strategies with one
click
➢ Different Availability Zones
➢ Different Regions (read-replicas)
➢ API First
➢ So many scenarios for your processes
Scale with read-replicas
Read-Replicas
Increase Read Capacity
Here a real example
Here a real example
And write intensive?
And write intensive?
And write intensive?
It works?
Yes?
How can i scale writes?
We need to look into database
shardings
➢ Primary key selection
➢ Scale-out writes
➢ Scale-out reads
➢ many other things...
AWS DynamoDB
NoSQL databases
NoSQL
var documentClient = new AWS.DynamoDB.DocumentClient();
var params = {
Item: {
hashkey: 'hashkey'
numbers: documentClient.createSet([1, 2, 3]);
}
};
documentClient.put(params, (err, data) => { /** .. */ });
Database shards
DynamoDB - Scaling for Reads
and Writes
➢ Select index read/write speed
➢ Pay only for index read/write speed
➢ Pay only for your database size
➢ Autoscaling on your index speed to
support cost-saving
Streams to support data more
operations!
➢ On row updates we can engage
triggers
➢ A trigger can be anything like:
Lambda, SNS, and so many other
things
Stream notification enable so many new scenarios
Thanks for listening.
AWSome Day - Torino 2018 - walter.dalmut@corley.it

AWSome day 2018 - database in cloud