Coffee Meets Bagel

CASE STUDY

Redis Enterprise has really sped up our development cycle. Instead of waiting for operational performance to scale for new application features and expansion, we’re waiting for the developers to catch up to performance.


— John Valdez, DevOps Engineer, Coffee Meets Bagel

Company Coffee Meets Bagel
Industry Dating apps

The Customer

With so many platforms for online dating, Coffee Meets Bagel differentiates itself by its authentic matching—it sends a limited number of highly curated matches to its users every day at noon.

The Challenge

Coffee Meets Bagel was struggling with its implementation of Cassandra when it moved to open source Redis. As Redis became integral to its production environment, the team adopted Redis Enterprise VPC to bring lightning-fast performance to caching, user analytics, and real-time data streaming.

The Solution

Since its founding in 2012, more than 3 million people around the globe have used Coffee Meets Bagel to look for love. With the company hoping to expand its international presence and processing upwards of 1TB of data an hour, Coffee Meets Bagel needed a database with outstanding performance.

The Benefits

Redis Enterprise provides automated scaling, failover, cluster creation, persistence, and high availability, helping Coffee Meets Bagel focus on application innovation. Redis Enterprise is delivering 99.99% uptime, and Redis on Flash has saved the company 40% compared to running the database entirely in DRAM.

“Redis Enterprise’s auto-scaling capabilities have eliminated days of manual effort previously required to ensure that workers were readily available for scaling during high-traffic times. We’ve had no problem achieving 99.99% uptime.”
—Stephen Brandon, Engineering Manager, Infrastructure, Coffee Meets Bagel

Like many men in their 20s, Andrew is looking for love. He tried his hand at many matchmaking apps, but while he looked at tons of potential dates, he didn’t find anyone long-term. His friends recommended Coffee Meets Bagel, a unique online dating service that sends a limited number of curated matches to its users each day at noon.

One day, Andrew opens his app just past noon. Andrew loves the app, but what if he logged in and didn’t see the matches he expected? He’d be annoyed, and maybe stop using it. And that would mean he’s doomed to die alone and unloved.

Keeping users like Andrew—who flood Coffee Meets Bagel at peak times—means that the app must process large amounts of data in a very short time. To prevent delays or lags, Coffee Meets Bagel needed a database with lightning-fast performance, especially as it worked to expand its international presence.


The value of Redis expertise

Before adopting Redis, Coffee Meets Bagel was struggling with its implementation of Cassandra. While Cassandra delivered on basic high write-volume requirements, it experienced noticeable issues when it came to simultaneous updates and deletions, resulting in partial outages that impacted the end-user experience. 

As a result, Coffee Meets Bagel moved to open source Redis, running as self-managed clusters to deliver low read latency while simultaneously tolerating high-update volume. The company initially adopted Redis delivered via Amazon ElastiCache, but as its Redis implementation grew to become an integral part of its production environment, the DevOps team realized that it would be extremely beneficial to have a fault-tolerant, highly available, and scalable solution with someone to call when problems arose.

“With open-source Redis, you’re on your own and there’s a lot of trial and error that takes place, which is not ideal in a production environment,” says John Valdez, DevOps Engineer at Coffee Meets Bagel. “Redis Labs’ expertise has helped us troubleshoot issues, optimize performance, and smoothly scale as our user base expands—without any of the guesswork.”

 
“To prevent delays or lags, Coffee Meets Bagel needed a database with lightning-fast performance, especially as it worked to expand its international presence.”
 
“Redis Enterprise VPC’s versatile data structures—including geo-based Sorted Sets, Bloom filters, Sets and Sorted Sets, and sinter operations—lets Coffee Meets Bagel generate personalized recommendations for millions of users.”

Caching and beyond

During off-peak times, Coffee Meets Bagel runs on approximately 600 reserved AWS instances. At peak activity times—typically when match recommendations are being pushed to users—the company’s spot instances can scale to double that. 

In this fast-paced environment, Redis Enterprise Virtual Private Cloud’s versatile data structures—including geo-based Sorted Sets, Bloom filters, Sets and Sorted Sets, and sinter operations—allows Coffee Meets Bagel to generate highly personalized recommendations for its millions of users, and process billions of user matches at high speeds. 

Additionally, Redis Enterprise is the primary database for more than 2TB (and growing) of user information. Redis Enterprise’s data-ingest capabilities seamlessly scale to process upwards of 1TB of data an hour with high reliability, including over 300 million exchanged messages and more than 1 billion matches, without the need for worker throttling.

Through Redis Enterprise’s in-memory processing and backlog queue, Coffee Meets Bagel is also able to store data for later use. “Asynchronous fault-tolerant priority queuing delivers granular prioritization and schedules tasks to send push notifications in advance using a queuing API with a timestamp parameter,” says Stephen Brandon, Engineering Manager, Infrastructure, at Coffee Meets Bagel. “These sophisticated queuing capabilities allowed us to eventually decommission our implementation of Celery, an asynchronous task queue, reducing the amount of I/O between operations and simplifying our application stack.”


Reaping the benefits

For Coffee Meets Bagel, the biggest benefit of Redis Enterprise VPC is also the biggest requirement: high performance. Previously, the team needed to throttle three server workers in order to avoid huge CPU spikes, but with Redis Enterprise, the worker count is up to 18 without any performance issues whatsoever. “It’s really sped up our development cycle. Instead of waiting for operational performance to scale for new application features and expansion, we’re waiting for the developers to catch up to performance,” Valdez says.

In addition to high performance, Coffee Meets Bagel has seen many other benefits as a result of its move to Redis Enterprise, including 24/7 support, automated operations, significant cost savings on cloud spend, and cloud-agnostic consistency. 

“Redis Enterprise’s auto-scaling capabilities have eliminated days of manual effort previously required to ensure that workers were readily available for scaling during high-traffic times,” says Brandon. “In addition, we’ve had no problem achieving 99.99% uptime.”

The team has taken advantage of Redis on Flash, which has saved the company 40% compared to running the database entirely in DRAM. Plus, as Coffee Meets Bagel moves toward a dual public cloud infrastructure in order to leverage the unique advantages of both AWS and Google Cloud, it doesn’t have to worry about its Redis performance—Redis Enterprise VPC is completely cloud agnostic, offering the same performance, capabilities, and configurations in any cloud for seamless operational consistency.


Global growth on the horizon

As Coffee Meets Bagel expands its international presence, it would like to eventually leverage Redis Enterprise’s CRDT-based Active-Active architecture, which is designed for geographically distributed applications. “Active-Active replication will be a great fit for us as we continue our expansion outside the United States,” says Valdez. “But in the meantime, we’re just enjoying the breath of fresh air-—and the breathing room—that Redis Enterprise has brought to our operations.”