Databases
Relational DB- RDS
Non-relational DB- DynamoDB
OLTP vs OLAP
- OLTP –>
Online Transaction Processing - OLAP –>
Online Analytical Processing
OLTP
- An OLTP system
captures and maintains transaction datain a database - Based on
INSERT, UPDATE, DELETE commands - It emphasis is on
fast processingi.e fast response time - And uses traditional DBMS.
- Both
Sql and No-Sqlare used
OLAP
- OLAP is an online
analysis and data retrieving process - OLAP applies complex queries to large amounts of historical data, aggregated from OLTP databases and other sources, for data mining, analytics, and business intelligence projects.
- Based on
SELECT commandsto aggregate data - Response time varies from seconds, minutes, or hours depending on the amount of data to process
- And uses the data warehouse.
- Redshift, Teradata, Amazon EMR, MapReduce
Amazon Neptune
- Amazon Neptune supports popular graph models Property Graph and W3C’s RDF
- Neptune powers graph use cases such as recommendation engines, fraud detection, knowledge graphs, drug discovery, and network security.
Amazon RDS
- Amazon Relational Database Service
- Provides you with
six database enginesAmazon aurora,MarinaDBMicrosoft SQL ServerMySQl,PostgreSQL,Oracle
- Aurora, Oracle –> has no free trail
- Create Free tier Db
- Easy create > PostgreSQL(any) > Free tier
Amazon Aurora
- Amazon Aurora (Aurora) is a fully managed relational database engine that’s
compatible with MySQL and PostgreSQL - 5 times faster than standard MySQL databases and
- 3 times faster than standard PostgreSQL databases.
Multi AZs Replica
- Currently we have a endpoints connected to a single DB
- Multi AZs Replica allows us to
one or two standby DBinstances- The standby DB instances provide failover support
RDS > Databases > Select DB > Modify DB > Availability & durability- Creates a standby in a different Availability Zone (AZ) to provide data
redundancy, eliminate I/O freezes, and minimize latencyspikes during system backups.
- Creates a standby in a different Availability Zone (AZ) to provide data
- Current and Standby DB will have the
same Endpoints
Read Replicas
- You are creating a replica DB instance from a source DB instance.
- This
new DB instancewill have the source DB instance’s DB security groups and DB parameter groups. - Its
like a Snapshot and can only perfrom read operation - Has
different Endpointsbecause its entirly new DB - NOTE
- In Multi-AZs Replica –> Read Replica may not be available
Amazon DynamoDB
- Amazon DynamoDB is a
fully managed NoSQL databaseservice that provides fast and predictable performance with seamless scalability. - It Offers
- Serverless, Flexible Scheme, Horizontal Scaling
- DynamoDB stream, DAX, Transactions
- Backup, Global Tables
- Its an alternate to MongoDB
- But with more addidtiona feature
- DB is called ad Table in NoSQL
Amazon DynamoDB Accelerator (DAX)
- Fully managed, highly available, in-memory cache for Amazon DynamoDB
- Its like a
Caching-service for DynamoDB - Delivers up to a
10 times performanceimprovement Pricing may br too high
AWS Caching Solutions
- Amazon ElastiCache
- Redis or Memcached is used
- Amazon DynamoDB Accelerator (DAX)
- In-memory cache for DynamoDB
- Amazon CloudFront
- Global content delivery network (CDN) service
- Automatically routed to the nearest edge location
- AWS Greengrass
- Amazon Route 53
Amazon ElastiCache
- Redis
- In-memory data structure store used as database, cache and message broker.
- ElastiCache for Redis offers Multi-AZ with Auto-Failover and enhanced robustness.
- Memcached
- High-performance, distributed memory object caching system, intended for use in speeding up dynamic web applications.
- Redis authentication tokens, or passwords, enable Redis to require a password before allowing clients to run commands, thereby improving data security.
Understanding Database Sharding
- Sharding is a database architecture pattern related to
horizontal partitioning - Each partition has the
same schema and columns, but also entirely different rows
Redshift
- Amazon Redshift is a fast, fully managed, petabyte-scale
data warehouseservice in the cloud - Uses
SQL to analyze structured and semi-structured dataacross data warehouses, operational databases, and data lakes