Idempotent Workflow Actions with Guard Conditions

Resolve Bottlenecks,
Find Innovative Solutions
Generate Solutions

Solution Overview

Problem

Complex workflows in distributed computing environments are prone to failure due to improper order of execution and independent failures of workflow processes, leading to data loss and inconsistencies.

Innovation Solution

Implementing workflows composed of idempotent actions, where each action includes a guard condition, executable code, and a record of execution state, allowing for iterative validation and execution without disrupting overall workflow completion, even if actions fail independently.

Engineering Contradictions & Design Principles

VSEngineering Contradiction Analysis

1Stability of the object's composition

If transactional workflows with tight control over order of operations are used, then execution order consistency is improved, but workflow reliability deteriorates because a single failure causes entire workflow failure

Engineering Contradiction:
Improveexecution order consistencyVSAvoidworkflow completion reliability
Core Design Contradiction:
Stability of the object's compositionVSReliability

Solution Approach 1:

The workflow is segmented into independent idempotent actions that can execute autonomously. Each action is a self-contained unit with its own guard conditions and execution logic, allowing individual actions to fail without propagating failure to the entire workflow. The workflow engine manages these segmented actions independently, checking guard conditions and executing successful ones while skipping failed actions.

Inventive Principle:
Principle #1Segmentation

Solution Approach 2:

The system changes the execution model from sequential transactional processing to parallel independent action execution. Guard conditions act as parameters that control when each action should execute, allowing the system to dynamically adjust execution based on current state while maintaining overall workflow progress even when some actions fail.

Inventive Principle:
Principle #35Parameter changes

2Adaptability or versatility

If live-site operations and independent scripts are used, then workflow flexibility is improved, but data consistency deteriorates due to execution inconsistencies

Engineering Contradiction:
Improveworkflow flexibilityVSAvoiddata consistency
Core Design Contradiction:
Adaptability or versatilityVSStability of the object's composition

Solution Approach 1:

The workflow engine provides a universal framework that handles both traditional sequential workflows and independent parallel actions through a single unified system. This multi-functional approach allows the same engine to manage ordered execution when needed and independent parallel execution when flexibility is required, maintaining data consistency through standardized guard condition checking and state management across all operation types.

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

Solution Approach 2:

The system uses guard conditions as configurable parameters that determine action execution. By changing the guard condition parameters and execution mode settings, the same workflow can operate in different modes (sequential or parallel) while maintaining data consistency through the standardized guard condition evaluation mechanism.

Inventive Principle:
Principle #35Parameter changes

3Reliability

If iterative validation of guard conditions is performed at predetermined intervals, then workflow progress is improved despite failures, but execution time increases due to repeated validation

Engineering Contradiction:
Improveworkflow completion progressVSAvoidvalidation execution time
Core Design Contradiction:
ReliabilityVSLoss of time

Solution Approach 1:

The workflow engine performs periodic validation of guard conditions at predetermined intervals for each action. This periodic checking allows the system to retry failed actions and progress toward completion despite individual failures. The periodic nature of this validation balances thoroughness with efficiency, avoiding continuous checking while ensuring progress.

Inventive Principle:
Principle #19Periodic action

Solution Approach 2:

The system maintains copies of action definitions including guard conditions and execution state in a centralized workflow definition. This allows efficient validation by copying and comparing state information rather than re-evaluating entire workflow contexts, reducing the time overhead of iterative validation while maintaining reliability.

Inventive Principle:
Principle #26Copying

Data Source

PatentUS10474500B2Running complex workflows in distributed systems while protecting consistency and ensuring progress despite failures
Publication Date: 2019.11.12 MICROSOFT TECHNOLOGY LICENSING LLC
  • US10474500B2 patent drawing
  • US10474500B2 patent drawing
  • US10474500B2 patent drawing

AI summary

Complex workflows are composed of a plurality of idempotent actions. During execution of the complex workflows, a computing system accesses the plurality of idempotent actions and determines whether corresponding guard conditions for triggering processing of the idempotent action are satisfied. When satisfied, a lock is taken on one or more resources used for executing the idempotent code of the idempotent action and execution of the idempotent code is initiated. Thereafter, upon successful execution of the idempotent code, the corresponding record is updated to reflect execution of the idempotent action and the lock is released. When execution of the idempotent action is unsuccessful, an exception is logged and the lock is released.