How Shopify built the one network edge to front our services and systems.
Overview
The article discusses Shopify's initiative to unify its traffic management through a new system called Möbius. This system aims to streamline how traffic is handled, improve observability, and enhance security and performance across Shopify's services.
What You'll Learn
1
How to implement a unified edge for traffic management in cloud services
2
Why standardizing traffic paths improves observability and performance
3
How to automate domain configuration for edge services
Key Questions Answered
What is the purpose of Möbius in Shopify's architecture?
Möbius serves as a unified edge that manages incoming traffic to Shopify, ensuring it is stable, secure, and performant. It handles TLS and TCP termination close to the client, providing faster requests and better DDoS protection while filtering malicious traffic before it reaches the internal clusters.
How does the Shopify Front End (SFE) contribute to traffic management?
The Shopify Front End (SFE) acts as a routing layer that receives traffic from Möbius and dispatches it to the appropriate application clusters. It utilizes nginx deployments with custom Lua code for routing based on various criteria, enhancing load balancing and reducing latency.
What challenges did Shopify face before implementing Möbius?
Prior to Möbius, Shopify had over six different traffic paths, making it difficult to deploy features uniformly. This complexity blurred observability and increased the time required for troubleshooting and onboarding new team members.
What benefits does Möbius provide for application owners?
Möbius automates the setup of edge services for application owners, allowing them to configure their domains and DNS without manual intervention. This streamlines the process of leveraging edge capabilities, ensuring that applications can benefit from improved performance and security without extensive configuration.
Technologies & Tools
Some links below are affiliate links. We may earn a commission if you make a purchase.
Backend
Nginx
Used in the routing clusters to handle traffic based on various criteria.
Backend
Lua
Custom code used in nginx deployments for routing logic.
Orchestration
Kubernetes
Used to deploy applications and services across clusters.
Key Actionable Insights
1Implementing a unified edge like Möbius can significantly reduce the complexity of traffic management across services.By consolidating traffic paths, teams can streamline feature deployment and improve observability, making it easier to troubleshoot issues and onboard new developers.
2Automating domain configuration for edge services can save time and reduce errors.Möbius allows application owners to focus on their core development tasks rather than getting bogged down in the intricacies of network configuration.
3Utilizing a centralized routing layer like SFE enhances load balancing capabilities.This approach allows for near-instantaneous traffic changes, improving responsiveness and control over how requests are handled across different application instances.
Common Pitfalls
1
Failing to standardize traffic paths can lead to increased complexity and slower feature deployment.
When multiple traffic paths exist, it complicates the deployment of new features and makes troubleshooting more difficult, as developers must navigate numerous configurations.