Skip to main content
PreparationZone Logo
PrepZone

Elasticsearch Architecture

Clusters, nodes, shards, and replicas — how VaultCommerce indexes millions of products.

Pass checkpoint below

Why this matters

  • VaultCommerce product search cannot rely on SQL LIKE at catalog scale — Elasticsearch indexes titles, descriptions, and facets for sub-second fuzzy search.
  • Shard and replica counts are fixed at index creation (with split/shrink limits) — wrong sizing causes reindex pain later.
  • Understanding cluster topology separates "search feels slow" triage from application bugs.

Cluster building blocks

Cluster
Node 1Shard 0 primary
Node 2Shard 1 primary
Node 3Shard 0 replica
An index is split into shards across nodes. Replicas provide failover and read scaling.

Core vocabulary

  • Cluster — one or more nodes sharing a cluster name; a node belongs to exactly one cluster.
  • Index — logical namespace (like a database table) for similar documents — e.g., vaultcommerce-products.
  • Shard — horizontal slice of an index; primary shards handle writes; replica shards copy primaries.
  • Document — JSON object with _id, _source, and analyzed fields for search.

VaultCommerce runs a three-node cluster: two primary shards plus one replica each — survives single-node loss while serving browse traffic from replicas.

The rest of this guide is part of Pro

Free covers every fresher guide in full. Pro unlocks Senior, Staff and Architect guides across every track.

Still to come · 3 sections

  • Indexing flow
  • Node roles (Elasticsearch 8.x)
  • Near-real-time search

Test yourself

Answer these before moving on — recall is what makes it stick.