Neptune and QLDB
Understand the roles of graph databases (Neptune) and ledger databases (QLDB) in AWS, including important status updates.
Some services in this lesson have no free tier and will incur charges.
AWS Services Used
Learning outcomes
By the end of this lesson, you will be able to:
- Explain what Amazon Neptune is.
- Explain what Amazon QLDB was designed for.
- Distinguish between a graph database and a ledger database.
- Recognize common Neptune use cases like recommendation engines and fraud detection.
- Understand the current status of QLDB and why the concept still matters.
Specialized data models
Neptune is for connected relationships. QLDB was for verifiable history.
Neptune solves graph-style problems where the connections between entities matter most, while QLDB was built for ledger-style problems where an immutable, cryptographically verifiable history is required.
A simple memory rule:
- Neptune = Relationship database.
- QLDB = History-proof ledger database (Conceptual).
1) What is Amazon Neptune?
Amazon Neptune is a fast, reliable, fully managed graph database service. It is optimized for storing billions of relationships and querying graphs with millisecond latency.
When to use a Graph Database?
You should think of Neptune when the "links" between your data are just as important as the data itself. AWS highlights these common use cases:
- Recommendation Engines: "People who liked this movie also liked..."
- Fraud Detection: Identifying patterns of suspicious transfers between accounts.
- Knowledge Graphs: Mapping complex concepts and how they relate.
- Network Security: Visualizing connections between devices and users.
2) Neptune's Languages
Neptune supports popular graph query languages, so you don't have to learn a proprietary AWS language:
- Gremlin and openCypher: Used for "Property Graphs" (most common).
- SPARQL: Used for "RDF Graphs" (data used in semantic web applications).
3) What was Amazon QLDB?
Amazon QLDB (Quantum Ledger Database) was built around an immutable, append-only journal. Every change to your data was saved in a verifiable log that could be cryptographically checked for tampering.
Warning
⚠️ Status Update: AWS documentation now carries an end-of-support notice for QLDB (July 31, 2025). While it is no longer recommended for new projects, the concept of a ledger database remains a core cloud architectural principle.
Why the concept matters:
Traditional databases allow you to "overwrite" data. In a ledger database, you keep a permanent record of every state the data has ever been in. This is critical for:
- Audit Trails: Proving who changed what and when.
- Data Integrity: Using cryptographic hashing (like SHA-256) to ensure history hasn't been faked.
4) Biggest Difference
| Feature | Amazon Neptune | Amazon QLDB (Concept) |
|---|---|---|
| Main Idea | Connected Relationships | Verifiable History |
| Best Question | "How are these entities linked?" | "Can I prove what happened?" |
| Data Model | Nodes and Edges | Append-only Journal |
| Current Status | Primary Graph Service | End-of-Support Noted |
Micro-activity 1: Pick the Better Fit
Neptune vs. QLDB Concept
Based on the requirement, which service idea is the best fit?
Examples
Choose one, then match it on the right
Characteristics
Select an example first
0 of 5 matched so far.
Micro-activity 2: Query Languages & Concepts
Terminology Check
Match the term to its role in specialized databases.
Examples
Choose one, then match it on the right
Characteristics
Select an example first
0 of 4 matched so far.
Summary
Amazon Neptune is your go-to for relationships—it's fast, managed, and speaks the standard languages of the graph world. Amazon QLDB introduced the cloud to the ledger concept—a way to have an unchangeable, provable history of data. While QLDB is reaching its end-of-life, the need for auditability and data integrity remains as important as ever.
Knowledge Check
Next lesson
Lesson 4.18: Databases and Data Services Review Quiz