Monday, August 25, 2025

AWS Databases Types & Choosing the Right Option | Overview


AWS Databases Types & Choosing the Right Option - Overview.

Scope:

  • Intro,
  • Types of Databases in AWS,
  • Relational Databases (SQL),
  • NoSQL Databases (Key-Value, Document, Wide Column),
  • In-Memory Databases,
  • Graph Databases,
  • Ledger Databases,
  • Analytics/OLAP Databases,
  • Table for choosing the right database for workload,
  • Quick Cheat Sheet.

Intro:
    • AWS offers a wide array of purpose-built databases, each optimized for specific data models and application requirements
    • Choosing the right option depends on twtech data's structure, performance needs, query patterns, and scalability requirements. 

1. Types of Databases in AWS


NB:

  • AWS databases are broadly categorized into:
    • Relational
    • NoSQL
    • In-memory
    • Graph
    • Ledger
    • Analytics/OLAP
Here's a breakdown:

A. Relational Databases (SQL)

  • Purpose: Structured data with relationships, ACID transactions.
  • AWS Services:
    • Amazon RDS – Managed relational databases (MySQL, PostgreSQL, MariaDB, Oracle, SQL Server).
    • Amazon Aurora – High-performance, fully managed MySQL/PostgreSQL-compatible database.
  • Use Cases:
    • E-commerce transactions
    • Financial systems
    • Applications requiring complex joins and constraints
  • Pros: ACID compliance, mature SQL ecosystem
  • Cons: Scaling writes horizontally is harder (Aurora can scale better)

B. NoSQL Databases (Key-Value, Document, Wide Column)

  • Purpose: Unstructured/semi-structured data, high throughput, low latency.
  • AWS Services:
    • Amazon DynamoDB – Key-value and document store; fully managed, serverless.
    • Amazon Keyspaces – Managed Apache Cassandra-compatible wide-column store.
  • Use Cases:
    • Session management
    • Gaming leaderboards
    • IoT data
    • Event-driven architectures
  • Pros: Scales horizontally, low-latency, flexible schema
  • Cons: Limited relational queries (joins), eventual consistency in some cases

C. In-Memory Databases

  • Purpose: Ultra-low latency, caching, transient or frequently accessed data.
  • AWS Services:
    • Amazon ElastiCache (Redis or Memcached)
  • Use Cases:
    • Caching web sessions
    • Real-time analytics
    • Leaderboards
  • Pros: Extremely fast reads/writes
  • Cons: Data is usually volatile (though Redis supports persistence)

D. Graph Databases

  • Purpose: Relationships and connections between entities.
  • AWS Services:
    • Amazon Neptune – Fully managed graph DB (supports Property Graph and RDF/SPARQL).
  • Use Cases:
    • Social networks
    • Fraud detection
    • Recommendation engines
  • Pros: Efficient traversal of relationships
  • Cons: Not ideal for general-purpose structured or document data

E. Ledger Databases

  • Purpose: Immutable, cryptographically verifiable transaction logs.
  • AWS Services:
    • Amazon QLDB – Fully managed ledger DB.
  • Use Cases:
    • Financial transactions
    • Supply chain tracking
    • Auditing systems
  • Pros: Integrity and verifiability of data
  • Cons: Specialized use cases

F. Analytics/OLAP Databases

  • Purpose: Complex analytics, aggregations over large datasets.
  • AWS Services:
    • Amazon Redshift – Columnar data warehouse, high-performance analytics.
    • Amazon Athena – Query data in S3 using SQL, serverless.
    • Amazon Timestream – Time-series database for IoT and metrics.
  • Use Cases:
    • Data warehouses
    • IoT telemetry analysis
    • Business intelligence dashboards
  • Pros: Optimized for large-scale analytics
  • Cons: Not ideal for transactional workloads

2. Table for Choosing the Right Database 

Consider these factors:

Factor

Questions to Ask

Examples

Data Structure

Is it relational, key-value, document, graph?

RDS for structured, DynamoDB for key-value

Query Patterns

Complex joins or simple key lookups?

Aurora for joins, DynamoDB for simple lookups

Scale & Performance

Need horizontal scale, low latency?

DynamoDB, ElastiCache

Transactions

Require ACID guarantees?

Aurora, RDS

Analytics

Batch vs real-time analytics?

Redshift for batch, Timestream for time-series

Cost & Management

Fully managed vs self-managed

RDS and DynamoDB are fully managed

Access Pattern

Random reads/writes vs sequential writes

DynamoDB for random, Timestream for sequential

Quick Cheat Sheet

Workload

Best AWS Database

Online transactions with complex relationships

RDS / Aurora

Massive scale key-value or document

DynamoDB

Ultra-fast caching

ElastiCache (Redis)

Graph relationships

Neptune

Immutable, verifiable ledger

QLDB

Big data analytics

Redshift / Athena / Timestream






No comments:

Post a Comment

Amazon EventBridge | Overview.

Amazon EventBridge - Overview. Scope: Intro, Core Concepts, Key Benefits, Link to official documentation, Insights. Intro: Amazon EventBridg...