TL;DR
This paper introduces DAGOR, a novel, service-agnostic overload control system designed for large-scale microservice architectures like WeChat. DAGOR effectively manages system overload by decoupling control logic from individual services, ensuring high success rates and fairness even under heavy load.
What Problem Does This Paper Address?
Modern online services, especially those built on microservice architectures, face significant challenges in managing overload. Unlike traditional monolithic systems, microservices involve complex dependencies and rapid evolution, making it difficult to implement effective, centralized overload control. Service developers often struggle to accurately predict workload dynamics, leading to ad-hoc, service-specific solutions that can be detrimental to the overall system. This can result in cascading failures, reduced service availability, and a poor user experience. The paper aims to address these issues by proposing a system-centric, service-agnostic approach that can adapt to the dynamic nature of microservice environments.
Methods
DAGOR employs a multi-faceted approach to overload control:
- Service Agnostic & System-Centric: DAGOR's core principle is to be independent of individual service logic. It operates at the microservice level, monitoring load and making decisions without needing to understand the specific business functions of each service.
- Decoupled Overload Detection: Instead of relying on response times (which can be influenced by downstream services), DAGOR uses the average request queuing time as its primary indicator for detecting overload. This metric is more indicative of a server's local processing capacity.
- Priority-Based Admission Control: DAGOR assigns priorities to requests based on two dimensions:
- Business Priority: Determined by the type of user action at the entry point of the system (e.g., login, payment).
-
User Priority: Dynamically generated based on user ID, providing a finer-grained control and fairness mechanism. When overload is detected, requests with lower priorities are shed first.
-
Adaptive Admission Control: DAGOR dynamically adjusts its admission levels based on the current load status. It uses a compound admission level (combining business and user priorities) and a histogram-based approach to efficiently find the optimal shedding strategy in real-time.
- Collaborative Admission Control: To improve efficiency and reduce network overhead, upstream services are informed of the downstream service's admission level. This allows upstream services to preemptively drop requests that would likely be rejected by the downstream service, preventing unnecessary network traffic and processing.
Datasets
Not discussed in the paper. The evaluation uses synthetically generated workloads simulating the WeChat encryption service.
Key Insights and Ideas
- Queuing Time is King for Overload Detection: The paper strongly argues that average request queuing time is a more reliable indicator of a server's local overload than response time. Response time can be skewed by downstream service performance, leading to false positives for overload.
- Two-Tiered Prioritization for Robustness: Combining business and user priorities allows DAGOR to handle complex scenarios, including subsequent overload (where a service is invoked multiple times in a chain). This ensures that critical user actions and users are prioritized, even when the system is under stress.
- Decoupling is Essential for Scalability: By making overload control service-agnostic, DAGOR can be easily applied across a vast and rapidly evolving microservice ecosystem like WeChat, without requiring constant re-configuration for each new or updated service.
- Collaboration Reduces Waste: Informing upstream services about downstream load status significantly improves efficiency by shedding requests earlier in the call chain, saving network bandwidth and processing resources.
Key Results
- Improved Success Rate: DAGOR demonstrated a significantly higher success rate (around 50% improvement) compared to other techniques like CoDel and SEDA, especially under subsequent overload scenarios (M², M³, M⁴ workloads).
- Efficient Overload Detection: DAGOR's use of queuing time allowed it to postpone load shedding until a higher feed rate (750 QPS) compared to response time-based detection (630 QPS) in simple overload scenarios.
- Fairness: DAGOR showed consistent success rates across different types of overload (simple vs. subsequent), unlike CoDel which favored simple overload. This indicates DAGOR is less biased towards specific service workflows.
- Real-World Deployment: DAGOR has been successfully deployed and operated in the WeChat backend for over five years, enhancing system robustness during peak loads and special events.
Limitations and Future Work
- Synthetic Workloads: While the experiments are designed to simulate real-world scenarios, they are based on synthetic workloads. The paper acknowledges the need for further evaluation with real-world traffic.
- Tuning Complexity: While DAGOR is designed to be adaptive, fine-tuning the admission control parameters (like the percentage increase/decrease in expected requests) might still require careful consideration for optimal performance in diverse environments.
- Future Work: The paper doesn't explicitly detail future work, but the success of DAGOR suggests potential applications in other large-scale distributed systems and further research into more sophisticated adaptive and collaborative control mechanisms.
Summary updated