Fairwinds | Blog

How Kubernetes Helps E-Commerce Companies Stay Profitable on Black Friday and Cyber Monday

Written by Fairwinds | Nov 26, 2019 10:00:48 PM

Running a successful Black Friday and Cyber Monday operation can be a major win for retail and e-commerce companies. For some businesses, the number of transactions generated in that single day can be equivalent to one month or more of sales. Yet horror stories abound. Last year, J. Crew lost an estimated $700,000  in Black Friday sales due to a website crash.

Fortunately, cloud computing has enabled e-commerce businesses to meet demand through elastic compute and on-demand provisioning of infrastructure resources. In this post, we discuss a few different architectural and technology considerations that e-commerce companies can pursue to run an efficient and reliable Black Friday/Cyber Monday event.

Microservice Architectures

A microservice architecture offers many benefits for an e-commerce platform. By breaking applications into smaller pieces, development teams can logically segment functionality - helping make the development and testing process more efficient. From a development perspective, teams can work on different parts of the codebase without stepping on each other. For example, product search, product details, and shopping cart functionality could all be built as their own microservice.

From a testing perspective, microservices put an emphasis on defining inputs and outputs. Services interact with each other through API calls, establishing a contract for how data and transactions will pass through the overall system.

Containers

Containers are a great way to package up microservices and make them ready for deployment on any computing platform or cloud. This portability is important, especially for e-commerce companies who may need to switch cloud providers. This ability to avoid “vendor lock-in” can be important, especially when cloud providers may have subsidiaries or adjacent businesses that compete directly with the e-commerce company.

Containers also provide a consistent way to run applications. By abstracting away the underlying operating system, developers can avoid troubleshooting and debug environment-specific or runtime-specific concerns.

Finally, containers are immutable. A container never changes while it’s running; instead, if it’s experiencing an error or requires an update, it must be deleted and a new container should be deployed to replace it.

You can imagine a scenario where a bug is found on the product search page during Black Friday. If the functionality is in its own microservice and container, engineers can simply push a new container version with the bug fix without having to take down the entire site — and interrupting hundreds or thousands of valuable user sessions.

Kubernetes

Kubernetes has emerged as not only the de-facto container orchestration, but an effective solution for scaling up and down compute resources as they are needed. Kubernetes comes with a few different auto-scaling capabilities that allow for intelligently replicating groups of containers (known as pods), as well as increasing and decreasing the number of compute instances required to run the site.

While Kubernetes automatically handles much of the background scaling activities, mastering these configurations comes with a learning curve. Sometimes, engineering teams neglect to provide these configurations, opening up risk for downtime when there is unpredictable traffic.

Fairwinds recently introduced a new open source tool, called Fairwinds Goldilocks, which helps engineers set the right resource requests and limits. These settings inform Kubernetes of the desired ranges for CPU and memory, helping Kubernetes know when to scale out.

Framebridge, Before and After Kubernetes

For insight, we sat down with Brock Wilcox, Vice President of Engineering at Framebridge, a world leading retailer of custom frames and client of Fairwinds.

Brock estimates that web traffic sometimes triples during Black Friday and Cyber Monday. Before implementing Kubernetes, the team would solve this by preemptively over-provisioning, which would double the cost of production.

One key improvement that Brock noticed was the ability for his engineers to make improvements to the application leading up to Black Friday. Framebridge is able to isolate and test new features in a staging environment. Not only is time to deployments down, but they are completely automated. And if something breaks after deploying new features, rollback only takes 60 seconds, allowing for the team to be less risk averse.

Managed Kubernetes

Kubernetes provides the double benefit of reliable and efficient production operations. For an event like Black Friday, it’s important for e-commerce companies to stay “in the black.” It’s also important to be reliable. Getting both right requires having the right expertise on your team.

Fully Managed Kubernetes offerings help provide expertise, monitoring, upgrades, and security patching in one complete subscription package. An event like Black Friday and Cyber Monday usually means “all hands on deck”, which can take developers away from valuable roadmap features and innovations. Best-of-breed people-led Managed Kubernetes services integrates 24x7 automated paging so your developers do not need to wake up at 3am for infrastructure alerts.

When choosing Kubernetes, you also need to consider enabling your engineers with the right open source tools. Fairwinds offers a suite of open source software  for managing Kubernetes - helping you deploy, operate, and optimize your infrastructure for security, reliability and efficiency. How can Fairwinds help you?