Go to home page
 

Long-Running Workflows: Connecting Business Processes That Unfold Over Time

Enterprise integration is no longer only about moving data between applications or exposing business capabilities through APIs. Many of the processes that organizations depend on span multiple systems, continue over time, require human decisions, and increasingly include AI agents alongside traditional applications and services.

Consider a claims process. A claim can be received and validated automatically, but completing it may require information from another system, additional customer documents, a decision by an employee, or further automated processing. Some steps happen immediately, while others may happen hours or days later. If something fails along the way, the business needs to understand what happened and determine how the process should continue.

From a business perspective, all of this is a single process, but the underlying technology needs to maintain continuity from the initial request through to the final outcome.

One business process, multiple workflow patterns

Traditional integrations often have a relatively clear execution boundary. An API receives a request, interacts with several systems, and returns a response. An event triggers an action, or an automation runs on schedule.

Business processes are often less predictable. A process may need to stop until a supplier responds. A high-value transaction may require approval. A failure may need to be reviewed before processing continues. An AI agent may perform much of a task autonomously, but require human authorization before taking a sensitive action.

Supporting these scenarios requires more than connecting the individual systems involved. The process itself needs to maintain its state, understand what it is waiting for, provide visibility into what has happened, and know how to continue when the next action becomes possible.

This gives rise to several workflow patterns, each addressing a different aspect of how real business processes operate.

These patterns should not be viewed in isolation. A real business process may combine several of them.

A claims process, for example, could begin as a transactional workflow, use an AI agent to assess submitted information, pause while waiting for additional documents, create a human task when specialist review is required, and allow an operations team to investigate and retry a failed interaction with an external system.

From the business’ perspective, these are not separate technologies or processes but one claim moving toward resolution.

This is ultimately the value of workflow orchestration: maintaining continuity across systems, people, events, time, and AI, while keeping the business outcome at the center.

Long-running and interruptible workflows: when the business needs to wait

Waiting is a normal part of many business processes. An order may wait for inventory, an onboarding process may wait for documentation, a logistics process may wait for confirmation from a partner, or a subscription process may wait until a future renewal date.

The challenge is that these waits can last much longer than an individual application execution. The process needs to pause without losing its progress, then resume when the expected event occurs.

An interruptible workflow allows the process to stop at the appropriate point and wait for an external event. When that event arrives, the workflow resumes from where it left off and continues toward the business outcome.

This allows organizations to represent a long-running process as one continuous business journey rather than breaking it into disconnected integrations, scheduled jobs, and custom mechanisms for remembering what happened earlier.

Human-in-the-loop workflows: combining automation with human judgment

Automation can handle an increasing amount of business activity, but many processes still contain decisions that require judgment, accountability, or authorization.

A large purchase may require manager approval. A suspicious insurance claim may need specialist review. An account application may need compliance approval before activation.

Human-in-the-loop workflows make these decisions part of the process itself. Tasks can be created for the appropriate business roles and presented to users for action, while the organization can manage and track those tasks as part of the overall business process. Once the required decision is made, automated processing can continue.

This creates a more natural relationship between people and automation. Employees remain involved where their expertise or authority is needed without separating those decisions from the broader automated process.

Transactional workflows: keeping critical processes under control

As workflows coordinate more business-critical activities, organizations also need to understand what is happening while those processes are running.

A transaction may involve several systems and multiple steps. If one of those steps fails, simply knowing that the process failed is often not enough. Operations teams need to understand which process was affected, what has already completed, where the problem occurred, and what action is required to move forward.

These teams need visibility into individual workflow instances and the ability to identify where an activity has failed so that the appropriate recovery action can be taken, making workflow management and observability important aspects of successfully operating transactional workflows

This becomes particularly important when earlier steps have already produced real-world effects, such as updating an account, creating an order, sending a notification, or interacting with an external service.

Durable agents: bringing AI into reliable business processes

AI agents introduce another dimension to workflow orchestration. An agent can reason about a task, select tools, interact with enterprise systems, and dynamically determine its next action.

Autonomy, however, does not remove the enterprise requirements around reliability and control.

An agent may need to wait for information that arrives later. A particular action may require human approval before it can proceed. Certain high-impact actions may need to be explicitly gated, and failures must still be handled without losing the progress already made.

This is where the concept of a durable agent becomes important. A durable agent is when agentic execution operates within a longer-running process that can survive interruptions, wait for external events, introduce human tasks and gated execution where appropriate, and provide a path for handling errors.

The result is a model in which organizations can benefit from agent autonomy while retaining control over the broader business process.

Handling failures without starting over

Failures are inevitable when processes span multiple applications, networks, partners, and services. The more important question is what happens after a failure occurs.

Some failures are temporary and can simply be retried. Others require someone to investigate the problem first. In some cases, the information that caused the failure may need to be corrected before processing can continue.

A business workflow, therefore, should provide more than a simple “fail” or “success” outcome. Operations teams should be able to review what went wrong, retry the affected step after resolving the underlying problem, and correct relevant information before trying again.

There are also situations where a completed transaction may need to be replayed. Examples of such scenarios include an issue being discovered at a later time or when downstream processing needs to be performed again. When the original process involved human decisions or external events, replay must also account for those interactions rather than blindly repeating everything that happened previously.

The broader goal is to make recovery a managed part of operating the business process rather than relying on ad hoc procedures whenever something goes wrong.

Bringing these capabilities together with WSO2 Integrator

WSO2 Integrator brings these workflow capabilities into the same environment organizations use to integrate AI agents, applications, APIs, data, events, and enterprise systems.

This combination is important because workflows rarely operate in isolation. The activities within a workflow still need to communicate with AI agents, SaaS applications, enterprise systems, partner APIs, databases, events, and other business services. Bringing workflow orchestration and integration together allows organizations to coordinate the overall process while using integration capabilities to perform the work behind each step.

WSO2 Integrator supports long-running and interruptible workflows that can pause for external events, human-in-the-loop workflows with role-based tasks and task management, transactional workflows with instance-level visibility and recovery, and durable agent scenarios that combine agentic execution with human tasks, gated actions, external events, and error handling.

For business-critical processes, this also means providing the operational capabilities required after deployment. Workflow instances can be observed and managed, failed activities can be investigated and retried, data can be corrected before retrying when appropriate, and transactions can be replayed when business operations require it.

Enterprise integration has traditionally focused on ensuring that independent systems can communicate. As business processes become more distributed and AI becomes a more active participant in enterprise operations, organizations also need to maintain continuity throughout the processes that follow those connections.

The process needs to remember what has already happened, wait when necessary, involve people at the appropriate points, recover when something goes wrong, and continue until the intended business outcome is reached.

By bringing workflow orchestration together with enterprise integration, WSO2 Integrator extends the integration layer from connecting individual interactions to coordinating complete business processes that span systems, people, and AI.