service
Rating Aggregator

Rating Aggregator

Keeps each product's aggregate star rating up to date as reviews are published, and serves it fast from a cache.

Service

Overview

The Rating Aggregator consumes Review PublishedReview PublishedEventv1.0.0Published when a submitted review passes moderation and becomes visible on the storefront. Ownerreviews-platformSchemaMapView docs and recomputes the affected product’s aggregate rating (average score and review count). It writes the result to the Rating CacheRating CacheContainerv1.0.0Redis cache that serves each product's aggregate star rating with low latency.MapView docs for fast reads and publishes Rating UpdatedRating UpdatedEventv1.0.0Published when a product's aggregate rating changes as a result of a newly published review. Ownerreviews-platformSchemaMapView docs so other domains can stay in sync.

Responsibilities

AreaDescription
AggregationRecomputes average rating and review count per product.
CachingWrites aggregate ratings to the Rating CacheRating CacheContainerv1.0.0Redis cache that serves each product's aggregate star rating with low latency.MapView docs.
EventingPublishes Rating UpdatedRating UpdatedEventv1.0.0Published when a product's aggregate rating changes as a result of a newly published review. Ownerreviews-platformSchemaMapView docs on every change.

Architecture diagram

Messages for this service

Sends messages (1)

Quickly find the message you need by searching for the name, type, or summary.
NameVersionTypeSummary
Rating Updated
v1.0.0eventPublished when a product's aggregate rating changes as a result of a newly published review.

Receives messages (1)

Quickly find the message you need by searching for the name, type, or summary.
NameVersionTypeSummary
Review Published
v1.0.0eventPublished when a submitted review passes moderation and becomes visible on the storefront.
Event-driven architecture documentation: Acme Inc