How it works...

When you create a Neptune cluster to host your graph data, several resources are created and managed for you:

  • The primary database instance: This database is available for both reads and writes.
  • Read replicas: You can create up to 15 read replicas. As the name implies, these instances can only be used for reads, allowing you to scale out read-intensive workloads. If the primary database instance fails, Neptune fails over to one of the read replicas, which gives it a reported availability of 99.99%.
  • Cluster volumes: The data is stored across multiple AZs for high availability. All database instances, both the primary and the read replicas, connect to the same cluster volume. If a disk fails in the underlying storage system, it is automatically repaired by Neptune without causing downtime.

Neptune allows you to encrypt the data with Key Management Service (KMS) keys, which are applied not only to the primary cluster volumes but also to snapshots and any other copies of the database.

You connect to your Neptune cluster using one of several endpoints, which are URLs dedicated to a specific purpose:

  • The cluster endpoint is the read/write connection to the primary database instance.
  • The reader endpoint provides round-robin connections to all readable database instances. It cannot be used for writes. Note that the way the round-robin works is by changing the DNS record to resolve to a different IP address, so clients that cache the DNS record will keep connecting to the same replica.
  • Instance endpoints point to specific cluster replica instances. Normally, you won't need these endpoints, but in some scenarios, it may make sense to connect directly to a replica.

Neptune allows you to use two popular query languages (although they cannot be intermixed):

  • Apache Tinkerpop Gremlin is a popular graph traversal language.
  • SPARQL allows you to query the Resource Definition Framework (RDF) graphs.

Advocates for graph databases claim that they are a more natural way to represent real-world objects and could eventually rival the popularity of relational databases. It's worth spending some time to acquaint yourself with Neptune so that you can recognize valid use cases and administer graph databases successfully.

..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset