What happened

Shares of Fastly (FSLY -0.47%) gained 26.3% in June, according to data from S&P Global Market Intelligence. The content delivery network (CDN) specialist suffered a significant service outage on June 8, but the company was able to turn this unfortunate event into a source of investor-pleasing strength. Here's how.

So what

One of Fastly's customers changed its service configuration on June 8. This happens all the time -- sometimes hundreds of times in a single day -- but this particular update triggered a previously undiscovered bug in Fastly's systems that brought the CDN network to its knees.

Fastly was immediately aware of the problem, found and disabled the errant configuration quickly, and brought its network back to full strength within 49 minutes. While Fastly worked through the issue, large portions of the public internet were unusable because many sites and apps either use Fastly's CDN directly or depend on third-party services that require a working Fastly setup.

A man wearing a derby examines something through a magnifying glass.

Image source: Getty Images.

Now what

At first glance, this sounds like bad news for Fastly. The outage broke the service level agreements with many of its enterprise-class customers, and that will lead to partial refunds of June's service fees. Furthermore, you could argue that Fastly is losing business since the service error lowers customers' trust in the company's reliability.

However, the investors who drove Fastly's share prices as much as 12.4% higher that day would argue that the swift and effective response to this outage could bring more clients to the company. Neutralizing this obscure problem in less than an hour shows that it is ready to tackle unexpected issues at the drop of a hat.

In an ideal world, where cows are perfectly spherical, Fastly would never experience any outages. In the real world, occasional service hiccups are unavoidable, and the company's response to these stress tests is what matters. And the huge impact this event had on dozens of consumer-facing services underscored how important Fastly is to the modern internet. That's certainly a positive effect for its customer sign-up efforts.

That being said, the stock still trades more than 60% below October's all-time highs due to lingering uncertainty around the company's largest customer (TikTok and its owner, Chinese tech company ByteDance). In my eyes, Fastly is primed for fantastic long-term returns even after June's robust gains.