Module 6: Databases & Data Architecture
Map your SQL Server experience onto the AWS database family: RDS, Aurora, DynamoDB, ElastiCache, DocumentDB, Redshift and S3. You learn to pick the right store for each banking workload, migrate SQL Server schemas and data safely, and connect a .NET API with EF Core, Secrets Manager credentials and least-privilege access.
Assumes: .NET 10 LTS · EF Core 10 · AWS SDK for .NET v4 · Region us-east-1. Verified against official sources on 2026-11-18.
Map your SQL Server experience onto the AWS database family: RDS, Aurora, DynamoDB, ElastiCache, DocumentDB, Redshift and S3. You learn to pick the right store for each banking workload, migrate SQL Server schemas and data safely, and connect a .NET API with EF Core, Secrets Manager credentials and least-privilege access.
| Estimated time | About 20 hours (lessons 12 h · labs 5 h · project 3 h) |
| Priority for you | High — priority 4 (feeds data pipelines and every API you build) |
| Level | Beginner → advanced |
| Certifications | SAA-C03 · DEA-C01 · DVA-C03 |
| Cost profile | 🟢 local containers + DynamoDB · 🟡 small RDS deploy-and-destroy · 🔴 SQL Server licence, Redshift, Aurora Global |
Why this matters in banking
A bank's ledger, customer master and payment history are its most valuable and most regulated assets. A badly chosen database shows up as month-end jobs that never finish, double-posted payments when two writers race, or a restore that takes a day when the business expected an hour. In AWS you also inherit new questions: who can connect, how credentials rotate, whether backups are encrypted with your own key, and how you prove point-in-time recovery works. This module turns the SQL Server instincts you already have into AWS-native decisions you can defend to architects and auditors.
From .NET/Azure to AWS
| You know (Microsoft/Azure) | AWS equivalent | What's different |
|---|---|---|
| SQL Server on a VM / Azure SQL Managed Instance | Amazon RDS for SQL Server | Managed patching and backups; licence-included pricing is much higher than open-source engines |
| Azure SQL Database (serverless) | Aurora PostgreSQL Serverless v2 | Different engine — T-SQL needs conversion, or Babelfish for partial compatibility |
| Always On availability groups | RDS/Aurora Multi-AZ + read replicas | Failover is managed; you choose the topology, not the cluster plumbing |
| Azure Cosmos DB | Amazon DynamoDB | Key-value with single-table design; you model access patterns first |
| Azure Cache for Redis | Amazon ElastiCache (Valkey or Redis OSS) | Valkey is the open-source Redis fork AWS now promotes |
| Azure Synapse dedicated pool | Amazon Redshift / Redshift Serverless | Columnar warehouse; covered more deeply in Module 7 |
| SQL logins in connection strings | IAM database authentication + Secrets Manager | Short-lived tokens or rotated secrets instead of static passwords |
| Data Migration Assistant / SSMA | AWS DMS + DMS Schema Conversion | Managed, cloud-hosted conversion and replication |
| TDE with a key in Key Vault | Storage encryption with an AWS KMS customer managed key | Must be chosen at creation time — you cannot simply switch it on later |
Learning objectives
By the end of this module you can:
- Choose between RDS, Aurora, DynamoDB, ElastiCache, DocumentDB, Redshift and S3 for a given banking workload, and write down why the others were rejected.
- Explain the licensing and cost implications of RDS for SQL Server versus Aurora PostgreSQL or Babelfish.
- Design a DynamoDB single-table model with partition keys, transactions, conditional writes for idempotency, Streams and TTL.
- Configure Multi-AZ, read replicas, automated backups, point-in-time recovery and KMS encryption — and prove a restore works.
- Connect a .NET 10 API through EF Core with Secrets Manager credentials or IAM authentication, pooled through RDS Proxy.
- Run EF Core migrations safely in a pipeline and compare isolation levels and consistency models with what you know from SQL Server.
- Plan a SQL Server migration with DMS and DMS Schema Conversion, including change data capture for cut-over.
Prerequisites
- Module 2: Networking — private subnets, security groups, VPC endpoints
- Module 3: .NET on AWS — DI-registered SDK clients, configuration and secrets
- Recommended: the KMS and Secrets Manager lessons of Module 5
- Assumed knowledge: SQL, indexing, transactions and EF Core from your day job
How the pieces fit
The usual banking pattern is a relational core (RDS or Aurora) for accounts and the ledger, DynamoDB for idempotency keys and high-volume lookups, ElastiCache for hot reads, and S3 as the long-term analytical store.
Lessons
Teaching order. Each lesson links to the next, and the module project lab comes last.
- Choosing a database: SQL vs NoSQL on AWS — a decision framework built on access patterns, consistency, scale and cost, not fashion.
- SQL Server on AWS: RDS, EC2, Aurora PostgreSQL and Babelfish compared — side-by-side table of features, HA options, backup models, tooling and licensing.
- Amazon RDS for SQL Server and PostgreSQL — editions, licence models, parameter groups, option groups and maintenance windows.
- Amazon Aurora — storage architecture, endpoints, Serverless v2 scaling and Aurora Global Database for cross-Region reads and DR.
- Multi-AZ, read replicas, backups and point-in-time recovery — what each protects against, and a restore drill you can repeat.
- Encryption and database access — KMS customer managed keys at rest, verified TLS in transit, IAM database authentication and Secrets Manager credentials with rotation.
- Connection pooling and RDS Proxy — why Lambda and autoscaled containers exhaust connections, and how Proxy and ADO.NET pooling interact.
- EF Core on AWS — provider choice, retry strategies, migrations in CI/CD, and changing a busy table without long locks.
- Transactions, isolation levels and consistency — SQL Server defaults vs PostgreSQL MVCC vs DynamoDB eventual and strong reads.
- Amazon DynamoDB fundamentals — partition and sort keys, capacity modes, single-table design for customers, accounts and transactions.
- DynamoDB for banking correctness — transactions, conditional writes for idempotency keys, Streams for change events and TTL for expiring records.
- Amazon ElastiCache (Valkey/Redis OSS) — cache-aside, session state, rate-limit counters and what must never be cached.
- Amazon DocumentDB — when a document model fits (product catalogues, onboarding forms) and its MongoDB-compatibility caveats.
- Amazon Redshift and S3 as data stores — warehouse vs data lake, and why most history should leave the OLTP database.
- Performance optimisation — CloudWatch Database Insights (the successor to Performance Insights), indexing, query plans and parameter sniffing.
- Database migration — AWS DMS full load + CDC, DMS Schema Conversion for T-SQL to PostgreSQL, Babelfish for Aurora PostgreSQL, and validation.
- Lab 6: Harbourline banking data store — the module project, walked through step by step.
Finally, the Module 6 cheat sheet is a printable one-page revision summary.
Labs and module project
The runnable code is in the folder labs/m06-banking-data-store (solution BankingDataStore.slnx, with docker-compose.yml, infra/ and docs/). Its suite has 46 tests: 44 pass and 2 are skipped by design, the AWS smoke test and the PostgreSQL integration test, which each need opt-in settings. Everything else runs with no AWS account. The lab page Lab 6 walks through it.
Some code listings in the lessons are fragments, not whole projects. For example, Account.cs and DebitHandler.cs in Transactions, isolation levels and consistency need a LedgerDbContext; the lab project contains the complete version.
The original plan listed five small labs. They are folded into the lesson exercises and the project; none has its own page.
| Planned lab | Where it lives now |
|---|---|
| 6.1 (🟢) SQL Server and PostgreSQL in Docker, seeded data, query plans | Exercises in Transactions, isolation levels and consistency and Performance optimisation |
| 6.2 (🟢) DynamoDB Local single-table design and duplicate-payment rejection | Exercises in DynamoDB fundamentals and DynamoDB for banking correctness |
| 6.3 (🟡) Small RDS for PostgreSQL, KMS, Secrets Manager, snapshot and restore | The cloud half of Lab 6, plus Multi-AZ, read replicas, backups and PITR |
| 6.4 (🟡) DynamoDB Streams triggering a .NET Lambda audit writer | Optional Streams deployment in DynamoDB for banking correctness |
| 6.5 (🟢) Design-only migration assessment | Exercises in Database migration |
Module project — banking data store. Create a customer / account / transaction database on the service you justify (RDS PostgreSQL or DynamoDB, with a written ADR). Connect it to the Module 3 .NET API with EF Core (or the SDK for DynamoDB), Secrets Manager credentials, a least-privilege IAM role and encrypted storage. Include a restore test and an idempotent "post transaction" endpoint. Fictional data only. This is Lab 6.
Cost profile
| Part | Label | Free alternative |
|---|---|---|
| SQL Server / PostgreSQL design, query plans, EF Core migrations | 🟢 free | Docker containers on your machine |
| DynamoDB tables for labs | 🟢 free | DynamoDB Local, or the always-free DynamoDB allowance for small tables |
| RDS for PostgreSQL (smallest eligible class) | 🟡 credits | Deploy, test and delete the same day; snapshots also cost storage — delete them |
| RDS for SQL Server (licence-included) | 🔴 paid | SQL Server Developer edition in Docker; RDS SQL Server is design-only |
| RDS Proxy, Aurora Serverless v2 | 🟡 credits | Short deploy-and-destroy; otherwise design-only with the Lab 6.1 containers |
| Aurora Global Database, DocumentDB, Redshift | 🔴 paid | Design-only exercise with diagrams and an ADR |
| ElastiCache | 🟡 credits | Valkey or Redis in Docker locally |
| DMS replication instance | 🔴 paid | Design-only; DMS Schema Conversion itself has no additional charge |
| Secrets Manager secret | 🟡 credits | Parameter Store SecureString for the lab; rotation explained design-only |
Certification alignment
| Exam | Domains (weight) | What this module covers |
|---|---|---|
| SAA-C03 | Resilient (26%) · High-Performing (24%) | Multi-AZ, replicas, Aurora, DynamoDB, caching and database selection |
| DEA-C01 | Store (26%) | Data store choice, DynamoDB modelling, Redshift basics, migration with DMS |
| DVA-C03 | Development (30%) | DynamoDB APIs from the SDK, conditional writes, caching patterns |
The domain labels are short forms; see each exam page for the official wording.
Service availability notes
Migration tooling names — verified 2026-11-17
DMS Schema Conversion is the managed schema-conversion feature inside AWS DMS, available at no additional charge. It now offers generative-AI-assisted conversion and, since July 2026, an offline SQL Server source (convert from extracted metadata without a live connection).
The standalone desktop AWS Schema Conversion Tool (AWS SCT) still has documentation, and no deprecation notice was found, but AWS's investment is clearly in DMS Schema Conversion ⚠ VERIFY current AWS SCT status before teaching it.
ElastiCache supports both Valkey and Redis OSS engines; labs use Valkey.
Compliance review required
Encryption, backup retention and data residency settings in this module are technical controls only. Retention periods, the right to erasure under UK GDPR and record-keeping obligations must be set with your bank's data-protection and compliance teams.
Key AWS services
Amazon RDS (SQL Server, PostgreSQL) · Amazon Aurora (PostgreSQL, MySQL, Serverless v2, Global Database) · Babelfish for Aurora PostgreSQL · Amazon DynamoDB (Streams, TTL, transactions) · Amazon ElastiCache (Valkey, Redis OSS) · Amazon DocumentDB · Amazon Redshift · Amazon S3 · Amazon RDS Proxy · AWS Database Migration Service + DMS Schema Conversion · AWS KMS · AWS Secrets Manager · CloudWatch Database Insights (and the Performance Insights API) · Amazon CloudWatch
Independent learning resource — not affiliated with, endorsed or sponsored by Amazon Web Services. AWS and related marks are trademarks of Amazon.com, Inc. or its affiliates. All banking data in examples is fictional. Sample architectures are for learning and are not automatically compliant with GDPR, PCI DSS or any banking regulation.
Module 5 cheat sheet
One-page revision summary for Security for Banking & Finance: services, Azure mapping, CLI commands, limits, decision rules, exam traps and cost traps.
Choosing a database: SQL vs NoSQL on AWS
Use a repeatable decision framework (access patterns, consistency, scale, operations and cost) to choose between RDS, Aurora, DynamoDB, ElastiCache, DocumentDB, Redshift and S3 for a banking workload, and record the choice in an ADR.