Discord는 폭발적인 성장을 거치는 과정에서 Cloudflare가 대역폭과 하드웨어 비용을 낮게, 웹 성능은 높게 유지하는 면에서 준 도움이 대해 고맙게 생각합니다.
Discord is a voice and text communication app for online computer gamers. Discord’s goal is to become the de-facto standard communication app for PC gamers, and they’ve seen success, boasting 2.4 million concurrent users and over 25 million registrations as of July 2016.
Discord’s Challenge: Mitigating DDoS Attacks on Websockets Servers at Scale
As Discord prepared for rapid growth, they needed an affordable way to quickly scale their existing hardware infrastructure, while maintaining performance and security. Performance wise, Discord would need to transition from serving their content from a single homed server to a high performing CDN (Content Delivery Network) partner that could serve their static assets from all around the globe. Security wise, Discord needed to protect their websockets-based traffic from the rampant DDoS attacks that they were experiencing. As CTO Stanislav Vishnevskiy explained, "Since we are a gamer focused product we attract a lot of users who love to DDoS each other during game matches. As we grew more popular the intensity and occurrences of these DDoS attacks increased to the point where our engineers were constantly dealing with them." Vishnevskiy continued, "Before Cloudflare, we were using a large number of HAProxy boxes with DNS load balancing to be able to failover during DDoS attacks on our real-time gateways." However, their initial hardware solution could cost Discord up to six figures annually at scale and would still require work from Discord's engineers. Discord thus needed an affordable, easily scalable solution to stop these attacks or, according to Vishnevskiy, Discord's customer experience and retention would significantly drop: "Every single outage would result in frustrated customers. While most existing customers were tolerant to the outages, new customers that signed up during the issues retained poorly due to very bad first impressions. Every time a customer got frustrated and lapsed, it pushed us further from our goal of becoming the de-facto communication app for gamers."
Discord’s Solution: A CDN With Built-In Security
In August 2015, Discord came to Cloudflare just as they hit 25,000 concurrent users, and Cloudflare provided immediate, lasting performance and security benefits. Discord easily scaled the business to their current 2.4 million concurrent users (over 9000% growth in just one year), by leveraging Cloudflare's Content Distribution Network (CDN). Cloudflare's CDN works by caching content to data centers in over 200 cities, and then serving it directly to users from the nearest Data Center. Over 2 Pb of Discord's traffic per month is served directly from Cloudflare's edgeside cache to Discord's users. In turn, Discord, a Google Cloud customer, both provides customers with a snappier application through the high speed interconnections between Cloudflare and Google Cloud and saves over $100,000 monthly on their Google Cloud bill. In addition, Discord gets tremendous comfort from knowing Cloudflare's security is always on protecting and serving their traffic. As Jake Heinz, a software engineer at Discord, explains "We have Cloudflare sit in front of our websockets servers to absorb Layer 7 attacks and various layer 3 & 4 reflection attacks. We have 2.4 million concurrent users connected through Cloudflare to us, and Cloudflare quickly and securely serves our traffic even with spikes of websocket events up to 2 million/second."
Discord는 Cloudflare를 사용함으로써 지속적으로 하드웨어와 대역폭 비용을 크게 절약할 뿐만 아니라 사용자에게 고성능과 안전하고 신뢰할 수 있는 애플리케이션을 제공합니다.