Easy ReviewDOP-C02
Resilient Cloud Solutions8

MemoryDB

Use a durable in-memory database with replication and failover.

Este conteúdo de estudo ainda não foi traduzido, então aparece em inglês. Ajude a traduzir

MemoryDB combines in-memory access with a Multi-AZ transactional log and optional Multi-Region replication.

Durable in-memory workloads

Amazon MemoryDB is a durable in-memory database compatible with Valkey and Redis OSS. It can act as a primary database rather than a cache in front of one.

How it works

  1. A cluster divides its data into shardsA shard is a partition of a MemoryDB dataset with a primary node and optional replicas., or partitions. Each shard has a primary node that accepts writes and optional read-only replicasA read replica maintains a copy of a shard's data and serves reads..
  2. Before returning a successful write, the primary stores it in a transactional log, a record of changes distributed across Availability Zones. Replicas use the log to update asynchronously, meaning they can lag behind the primary.
  3. If a primary fails, a replica can become the new primary. Place the primary and replicas in different Availability Zones for fault tolerance.
  4. For active-active access, where applications read and write locally in multiple Regions, MemoryDB Multi-Region replicates changes asynchronously across Regions. A conflict-free replicated data typeA conflict-free replicated data type can be updated independently and concurrently without coordination. reconciles concurrent changes.

Exam cues

  • If the question says a durable Valkey-compatible primary database, think MemoryDB, because it stores data in memory and writes to a Multi-AZ log.
  • If the question says read the latest successful writes after failover, think primary node, because primary reads remain strongly consistentStrongly consistent primary reads reflect all earlier successful writes. while replica reads are eventually consistentAn eventually consistent replica might not yet reflect the most recent successful write..
  • If the question says local writes in multiple Regions, think MemoryDB Multi-Region, because it provides active-active access with asynchronous replication.
  • If the question says restore a previous point, think snapshotA MemoryDB snapshot is a point-in-time copy of cluster data and metadata., because a new cluster can be created from it.

Remember

  • A shard has one primary. The default is one replica, and the maximum is five.
  • Without a replica, a failed primary must be replaced and synchronized before writes resume.
  • A cluster is regional; Multi-Region is a separate active-active configuration.
  • Valkey support arrived in October 2024; MemoryDB Multi-Region launched in December 2024.
  • Snapshots contain data and cluster metadata and are stored in S3.

Trap: ElastiCache is commonly a cache, but node-based ElastiCache for Valkey can also be a durable data store when durability is enabled. Do not select MemoryDB solely because durability is required.

MemoryDB shard replication
12Primary nodeMulti-AZ logRead replica
  1. The primary stores successful writes in the Multi-AZ transactional log before responding.

  2. Read replicas replicate asynchronously using transaction logs and can be promoted on primary failure.

Da documentação da AWS (13)
  • MemoryDB is a durable in-memory database compatible with Valkey and Redis OSS that can serve as a primary database.
  • Successful writes are durably stored in a distributed Multi-AZ transactional log before the primary responds to the client.
  • Primary reads are strongly consistent across primary failovers; replica reads are eventually consistent.
  • Each shard has a read-write primary and optional read-only replicas that replicate asynchronously using transaction logs.
  • A failed primary can fail over to a replica, which becomes the new primary for its shard.
  • If a primary in a shard without replicas fails, MemoryDB stops accepting writes until the primary is replaced and synchronized from the transaction log.
  • A MemoryDB cluster is regional; placing primary and replica nodes in multiple Availability Zones improves fault tolerance.
  • MemoryDB Multi-Region supports active-active local reads and writes in multiple Regions and asynchronously replicates between them.
  • MemoryDB Multi-Region uses conflict-free replicated data types to reconcile concurrent writes with eventual consistency.
  • MemoryDB point-in-time snapshots contain cluster metadata and data, are stored in S3, and can restore a new cluster.
  • ElastiCache is commonly used as a cache, and node-based ElastiCache for Valkey can also be a durable data store when durability is enabled.
  • The default is one replica per MemoryDB shard and the maximum is five replicas.
  • MemoryDB added Valkey support in October 2024 and launched Multi-Region in December 2024.

Flashcards

toque para virar
Resposta

·

Todos os 8 flashcards em lista

A workload needs a Valkey-compatible primary database with local writes in multiple AWS Regions. Which service fits?

MemoryDB Multi-Region. It supports active-active regional reads and writes with asynchronous replication.

Which AWS managed in-memory database can serve as a durable primary database for Redis OSS or Valkey applications?

Amazon MemoryDB. It stores data in memory and uses a Multi-AZ transactional log.

A MemoryDB application must read the latest successful writes after a primary failover. Which node should it read?

The primary. Primary reads are strongly consistent across failovers; replica reads are eventually consistent.

How can a MemoryDB shard recover from a primary node failure?

A replica can be promoted to primary. Place primary and replica nodes across Availability Zones for fault tolerance.

Does a MemoryDB Multi-Region write immediately appear in every Region?

No. Replication between Regions is asynchronous and concurrent writes are reconciled with eventual consistency.

How can a MemoryDB cluster be restored to an earlier point?

Create a new cluster from a snapshot. Snapshots contain data and cluster metadata.

How does Amazon MemoryDB keep successful writes durable if a primary fails?

It stores successful writes in a distributed Multi-AZ transaction log before responding. A replica can become the new primary.

A MemoryDB shard has no replicas and its primary fails. Can it immediately accept writes?

No. Writes stop until the primary is replaced and synchronized from the transaction log.

Você concluiu todos os tópicos da DOP-C02!

Seu badge ficou dourado. Próximo passo: agendar a prova na AWS. Depois de passar, adicione-se ao Quem passou.

Compartilhar

Conte que você concluiu esta certificação

Concluí todos os tópicos da AWS Certified DevOps Engineer - Professional (DOP-C02) no Easy Review. Venha estudar também!