Git Product home page Git Product logo

thrift-shop

Primary project and documentation for Thrift Shop

The Thrift Shop is a micro-services application built using Thrift-Server. It is used to demonstrate how to build a complete application based on the Thrift tools built @creditkarama.

Table Of Contents

  1. Key principals
  2. Technology Stack
  3. Architecture

Key principals

Scalable

  • 100k per minute
  • 25% writes
  • 50% reads
  • 99% GraphQL query latency < 500ms
  • Eventually consistent within 100ms

Resilient

  • No single point of failure
  • Service discovery
  • Routing
  • Failure handling

API Driven

  • Machine and human readable service contracts
  • Sync and Async APIs consistent contracts
  • Centralized / discoverable API repository

All services have well defined API contracts

Telemetry

  • Performance metrics
  • Distributed tracing
  • Log aggregation
  • Dashboard

Secure

  • Login and authentication
  • Identity restricted data access
  • Service to service ACL

Analytics

  • Event tracking
  • User behavior tracking
  • Dashboard

Experimentation

  • A/B testing
  • Canary deploy

Cloud ready

  • Orchestration
  • Service discovery
  • Elastic scaling

Technology Stack

  • GraphQL API gateway
  • Request / response API with Thrift
  • RPC with HTTP/2 and LinkerD
  • Event sourcing with Kafka and Cassandra
  • Metrics and monitoring with Kafka / Influxdb / Grafana

Architecture

  • GraphQL server - Provides client API
  • Catalog Service - Maintains the list of available products and prices
  • Inventory Service - Immutable store that tracks current qty
  • Shopping Cart - Maintains the active shopping carts by user
  • Order Management - An async service that transitions a shopping cart into an order and notifies other services
  • Users - Maintain users credentials and settings
  • Session - Session management services that tracks active tokens and sessions
  • Recommender - A recommendation service based on previous purchasing behavior

Thrift Shop's Projects

catalog icon catalog

Thrift Shop Catalog service that maintains the list of available products and prices

idl icon idl

Thrift IDL Repository for all services

inventory icon inventory

Immutable store that tracks current qty of an item

site icon site

A beautiful e-commerce template powered by React, Redux and other modern web tech.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.