Global Retry Constraints in Distributed Applications

Resolve Bottlenecks,
Find Innovative Solutions
Generate Solutions

Solution Overview

Problem

In distributed applications using service-oriented architecture, retry storms can occur due to excessive retry attempts, leading to system overload and congestion collapse, especially when individual resources make decisions about retries independently without considering overall system activity.

Innovation Solution

Implementing global or transaction-wide constraints on retry attempts using token buckets or a retry manager to limit the total number of retries across all resources involved in a transaction, ensuring that the entire transaction is considered as a single unit, rather than individual resources making independent decisions.

Engineering Contradictions & Design Principles

VSEngineering Contradiction Analysis

1Reliability

If individual resources make independent retry decisions to handle transient disruptions, then the system can recover from brief failures, but retry storms and congestion collapse can occur when too many retries are attempted in quick succession

Engineering Contradiction:
Improvesystem recovery from transient failuresVSAvoidretry storms and congestion collapse
Core Design Contradiction:
ReliabilityVSObject-affected harmful factors

Solution Approach 1:

The patent introduces a coordinator resource that acts as an intermediary between individual resources and the retry mechanism. This coordinator receives retry requests from multiple resources, manages a shared retry budget, and decides whether to allow or deny each retry attempt. By centralizing retry control, the system prevents retry storms while maintaining the ability to recover from transient failures.

Inventive Principle:
Principle #24Intermediary (Mediator)

Solution Approach 2:

The system implements feedback mechanisms where the coordinator monitors the state of shared resources and the number of retry attempts made. Based on this feedback, the coordinator dynamically adjusts retry decisions, allowing retries when resources are available and denying them when the system is approaching capacity limits, thereby preventing congestion collapse.

Inventive Principle:
Principle #23Feedback

2Object-affected harmful factors

If a fail fast policy is used to avoid retry storms, then system overload is prevented, but negative end-user experiences occur more frequently due to abandoned recoverable transactions

Engineering Contradiction:
Improvesystem overload preventionVSAvoidend-user experience and transaction completion
Core Design Contradiction:
Object-affected harmful factorsVSReliability

Solution Approach 1:

The patent implements dynamic retry management where the retry policy is not fixed but adapts based on current system conditions. The coordinator adjusts the number of allowed retries and the timing of retry attempts based on resource availability and system load, enabling the system to be more aggressive during low-load periods and more conservative during high-load periods.

Inventive Principle:
Principle #15Dynamics

Solution Approach 2:

The system performs preliminary assessment of retry requests by the coordinator before allowing them to proceed. The coordinator evaluates whether a retry should be permitted based on current system state, resource availability, and retry history, making a decision in advance that prevents both premature failures and excessive retries.

Inventive Principle:
Principle #10Preliminary action

3Object-affected harmful factors

If global constraints are applied to limit total retries across all resources, then retry storms are prevented, but the complexity of managing coordinated retry logic increases

Engineering Contradiction:
Improveretry storm preventionVSAvoidcoordinated retry management system
Core Design Contradiction:
Object-affected harmful factorsVSDevice complexity

Solution Approach 1:

The patent segments the retry management function into separate components: individual resources that generate retry requests, a coordinator that manages the shared retry budget, and a decision-making layer that evaluates each retry request. This segmentation allows each component to remain relatively simple while the system as a whole achieves sophisticated retry control.

Inventive Principle:
Principle #1Segmentation

Solution Approach 2:

The coordinator resource serves multiple functions: it receives retry requests from various resources, manages the shared retry budget, makes authorization decisions, and provides feedback to requesting resources. This multi-functionality consolidates complexity into a single component rather than distributing it across multiple resources.

Inventive Principle:
Principle #6Universality (Multi-functionality)

Data Source

PatentUS12181972B1System-wide constraints on retries within distributed applications
Publication Date: 2024.12.31 AMAZON TECH INC
  • US12181972B1 patent drawing
  • US12181972B1 patent drawing
  • US12181972B1 patent drawing

AI summary

It is determined that a workflow comprising inter-resource requests of a distributed application is to be initiated. In response to detecting, at a first resource during execution of the workflow, that a triggering condition for retrying a request is met, and that a workflow-level retry budget of the workflow indicates that a retry is permitted, the retry is attempted and the budget is modified to indicate that the retry has been attempted. In response to detecting, at another resource, that a triggering condition for retrying another request is met, and that the workflow-level retry budget of the workflow indicates that a retry is not permitted, an indication that the workflow has failed is generated.