Designing a Basic Product Model for E‑commerce Systems
This article explains how to design a flexible product model for e‑commerce by evolving from simple category‑article structures to a richer schema that includes brands, attributes, specifications, and separate SKU entities, enabling effective filtering, search, and integration with other services.
In e‑commerce systems the product model is a core component; the article begins by emphasizing its importance and proposes a basic design that can support typical catalog operations.
The author traces the evolution from early CMS‑style category‑article models, where a category maps to a product, to the need for additional concepts such as brands to allow users to browse all items from a brand like Nike.
To address the demand for fine‑grained filtering, a UI pattern is introduced that lets users narrow results by various criteria. The article then analyses how product attributes differ across categories (e.g., jeans have fit, waist, length; computers have CPU, GPU) and proposes a hierarchical model: a category has many attributes, each attribute has many options, and a concrete product links to specific attribute options.
An illustrative diagram (shown in the original images) depicts the relationships among categories, attributes, attribute options, and products, highlighting that price should also be treated as an attribute rather than a simple field.
The concept of separating “product” from “SKU” (stock‑keeping unit) is clarified: different specifications such as color, size, or storage constitute distinct SKUs, which are linked to a single product via a one‑to‑many relationship.
Finally, the article concludes that the proposed model satisfies basic product search and display requirements, can feed search indexes, and fits into a larger architecture where the product domain is isolated as a “product center” service that collaborates with user, order, and payment services.
Architecture Digest
Focusing on Java backend development, covering application architecture from top-tier internet companies (high availability, high performance, high stability), big data, machine learning, Java architecture, and other popular fields.
How this landed with the community
Was this worth your time?
0 Comments
Thoughtful readers leave field notes, pushback, and hard-won operational detail here.