Storefront has been decoupled into micro-frontends with a dedicated commerce app and shared shell.

Read the architecture guide →

Consistency and data ownership

Authoritative stores, derived projections, transactional boundaries, and propagation guarantees in Catalog.

Architecture

Purpose & Scope

This document defines data ownership, transactional boundaries, cache invalidation, and eventual consistency guarantees for the CatalogDomainv1.0.0CatalogCore BookWorm subdomain that makes books discoverable, purchasable, and consistently described across the customer journ...Ownercatalog-experience-teamDiagramOpen docs subdomain, governing Catalog APIServicev1.0.0Catalog APIInternal HTTP and gRPC service for Catalog product management, hybrid discovery, and authoritative book metadata. PublishesBookUpdatedRatingFailedIntegrationEventSubscribesCreatePublisher, UpdatePublisher +24APIsOpenAPI, AsyncAPIOwnercatalog-experience-teamDiagramRepositoryOpen docs and Catalog IngestionServicev1.0.0Catalog IngestionInternal background worker that reads pending Catalog book updates and synchronizes semantic search vectors in Qdrant. SubscribesProcessVectorBatchIntegrationEventOwnercatalog-experience-teamDiagramRepositoryOpen docs. Use it to reason about which stores are authoritative systems of record versus replayable projections before modifying write paths, search indexing, or cross-domain rating handlers.

Visual Reference

The visual below illustrates how catalog mutations, scheduled vector indexing, and cross-domain rating events propagate across authoritative and derived stores.

Loading graph...

Catalog Write, Cache Invalidation, and Index Propagation Pipeline

Core Invariants & Design Rules

Warning

Never use derived stores for purchase or checkout decisions. Order APIServicev1.0.0Order APIAuthenticated Ordering service for Buyer profiles and the Order lifecycle, creating Orders from baskets, snapshotting pr...PublishesGetBasketGrpc, GetBookGrpc +5SubscribesCreateOrder, CompleteOrder +11APIsOpenAPI, AsyncAPI, Carrier Service LevelsOwnercommerce-fulfillment-teamDiagramRepositoryOpen docs and Basket APIServicev1.0.0Basket APIInternal HTTP and gRPC service for managing customer-scoped shopping baskets, Catalog price enrichment, and post-checkou...PublishesGetBookGrpc, GetBooksGrpc +2SubscribesCreateBasket, UpdateBasket +4APIsOpenAPI, AsyncAPIOwnercommerce-fulfillment-teamDiagramRepositoryOpen docs must resolve prices and book existence exclusively through gRPC queries backed by Catalog DatabaseContainerv1.0.0Catalog DatabaseAuthoritative PostgreSQL system of record owned by the Catalog bounded context for books, authors, categories, publisher...Ownercatalog-experience-teamDiagramOpen docs—never from Catalog VectorContainerv1.0.0Catalog VectorNon-authoritative Qdrant vector search index owned by the Catalog bounded context for hybrid semantic and keyword book d...Ownercatalog-experience-teamDiagramOpen docs or stale client caches.

Boundaries & Guarantees

ConcernStrategy & GuaranteeFailure / Edge-Case BehaviorRelated Resources
Persistencecatalog-database provides ACID transactions for catalog entities, pending vector updates, and Wolverine outbox/inbox tables; catalog-blob stores cover images with expiring read-only SAS URLs (1h default).Uncommitted writes never enqueue vector updates or outbox messages; missing blobs surface as unavailable cover URLs without corrupting book records.catalog-database, catalog-blob, adr-001-postgresql-system-of-record, adr-005-blob-storage-for-book-images
Cachingcatalog-cache uses FusionCache L1/L2 with a Redis backplane and 2h fail-safe; book detail (book:{id}) and summary (book:summary:{id}) keys expire in 30m and are actively invalidated on write; dashboard metrics (catalog:dashboard:v1) expire every 15s.List (books:list) and search (books:search) keys are tag-invalidated; if Redis is unavailable, FusionCache falls back to L1/fail-safe or direct database reads.catalog-cache, adr-004-fusioncache-redis-for-catalog-reads
Messagingscheduler-service triggers catalog-ingestion every 5m UTC via ProcessVectorBatchIntegrationEvent; catalog-api consumes FeedbackCreatedIntegrationEvent and FeedbackDeletedIntegrationEvent to project average_rating and total_reviews.Missing books on feedback creation emit BookUpdatedRatingFailedIntegrationEvent for compensation; missing books on feedback deletion complete as a no-op; exhausted retries route to <code>bookworm.{env}.catalog.dead-letter-queue</code>.ProcessVectorBatchIntegrationEvent, FeedbackCreatedIntegrationEvent, FeedbackDeletedIntegrationEvent, BookUpdatedRatingFailedIntegrationEvent, <code>bookworm.{env}.catalog.dead-letter-queue</code>
Concurrencycatalog-ingestion uses PostgreSQL advisory lock 740031001 and (book_id, revision) optimistic matching; inbound rating events use a 24h Redis integration-event idempotency guard; Qdrant upserts are idempotent by book UUID.Duplicate rating events within 24h are ignored; concurrent book edits during an ingestion batch advance revision and are automatically picked up on the next run.product-ingestion, adr-003-database-queue-for-vector-indexing, adr-006-reviews-rating-projection-on-book

Safe Change & Verification Checklist