Files
floci/docs/services
TATSUNO “Taz” Yasuhiro 6e6ce61eea feat(lambda): durable function chained invokes (#5164)
* feat(lambda): durable function chained invokes

A CHAINED_INVOKE operation runs another function. A durable target
needs a version or alias and runs as its own durable execution with a
random name; its close completes the operation as SUCCEEDED, FAILED,
TIMED_OUT ("CHAINED_INVOKE timed out after N seconds.") or STOPPED. Any
other function is invoked once, and an output over 1 MB fails the
operation. A missing function or an unqualified durable one fails the
operation at once. Stopping the parent leaves the child running.

A plain chained invoke lost with the process runs again after a restart,
and a durable child that closed before its report reaches the parent
reports then.

* fix(lambda): close the gaps in durable chained invokes

A durable child that closes during a restart reports to its parent
under its own lock, and recovery triggers an execution once. A durable
target invoked without Payload starts its child with no input, while a
plain target gets {}. A target started in the batch that closes the
execution still runs and its result is ignored, as on AWS.

* fix(lambda): reject a chained invoke of another account or region

AWS rejects the checkpoint with InvalidParameterValueException "Cannot
start a CHAINED_INVOKE on a function in another account." or "... in
another region." Cross-account chained invocations are not supported.

* fix(lambda): keep durable chained invokes across a crash

The parent is saved before the child it starts, so a crash in between
leaves no child the parent does not know. On restart a child the parent
recorded but the store lost is started again under the same ARN, and a
plain target started by the checkpoint that closed the execution runs
again until its result is recorded. A child reports only to the
operation that started it.

* fix(lambda): recreate a lost durable child on the version its ARN names

An alias the chained invoke named may point to another version after a
restart, and a child recreated there would not match the ARN the parent
saved.
2026-10-06 08:17:51 -04:00
..
2026-08-21 00:09:04 -04:00