# Planning recovery before a new application changes live data

> A deployment rollback does not account for payments already attempted. Follow three recovery cases to decide what to stop, what to reconcile and what must be demonstrated before the new application takes live responsibility.

Paper: 06.3
Published: 2026-11-15
Canonical: https://harten.io/papers/06-3-a-safe-slice-needs-a-way-back/

Cover illustration: [View the title image](https://harten.io/media/papers/covers/v1/06-3-a-safe-slice-needs-a-way-back.jpg?v=203dbc4337bd). Illustrative cover artwork, not an application screenshot or a record of measured results.

## What This Paper Examines

Once a new application has accepted instructions, changed authoritative records or sent requests to another system, disabling it cannot undo everything it has done. This paper follows three payments affected by an illustrative failure: one still local, one accepted externally and one with an unknown outcome. For these circumstances, I would stop further automatic payment dispatch, establish what is known about each affected instruction and place it in the appropriate recovery process. Payment processing could resume once the agreed conditions are met, even if some cases remain under controlled reconciliation. Returning the software to an earlier version may help contain the defect, but it is not the recovery plan for those payments. The paper explains why, what engineers and operations should rehearse before release, and how AI can help investigate and test recovery without deciding which financial actions are authorised. It closes Series 06 by connecting the scope of engineering work with responsibility for its live effects.

## The First Instructions Accepted by the Replacement

Imagine the payments replacement has reached a deliberate release decision. Engineers have developed the required behaviour in the new application, investigated important differences and exercised the relevant integrations. Operations can explain a decision and identify the application responsible for an instruction. The organisation authorises the replacement to handle a defined part of the service, while the established application continues handling the remainder under an agreed ownership arrangement.

In [Choose the first slice for what it teaches you](https://harten.io/papers/06-2-choose-the-first-slice-for-what-it-teaches-you/), I recommended a narrow end-to-end payment path as the first completed engineering slice. That exercise connected assessment, recorded state, the operational explanation and a controlled settlement receiver. It gave the team a useful implementation and a way to examine its behaviour, not permission to process live payments. For this paper, suppose the remaining integration, concurrency and operational work for the selected release scope has subsequently been completed. We are now considering the recovery arrangements that should have been prepared alongside it.

This is a complete new implementation for the responsibilities it has accepted, not a requirement to extract another legacy component. The organisation could also choose one rehearsed cutover where that better suits its service. The recovery question applies to either route: what happens after the replacement has done something on which another person or system now depends?

Suppose a later configuration change allows a retry worker to use an earlier approval without applying the current operational hold check. Some instructions that should have remained under review continue further than intended. This is a different execution path from the controlled interaction examined in the first slice. It needs its own investigation and regression case; the earlier successful exercise did not establish that every later change would preserve the same behaviour.

The release dashboard offers a familiar response: disable the new path and send traffic back to the previous application. That may contain further exposure, but it leaves a different question unanswered. What happened to the instructions already processed? One may still be waiting in the new application's queue. Another may have been accepted by the external settlement system. A third may have been sent without its acknowledgement reaching the application. Returning software to an earlier version does not place these three instructions in the same state, and it does not establish which of them can safely be processed again.

## Containing New Work Without Losing Existing Work

The first response should distinguish preventing further harmful actions from restoring normal operation. In our example, I would pause automatic release for the affected population while preserving accepted instructions and their history. New instructions could be held, referred or directed to an unaffected path according to an arrangement agreed before the incident. The team would not simply send every outstanding instruction through the old application, because some may already have produced an external effect.

A switch that merely changes where new requests arrive may not stop work already in flight. A scheduled process could still select previously approved instructions, or a worker could finish after the routing change. The team needs to know which mechanism prevents further external instructions and how it identifies operations that had already begun. Otherwise the dashboard can report that the new path is disabled while consequential activity continues behind it.

For the retry-worker defect, that means examining the retry and dispatch mechanisms as well as the incoming request route. The pause must prevent further releases through those mechanisms, and the recovery record must account for requests that passed the last effective stopping point before the pause took effect. A payment should not be classified as safely local merely because an operator inspected it before a worker completed its send. The stopping point and the treatment of already-dispatched work are part of the design to rehearse.

The containment control needs a clear scope. Pausing one payment category may be sufficient where ownership and shared dependencies are genuinely separated. It may not be sufficient where the defect changes a shared account position or a rule used by several categories. The daily account limit discussed in [A small code change can have a large consequence](https://harten.io/papers/06-1-a-small-code-change-can-have-a-large-consequence/) remains relevant: activity in either application may affect what the other is allowed to do. Engineers should establish the affected population from the actual implementation, configuration and retained activity, rather than assume it is identical to the intended rollout group.

Operations also needs to know what service it can continue providing during the pause. A manual queue is a workable response only if staff can identify the cases, understand the permitted actions and manage the demand. Keeping the interface available while leaving customers' instructions unaccounted for would not constitute recovery.

## Three Payments and the Actions Their States Permit

The following cases are different recovery situations within the same incident, not competing strategies from which the team chooses only one. I would classify each affected instruction using the retained records and the external system's supported checks, then apply the corresponding authorised treatment. Where the evidence is incomplete, the case stays unresolved rather than being assigned to whichever category is easiest to process.

### A Payment Still Waiting Locally

For the instruction still waiting locally, recovery may be straightforward. Once further dispatch has been prevented and the team has established that no external instruction was issued, it can apply the approved hold and return the case to the correct operational process. The history should show that a candidate decision was made and then corrected, rather than make the earlier action disappear. That gives an operator a coherent account of what happened.

A local status of pending is not enough on its own. The application may have sent the request and failed before updating that status. The classification needs to account for the relevant workers, queued messages and send records. If those records cannot distinguish an unsent instruction from a send whose result was not recorded, I would treat the outcome as uncertain and use the reconciliation route described below.

### A Payment Accepted by the Settlement System

The instruction acknowledged by the settlement system requires a different response. Acceptance is evidence about the external operation, but it does not necessarily mean that final settlement has occurred. The external contract and current state determine what options remain. A request to cancel, reverse or otherwise remedy the action may be available, but it is a separate operation with its own conditions and consequences. The application cannot assume that disabling its local decision retracts an accepted external instruction.

I would establish that current state and use the permitted remedy under the service's agreed authority. Where no automated remedy is supported, the instruction needs the designated operational treatment rather than an invented reversal. The original request and any remedy must remain linked so that the next operator can distinguish an attempted correction from a completed one. A correction that has itself failed or received no acknowledgement also needs reconciliation.

### A Payment With No Acknowledgement

The instruction with no acknowledgement is different again. The absence of a response does not establish that the external operation failed. Retrying without checking can repeat an action that already happened; treating it as complete can conceal an action that never succeeded. The application needs an agreed way to establish or reconcile the outcome, using the identifiers and status mechanisms the external system actually supports.

For this case, I would preserve the original reference, prevent an unexamined resubmission and query or reconcile the outcome through that supported mechanism. A query that returns no record may still need interpretation under the external contract, including any delay before accepted work becomes visible. If the outcome remains unknown, operations should retain the case with an owner and a next permitted check. It should not silently become a failed payment eligible for a new request.

A stable instruction identifier can help correlate the original request, subsequent queries and permitted retries. It is not, by itself, proof that duplicates are impossible. The receiving system's contract, the scope and duration of its duplicate handling and the treatment of changed request details all matter. A repeat using the original reference may be an authorised recovery action where the contract supports it. Generating a new reference merely because the first response was lost can defeat the very protection the team intended to rely on.

| Established state | The recovery action I would take | What would not justify that action |
| --- | --- | --- |
| Still local, with dispatch prevented and no external request issued | Apply the approved hold and return the instruction to operational review, retaining its history. | A local pending status without accounting for queued or in-flight work. |
| Accepted externally, with the current external state established | Use the supported, authorised cancellation, reversal or other remedy and record its outcome separately. | Assuming that rolling back software retracts the external instruction. |
| External outcome unknown | Retain the original reference and reconcile through supported checks or an expressly permitted retry. | Treating a timeout, missing local log entry or confident explanation as proof of failure. |

These distinctions are why I would avoid a recovery plan expressed only as a deployment command. The command can be useful, but the service needs all three routes. The next action follows the established state of the particular instruction, not the operator's preference for returning to familiar software.

## Records Needed to Account for Every Affected Payment

Recovery requires the application to retain enough information to identify the work in question. For the example, that includes the instruction's identity, the relevant decision and input versions, its operational hold history and the external request reference where one exists. Engineers also need to know which release and configuration handled it. A timestamp alone may help narrow an investigation without explaining the result.

The record should distinguish an intended action from an attempted action and an observed outcome. Recording that the application planned to send an instruction is not the same as recording that the receiver accepted it. A local failure after a send can leave uncertainty which needs reconciliation. The application should show that uncertainty in its state and operator view rather than force every case into a misleading success or failure label.

An agent could assemble an initial investigation from an authorised read-only view of those records. For each instruction, I would expect its report to identify the source records, the last established action, the observed external response and any gap that prevents classification. A useful report might say that a dispatch attempt exists but no outcome has been recorded. It should not complete that history with a plausible account of what the receiver probably did. Engineers can then check the selection of affected cases, while operations uses the approved external checks to resolve their status.

This does not require retaining every debug message or copying sensitive input indiscriminately. The information should be appropriate to the service's operational, security and retention requirements. The design question is whether an authorised operator can establish what happened and resolve the case using the retained records and permitted external checks.

The recovery path also needs to preserve valid work. Some instructions processed by the new application may be entirely correct. An operational correction may have been made after the release began. Restoring an earlier database snapshot without accounting for that activity can remove legitimate changes along with the defect. The team must know what it is restoring and how later valid work will be retained or reconciled.

Microsoft's [Compensating Transaction pattern](https://learn.microsoft.com/en-us/azure/architecture/patterns/compensating-transaction) explains that recovering a multi-step operation can require application-specific actions rather than restoring the original data state. It also notes that compensation itself can fail. That distinction is relevant here: the team needs a demonstrable recovery process, with its own progress and failure handling, not a general promise that every action has an automatic inverse.

## Returning Responsibility to the Old Application

Keeping the old application available creates an option, but only if it can correctly handle the state it will receive. Suppose the replacement records a richer set of outcomes or applies an authorised rule that the old application does not understand. Routing an affected instruction back may cause the old implementation to reinterpret it, lose a control or issue an action again.

The return route therefore needs a compatibility judgement. Which records can the old application accept? Which states require translation or reconciliation? What prevents both applications from acting on the same instruction? Which live responsibilities remain with the replacement even after new traffic has moved elsewhere? These questions should be answered for the actual release scope, rather than hidden inside the phrase that rollback is available.

For a staged introduction, ownership should remain identifiable at the level at which the service makes consequential decisions. Switching each request independently can be inappropriate where later requests belong to work already owned by another application. The team needs an arrangement that prevents competing changes to the same authoritative instruction and accounts for relevant shared account state.

There are circumstances in which I would use the old application. If it can accept genuinely new instructions under a rehearsed ownership arrangement, restoring that route may help maintain service while the affected instructions remain in recovery. That is different from replaying the entire backlog through it. If an existing instruction is transferred, the receiving application must have the information and controls needed to continue it correctly, and the replacement must no longer be able to act on it independently.

The return route can also become less practical over time. As the new application introduces capabilities and data that the old application never supported, maintaining full backward compatibility may create significant work without a proportionate benefit. The organisation can decide to stop supporting return to the old implementation. That is a legitimate engineering decision when an adequate recovery route exists in the new service and the consequences of the change are understood.

There is no requirement for an evergreen application to retain every previous implementation indefinitely. The continuing responsibility is to maintain a usable way to understand, contain and recover its current behaviour. The historical system can be retired once the dependencies, records and operating arrangements that still matter have been accounted for.

## Correcting Affected Payments Within the New Application

For the incident described here, I would retain ownership of the already-accepted instructions within the replacement's recovery process while disabling the defective behaviour. Their histories and external references are already recorded there, and returning them all to the old application would not resolve the different external outcomes. This choice does not require the faulty release to keep running. A compatible software rollback or corrective deployment can form part of containment while the records and ownership of accepted work are retained.

The team would suspend automatic progression for the affected population, identify instructions assessed under the faulty conditions and apply the approved treatment to each. The local instruction would remain held. The externally accepted instruction would follow the supported remedy, where available. The unconfirmed instruction would stay in reconciliation until its outcome or the contract's permitted next action was established. Unaffected instructions and valid later corrections would be preserved rather than discarded in a blanket restoration.

This is a forward recovery route: the team accounts for what happened and brings the service to an acceptable state without pretending the intervening activity never occurred. It should not be confused with making speculative repairs directly in production. The permitted actions, their authority and their effect on records need to be understood. Some cases may be resolved mechanically; others may require an accountable person to decide which business action is appropriate. A tool being able to update a record does not establish that the update is authorised.

A recovery plan might propose delaying settlement during an initial release to provide time for intervention. That could be useful where the external contract, customer commitments and service requirements permit it. It should not be assumed available merely because it makes the engineering plan easier. Where an action becomes effectively irreversible sooner, the release decision and the preceding evidence must reflect that condition.

The point is to design a route the service can actually use. A nominal fallback that depends on an unavailable cancellation operation or an unmanageable manual queue offers little protection when the incident occurs.

## Rehearsing Missing Acknowledgements and Interrupted Recovery

I would rehearse recovery before the replacement receives the corresponding live responsibility. The exercise should start from representative states, including instructions still local, instructions acknowledged externally and instructions whose acknowledgements are missing. It should also include unaffected work which must remain intact. That makes the test about restoring the service, not merely restarting a process.

The team should exercise the mechanism that stops further consequential actions, including the retry worker, then demonstrate how it identifies and classifies the affected instructions. Operations should be able to use the retained explanation and the permitted checks to determine the next action. Where the route returns responsibility to the old application, the exercise should show that the returned state is compatible and that the replacement cannot continue acting on it.

An engineer could ask an agent to extend the controlled settlement receiver from 06.2 so that it records acceptance of a request but withholds the acknowledgement. The application would time out even though the receiver had accepted the instruction. The engineer would then inspect both sides: the receiver's retained action and the application's recovery record. The expected result is not merely that a retry test passes. The application must avoid treating the timeout as proof of failure and must reach the next permitted action through its reconciliation procedure. A second case in which the receiver never accepts the request should test the permitted next action under that condition. If the supported checks cannot yet establish whether acceptance occurred, the application should keep the case unresolved and record the next permitted check.

The agent can construct these cases and run them repeatedly without access to live settlement. The engineer still needs to check that the fixture actually represents acceptance followed by a lost acknowledgement. A fixture that returns an error before accepting anything would avoid the very uncertainty the test is intended to examine. The intended outcomes come from the approved recovery contract, not from whatever behaviour the candidate implementation happens to produce.

Recovery can itself be interrupted. Suppose a permitted cancellation is accepted externally but the recovery worker stops before recording the response. On restart, the original payment and its attempted cancellation have different histories to reconcile. Repeating the cancellation blindly is not an adequate restart policy. The retained references and progress must allow the worker or operator to determine what happened before taking the next authorised action. An operator handing over to another shift needs that same information.

The observed result should be recorded with its scope. A successful exercise using a controlled settlement response establishes the application's behaviour against that response. It does not establish the real external service's cancellation or duplicate-handling behaviour. Those parts need the evidence available through the integration contract and an appropriate test arrangement. Any limitation that changes the release decision belongs with that decision.

Once the agreed recovery behaviour has been demonstrated, the team should state that result directly. It need not reopen the completed exercise because unrelated parts of the application have further work to do. For the selected scope, the useful result is that affected instructions can be accounted for, authorised recovery can resume after interruption and valid work remains intact.

## The Evidence Required Before Live Payment Processing

The release decision should bring the implementation and recovery evidence together. The service owner needs to know what responsibility is moving, which population is affected, how a problem will be detected and what the team can do after detection. Engineers and operations need to understand the same limits, including any point after which a simple return is no longer supported.

For this example, I would require a demonstrated stop for further automatic releases, an account of the instructions already in flight and a usable treatment for each of the three recovery states. I would also require the interrupted-recovery case to preserve completed actions rather than repeat them, and the unaffected cases to remain unchanged. Operations should be able to identify who owns an unresolved instruction and what action is allowed next. These are specific acceptance conditions for the proposed release, not a demand to solve every conceivable future incident.

If the application can restart but cannot distinguish an externally accepted payment from one that was never sent, I would not approve automatic live processing for that scope on the strength of the restart. The next work would be to establish the missing reconciliation capability or choose an agreed service arrangement that avoids the unsupported action. Equally, once the relevant behaviour is demonstrated and the remaining operational responsibilities are accepted, I would not keep the release blocked merely because the whole replacement programme is unfinished.

Google's [canarying guidance](https://sre.google/workbook/canarying-releases/) describes evaluating limited production exposure with signals suited to the service. For this example, request success and latency would not be enough on their own. The release also needs observations that distinguish payment acceptance, holds, manual-review demand and uncertain external outcomes. These measures follow the behaviour whose failure the programme is trying to contain.

The evidence can support automated containment within an agreed policy. For instance, a defined condition might stop new automatic releases and preserve work for investigation. That is different from allowing the automation to reinterpret disputed cases or broaden the eligible population. The boundaries of those actions should be decided before the release, while the team has the time and context to consider them properly.

The same recovery requirements apply to a single rehearsed cutover. A team can decide that the cost and complexity of prolonged coexistence are not justified, then prepare a deliberate transfer with a demonstrated recovery procedure for the responsibilities being moved.

## Agent-Assisted Investigation and Authorised Recovery Actions

Agents can contribute substantially to recovery engineering. They can help identify affected records, reconstruct an action history, compare versions, prepare a corrective implementation and generate tests from retained failure cases. They can also assemble a proposed reconciliation report for an operator. These tasks are valuable when they reduce the work required to establish what happened and restore an acceptable service.

The limits should follow the effect of the action. An agent investigating a read-only copy of the relevant records has a different responsibility from one authorised to resubmit payments or alter live state. A plausible explanation is not sufficient grounds for a consequential repair. The proposed action needs the correct evidence, the approved business meaning and the required authority. In our example, an agent finding a missing acknowledgement can identify the gap and prepare a status check. It cannot infer permission to create a replacement payment from that gap.

The recovery procedure should also distinguish a failed tool response from a failed operation. An agent that receives no confirmation after requesting an external action should check its outcome through the supported mechanism before deciding that repeating it is harmless. The same discipline applies to the application itself. The uncertainty concerns what happened outside the process, not how confidently a participant describes what it intended to do.

An agent can be given broad freedom to implement and test a recovery mechanism in a bounded environment. Production action can then follow an explicitly authorised procedure or return to an accountable person where the decision remains unresolved. A human need not approve every routine query or replay of a synthetic test. The engineer establishes that the procedure examines the relevant failure; operations confirms that it can use the resulting records; and the service owner approves the business treatment and the release of live responsibility. Those are different judgements, not a single approval button placed after the agent's report.

## Why I Would Contain and Reconcile Before Resuming Payments

For the failure described here, I would first prevent further automatic releases and retain the records and ownership of the instructions already accepted. I would then account for each instruction using the three recovery routes: correct locally held work, establish the permitted remedy for externally accepted work and reconcile work whose external outcome remains unknown. The software version may change during that process, but changing it does not settle the status of any of those payments.

I would choose this approach over sending the entire backlog back to the old application because the backlog no longer represents one kind of unfinished work. Some instructions have not left the replacement; others have already affected another system. Processing them all again would ignore the information needed to choose the next action. I would also reject a blanket database restoration that removed valid activity without a plan to retain or reconcile it. The recovery process should correct the defect and its consequences without creating a second incident by losing good work or repeating completed actions.

Resuming the service does not always require every exceptional case to have reached a final business outcome. A case may legitimately remain in a controlled reconciliation process. It does require that the defect has been contained or corrected, the affected population is accounted for, unresolved cases have an owner and permitted next action, and the agreed conditions for further processing have been met. Before the retry path is re-enabled, its regression case should demonstrate that an earlier approval cannot cause a payment to be sent while a current hold is in force. The service owner and operations can then decide what can resume without treating unresolved instructions as either forgotten or automatically safe to retry.

That is the practical conclusion to Series 06. The [flagship paper](https://harten.io/papers/06-modernisation-should-be-sliced-by-risk-not-repository-structure/) distinguished the architecture, engineering work and transfer of live responsibility. 06.1 followed the consequences of a small change. 06.2 selected an end-to-end first slice because the important uncertainty lay in the interactions. This final paper adds the recovery behaviour needed before that implementation is allowed to affect live work. Together, the papers show why completing an engineering slice and approving its live use are related but separate decisions.

The programme can still deliver a completely new application. It need not reproduce the old repository structure or retain the previous implementation indefinitely. After the replacement is established, its recovery arrangements must change with it. A new external integration, data representation or authorised business rule can alter what the service needs to restore after failure. Keeping the requirements, implementation and relevant exercises current is part of the continuing responsibility described in [How to build a new application and keep it evergreen](https://harten.io/papers/05-3-the-route-to-the-target-is-part-of-the-architecture/).

The next series examines how much of this work software agents can undertake and how their authority should be bounded. Recovery makes that question specific: permission to investigate an uncertain payment is not permission to issue it again. Engineers can delegate substantial investigation, implementation and testing while keeping consequential actions within the organisation's agreed authority. The useful result is a service that can explain what happened and recover through an authorised, demonstrated procedure, not simply a faster way to make another change.

---

*The payments service, retry-worker defect and recovery situations are illustrative. The paper does not claim that a live payment incident, settlement cancellation or recovery rehearsal has been performed. External references support the practices specifically attributed to them; the proposed operating choices depend on the example's requirements and actual integration contracts.*

*This paper is part of The Modernisation Control Papers, the first major sequence within The Harten Papers. [Read the complete series on harten.io](https://harten.io/papers/).*
