FDE Times dataFDE jobs open 932▼14 Change in open roles over 7 days, like-for-like: roles from companies we started tracking this week are left outNew in 7 days 62Companies hiring 202Remote-friendly 24%Median US pay $201kTop hirer Databricks 92
中文VI

The newspaper of the Forward Deployed Engineer

Tools

Your agent crashed at order 120. Temporal saves the 119 before it

Temporal's chief executive argues agentic AI mostly exposes old problems of state and error handling, so the hard part of production agents is rarely the prompt.

ShareLinkedInFacebookX

In brief

  • Temporal moves failure handling out of application code and into the platform: when a worker crashes, the Temporal Service hands the work to another worker.
  • Recovery relies on Event History, so Workflow code must be deterministic; LLM and tool calls belong in Activities.
  • Activities are retried automatically, so making them idempotent is your job.
Horizontal bar representing 200 orders. The first 119 orders are shaded blue, labelled as done and replayed, with no repeat LLM calls. An orange marker flags order 120, where the worker died. The remainder is shaded light grey, labelled as resuming from order 120.
Thanks to Event History, the new worker replays the recorded results of the first 119 orders instead of calling the LLM again, then resumes from order 120. Source: illustrative example, based on Temporal's official documentation.

Take an agent reconciling 200 orders for a logistics client. For each order, it calls an LLM to read the shipping documents, then writes the result into the client’s ERP. At order 120 the ERP hangs, and the worker running the agent dies with it.

If the whole loop lived in memory, the 119 processed orders are gone. Starting over costs another 119 LLM calls and, worse, risks writing duplicates into the ERP. On a client site, an incident like that is enough to ensure the second demo never happens.

This is the problem Temporal is built for. Samar Abbas, Temporal’s chief executive and co-founder, argues that agentic AI does not create new problems so much as expose old ones, such as state management and failure handling. For a forward deployed engineer, that remark works as a reminder: the hard part of a production agent usually lies somewhere other than the prompt.

What does Temporal do, in brief?

Temporal is an open-source, MIT-licensed platform from Temporal Technologies. You write business logic with the SDK for your language, and Temporal runs that code as Durable Execution. The official documentation states that once started, a Workflow runs to completion, whether that takes seconds or months.

The core idea is to move failure handling out of application code and into the platform. When a worker crashes, the Temporal Service hands its work to another worker. There is no need to write your own checkpoints, store a “how far did we get” flag in a database, or build a retry queue.

The company is also betting openly on agents. Its homepage carries a dedicated use case for agents, MCP and AI pipelines that keep running through failures. Its funding announcement in February 2026 put agentic AI in the headline.

Recovery by rereading history

Temporal takes no memory snapshots. Everything that happens in a Workflow is recorded in the Event History, an ordered log that the documentation treats as the source of truth for everything that occurred in the Workflow. When a new worker picks up the job, it replays this log to rebuild the state.

Apply that to the 200 orders. Each LLM call and each ERP write is an Activity. The results for the first 119 orders already sit in the Event History. The new worker replays it, sees that 119 steps already have results and so skips calling them again, then carries on from order 120.

The ERP call that hung at order 120 is retried automatically according to the Retry Policy. The advice here is to avoid leaving that policy on its defaults without review: check it, and set the maximum number of attempts and the timeouts explicitly so they match what the client’s systems can bear.

Replay comes with a discipline that newcomers often trip over.

The line between Workflow and Activity

Because Workflows are replayed, Workflow code must be deterministic: given the same history, it must make the same decisions. An LLM call with the same prompt can return a different answer next time, so it cannot sit directly in a Workflow. Calls to LLMs, tools and client APIs all belong in Activities.

Workflow Activity
What it holds Orchestration logic: step order, branching, the agent loop Failure-prone work: LLM calls, tools, ERP, sending email
Requirement Deterministic, because it will be replayed Should be idempotent, because it will be retried
On failure Another worker replays the Event History and continues Retried automatically under the Retry Policy
Common mistake Calling an LLM or reading the system clock inside the Workflow Writing duplicate records on retry

The right-hand column is where the FDE has to do their own share of the work. Temporal recommends that Activities be idempotent: running one twice should not produce two side effects.

Walk through a concrete case. The Activity writes order 120 to the ERP. The ERP actually saves it, but the response does not come back in time, so the Activity is treated as failed and retried. If the Activity only knows how to “create a new record”, the ERP now holds two rows for the same order.

The fix is to write with a unique key derived from the order ID. The retry sends the same key, the ERP recognizes that the record exists and simply updates it, so however many retries run, there is still only one row. Temporal handles the retrying; whether a retry is safe remains your responsibility.

When to use it, and when it is overkill

Temporal earns its place when an agent runs many steps, runs for a long time, and touches systems you do not control. That is close to a description of FDE work: a pipeline reading documents all night, an agent waiting for human approval before it continues, a tool-calling loop hitting a client’s flaky internal API.

For a chatbot that answers once and stops, adding Temporal means one more platform to operate for almost no gain. The real cost lies in the deterministic discipline. A team used to writing agents as one long script will have to restructure its code, and non-determinism bugs tend to surface only during replay, which is to say in the middle of an incident.

On client sites that run on-premises, the calculation needs even more care. If the Temporal Service lives in the client’s infrastructure, someone on their side has to be on call for, and operate, yet another system after you leave. For a pipeline of a few steps that runs in a few minutes, a simple status table plus manual retries may be easier to hand over.

What to learn first before using it on a client site

Skip installing a cluster at the start. Learn four concepts in order: Workflow, Activity, Event History, Retry Policy. Temporal’s official AI Cookbook is a good place to begin.

It includes a recipe that builds an agent on the OpenAI Agents SDK, survives failures and picks its own tools to answer a user’s question. Alongside it is another recipe for an agentic loop with tool calling.

One exercise is worth the time: take that recipe, add an Activity that writes results to a mock ERP table, then kill the worker partway through and restart it. Afterwards, count the rows in the table. If you find duplicates, you have discovered for yourself why an idempotency key has to exist from day one.

When reading job descriptions for FDE or AI engineer roles, watch for phrases such as “durable execution”, “long-running agents” or the name Temporal. On a CV, a line such as “multi-step reconciliation agent that recovers automatically from worker crashes, with Activities made idempotent by order ID” carries far more weight than “experience with LLMs”.

On a client site, the first question is which model is smartest only for people who have never been paged. The question that matters is what your agent will do when their ERP goes down at 2am.

Was this article useful?

Use with your AI assistantAsk Claude ↗Ask ChatGPT ↗
6 sources
Read next on the roadmap · Stage 3: Applied AIDSPy turns a client's eval set into a machine that finds promptsAn algorithm once beat the best-known human-written reasoning prompt; DSPy applies that search to whole pipelines, so switching models no longer means retuning by hand.