How Discord Stores Trillions of Messages (2024)

Discord engineers recently posted a description of their billion-message message storage system, which they started in 2017. When they migrated from MongoDB to 12 Cassandra nodes to store billions of messages, they had different problems, which were unpredictable. A server with small groups of friends tended to send a lot fewer messages than a server with hundreds of thousands of people. Additionally, they discovered that because readings in Cassandra require querying the memtable and on-disk files, they are far more expensive than writing.

Their solution was to migrate to ScyllaDB, a Cassandra-compatible database written in C++, which promises better performance and garbage collection. It is an open-source distributed NoSQL wide-column data store compatible with Apache Cassandra.

They started small but then decided to move all their databases. Nevertheless, despite all this, hot partitions-many concurrent reads on a server that causes latencies-persisted. They attempted to address the issue using data services between a ScyllaDB database cluster and their API monolith.

They used Rust to write data services, which gave them a C/C++ speed with thread and memory safety. In addition, these data services contain one gRPC endpoint per DB query, and if more users query the same data, the DB will be queried only once.

Ultimately, this prevented the DB from getting traffic spikes if someone sent a message to everyone on a large server. Their tail latencies improved

How Discord Stores Trillions of Messages (2024)
Top Articles
PGP Encryption: The Email Security Standard - Panda Security
Remote Management Settings
Somboun Asian Market
Urist Mcenforcer
Ffxiv Shelfeye Reaver
Craftsman M230 Lawn Mower Oil Change
Wisconsin Women's Volleyball Team Leaked Pictures
Top Financial Advisors in the U.S.
Erskine Plus Portal
Optum Medicare Support
Pbr Wisconsin Baseball
13 The Musical Common Sense Media
Gt Transfer Equivalency
454 Cu In Liters
Turning the System On or Off
7 Low-Carb Foods That Fill You Up - Keto Tips
Pricelinerewardsvisa Com Activate
Indiana Wesleyan Transcripts
Kamzz Llc
FDA Approves Arcutis’ ZORYVE® (roflumilast) Topical Foam, 0.3% for the Treatment of Seborrheic Dermatitis in Individuals Aged 9 Years and Older - Arcutis Biotherapeutics
Finalize Teams Yahoo Fantasy Football
Japanese Mushrooms: 10 Popular Varieties and Simple Recipes - Japan Travel Guide MATCHA
Zillow Group Stock Price | ZG Stock Quote, News, and History | Markets Insider
At&T Outage Today 2022 Map
Jordan Poyer Wiki
kvoa.com | News 4 Tucson
Cornedbeefapproved
Sinai Sdn 2023
How Do Netspend Cards Work?
Kelley Fliehler Wikipedia
Otis Offender Michigan
Stolen Touches Neva Altaj Read Online Free
Www Craigslist Com Shreveport Louisiana
Scioto Post News
How to Watch the X Trilogy Starring Mia Goth in Chronological Order
Skip The Games Ventura
Arcadia Lesson Plan | Day 4: Crossword Puzzle | GradeSaver
Hindilinks4U Bollywood Action Movies
Temu Y2K
Craigslist Tulsa Ok Farm And Garden
Cranston Sewer Tax
Barstool Sports Gif
412Doctors
Timothy Warren Cobb Obituary
Professors Helpers Abbreviation
Dontrell Nelson - 2016 - Football - University of Memphis Athletics
Copd Active Learning Template
Bonecrusher Upgrade Rs3
The 13 best home gym equipment and machines of 2023
Kidcheck Login
Arnold Swansinger Family
Latest Posts
Article information

Author: Saturnina Altenwerth DVM

Last Updated:

Views: 6614

Rating: 4.3 / 5 (44 voted)

Reviews: 83% of readers found this page helpful

Author information

Name: Saturnina Altenwerth DVM

Birthday: 1992-08-21

Address: Apt. 237 662 Haag Mills, East Verenaport, MO 57071-5493

Phone: +331850833384

Job: District Real-Estate Architect

Hobby: Skateboarding, Taxidermy, Air sports, Painting, Knife making, Letterboxing, Inline skating

Introduction: My name is Saturnina Altenwerth DVM, I am a witty, perfect, combative, beautiful, determined, fancy, determined person who loves writing and wants to share my knowledge and understanding with you.