Sweet Analytics

Sweet Analytics is a customer and marketing data platform designed for ecommerce brands. It seamlessly connects all customer data points and interactions, offering a comprehensive 360-degree view of business performance. The platform not only provides tools to track against business goals but also enables a deep understanding of customer behavior and its impact on revenue. Ultimately, Sweet Analytics equips businesses with the essential tools to better understand their customers and foster growth.

Upstash Kafka as the primary messaging engine to allow cross-microservice communication

As a Customer Data Platform (CDP), Sweet ingests vast amounts of data from various sources, including ecommerce, email, and marketing platforms, as well as live behavioral data from website users. Sweet relies on Upstash's managed Kafka service as its primary messaging engine, enabling different microservices to communicate seamlessly. These services publish key events that other services might need to act upon. For example, when the ecommerce data sync service creates an order in the system, it triggers a need for Sweet to update certain customer stats. This is due to changes in metrics like the total number of orders, sales, and other key customer-related figures. The customer stats service subscribes to these events and recalculates the relevant statistics. While this is a simplified illustration, the primary use of Upstash Kafka for Sweet is to facilitate cross-microservice communication within their real-time system

Miguel Martinez

Upstash Kafka has essentially allowed us to focus more on shipping new features and provide a higher quality service, as well as simplify our operations by using a managed service rather than setting it up and managing it ourselves.

Miguel Martinez, CTO

From Batch Processing to Upstash Kafka for realtime consistency and streamlined operations

To achieve their objectives, Sweet's tech stack integrates a range of technologies, including Node.js, Python, MongoDB, ElasticSearch, PostgreSQL, RabbitMQ, Redis, Kafka, and more. Prior Upstash, Sweet primarily used batch processing. If we go back to the previous example, this approach would recalculate customer stats for updated profiles based on a scheduled run multiple times a day. However, this led to temporary inconsistencies in the data. To address this challenge, Sweet adopted Upstash's managed Kafka service. This decision brought two significant advantages:

  • Instead of managing and maintaining their own Kafka cluster, which would require quite a bit of work , Sweet was able to streamline their operations with Upstash significantly.
  • With Upstash's Kafka service, Sweet achieved better eventual consistency across the platform. They utilized Kafka to notify various services about key events, enabling real-time processing.