← AWS Solutions Architect Professional: complex decisions
24 / 25 · 130 MIN

Modernization and orchestration

Decompose a legacy workflow while preserving contracts, business effects, and recoverability.

Extract a capability with a clear boundary

A fictional position-publication batch combines validation, transformation, and delivery to several consumers. Modernization does not require replacing everything at once. A strangler fig can route an already validated capability to a new service while other functions remain in the legacy system.

Define data ownership, contracts, routing, and exit criteria before extraction. Splitting only by technical layer can leave every service dependent on the same change and transaction. The transition proxy also needs capacity and availability; adding microservices does not remove that failure point.

An anti-corruption layer translates semantics between models, including units, states, and identifiers. It should not indefinitely hide who owns an incompatible contract. Include its monitoring, release process, and eventual retirement in the plan.

Resolve dual writes without inventing a global transaction

If a service commits its database and fails before publishing an event, the consumer might never learn about the change. In a relational outbox pattern, the business change and event record belong to the same local transaction. A separate publisher reads committed changes and sends the event.

This closes the gap between commit and publication intent but does not turn database and broker into a global ACID transaction. Delivery can repeat; preserve event identity, required ordering, and idempotent consumers. Measure publisher delay and failures and define replay.

Committing an outbox row does not establish that the consumer applied the effect. Business-visible status should reflect the stage actually demonstrated, with reconciliation for deliveries whose outcome remains uncertain.

Compensate effects and make irreversibility explicit

A saga coordinates local transactions and compensating actions when the flow cannot finish as planned. Compensation is not equivalent to ROLLBACK in a single transaction and does not automatically isolate concurrent sagas. A reservation may be released, but an already delivered notification does not disappear.

Define repeatable, compensable, and irreversible steps, with durable records and an exception owner. If compensation fails, the flow remains incomplete; do not report success merely because the original error was caught. Participants and compensations should tolerate repetition according to their contract.

A circuit breaker can reduce pressure on a failing dependency but does not establish earlier call outcomes or replace business-effect reconciliation. Test partial progress and recovery, not only the successful path.

Choose the workflow and the meaning of completion

Step Functions Standard and Express have different models. Standard supports durable workflows and job or callback waiting patterns; Express has a five-minute maximum and does not support .sync or .waitForTaskToken. Distinguish asynchronous Express, with at-least-once execution, from synchronous Express, with at-most-once execution.

These properties are not a global transaction over external effects, and explicit retries can repeat tasks. Request Response advances after the API response, which may only acknowledge submission. The .sync pattern waits for a supported job, but cancellation is best effort.

Callback requires token correlation and appropriate authorization; an external system can communicate through an authorized bridge while respecting the same-account-principal requirement when returning the token. Confirm what the downstream consumer treats as completed work.

Bound retries and handle the correct error

An applicable Retry is evaluated before Catch. Define transient errors, retry count, backoff, jitter, and total deadline without automatically retrying business rejections. MaxAttempts counts retries and excludes the initial attempt.

In the original model, three retries after waits of 2, 4, and 8 seconds produce at most four attempts and fourteen seconds of waiting, excluding task execution. States.ALL does not catch States.DataLimitExceeded or States.Runtime; current documentation allows explicit handling of DataLimitExceeded.

Do not extend that possibility to Runtime. A workflow’s top-level timeout is not an error caught by an arbitrary Catch in the same machine. Heartbeats establish activity, not success, and do not remove the total execution limit. Observe the actual failing layer before changing retry behavior.

Prove resumption, observability, and transition to RUN

For Standard, repeating StartExecution with identical name and input while an execution is running has specific idempotent behavior; changing input or using a closed execution is a different situation. Express does not offer that start idempotency.

Nor should complete Express history be assumed merely because CloudWatch Logs is enabled: delivery is best effort. If the business requires durable evidence, design appropriate records and state reconciliation. Handover should include correlation among request, workflow, outbox, and consumer, procedures for uncertain outcomes, and compensation limits.

The PM requests recovery evidence after failures and criteria for retiring legacy functions. A green orchestration result is accepted only when that state’s meaning matches the business commitment, including required downstream acknowledgement rather than submission alone.

Translate meaning using boundary cases

Build a transformation matrix with fields, units, signs, and allowed states. Include values distinguishing a per-record rule from a global rule: two numerically identical inputs can represent different amounts. Define unknown-code behavior before publishing.

Quarantine should preserve identity, origin, and reason so resolution does not invent meaning. Also compare totals and signs after transformation; message counts do not detect incorrect scale. During implementation, choose decimal representation appropriate to the contract.

Acceptance checks positive, negative, and unknown examples and identifies who may approve new mappings.

Accept recovery using net work reduction

Separate arrival rate, publication capacity, and free destination capacity. Drainage is effective service minus new arrivals, not gross throughput. Reserve other applications’ consumption before calculating the publisher limit.

Compare minimum time with the agreed deadline and state the remaining delivery balance. If the deadline cannot fit, present a capacity, admission, or deadline decision while retaining obligations. In a later trial, observe errors, duplicates, age, and consumer acknowledgement.

An empty queue and destination acknowledgement establish different stages; the contract must identify which closes the work.

Protect acquisition and compensation

Write the resource invariant before the workflow: nonnegative capacity, one owner, and correspondence between operation and reservation. Evaluate interleavings where two sagas observe the same state. The decision consuming capacity must check its condition at write time rather than rely solely on an earlier read.

Then evaluate recovery: a saga acquiring nothing must not release another saga’s resource. Preserve durable identity for repetition and distinguish conflict from unknown outcome. The same rules must survive orchestrator restart.

The saga coordinates the path; the participant remains responsible for protecting the state it commits.

Separate execution and business identity

Record the business operation using stable identity, payload, and result at the boundary committing its effect. A start call can lose its response without losing the effect. Before retrying, distinguish identical repetition, changed intent, and recovery of a completed operation.

A machine naming policy does not replace this distinction. For Standard, also consider whether execution is running and input is identical; starting again does not implicitly query a closed execution. Retain both execution reference and business identity to investigate both layers. Do not erase evidence to make a conflict disappear.

Close recovery using participant effects

Build a per-participant record: identity, observed state, confirmed effect, unknown outcome, reserved resource, and owner. Orchestrator status does not replace these fields. For still-active work, define how to prevent obsolete publication and confirm cancellation outcome in the service executing it.

Do not release protected capacity merely because the machine no longer waits. For compensation, retain original identity and record what remains irreversible or unknown. Handover should identify the next action and evidence authorizing closure of each obligation.

An acceptance response or execution of Catch does not establish that closure.

Budget attempts, waiting, and completion

Draw the timeline including the initial attempt. For each retry, calculate exponential waiting and apply the configured cap before summing. Add each call’s duration, preparation, and final stages included in the contract.

Jitter changes the waiting distribution; it does not justify replacing an upper bound with an average when the requirement demands a guaranteed deadline. Compare attempt, timeout, and capacity alternatives, explaining the recovery trade-off.

Also verify that repetition is safe and the error is eligible. A deterministic model helps detect incorrect arithmetic but does not measure actual duration or service delays.

retry_count = 3
interval_seconds = 2
backoff_rate = 2
waits = [interval_seconds * backoff_rate ** i for i in range(retry_count)]
maximum_attempts = 1 + retry_count
total_wait_seconds = sum(waits)
# Original deterministic model: [2, 4, 8], four attempts, 14 seconds waiting.
# Excludes task duration, jitter, caps, redrive and other retriers. Not an AWS execution.
IN PRACTICE

In a fictional case, the new flow marks publication complete when the API accepts the job. The consumer has not received the positions yet. APS and business teams review completion state, correlation, and evidence before retiring the legacy batch.

Common pitfalls

Confusing outbox with single delivery, saga with ACID isolation, API response with completion, heartbeat with success, or best-effort logs with complete history.

Related topics: Performance, caching, and evidence

Take this idea with you

Modernization preserves meaning and recovery when each state, retry, and compensation has a demonstrable contract.

Create account

References

AWS is a trademark of Amazon.com, Inc. or its affiliates. bigsavant.com is an independent preparation platform and is not affiliated with, associated with, sponsored, authorised or endorsed by AWS. Content and questions are original, are not official exam questions, and completing our tests does not award or guarantee any certification. Names are used only to identify the subject. All other trademarks belong to their respective owners.