Files
floci/docs
TATSUNO “Taz” Yasuhiro bf82846971 feat(lambdaweb): keep the code a revision was created from (#6113)
* feat(lambdaweb): keep the code a revision was created from

A revision reads its code object at creation and keeps its own copy under
the Lambda code path. New environments start from that copy, so a later
write or delete in the bucket no longer changes what the revision runs.
AWS pins the version that was current at creation when the request names
none, and serves it after that version is deleted.

A versionId that cannot be read gets the AWS wording. A 404 from S3 says
the object does not exist with the versionId, and any other error says the
object is inaccessible.

* fix(lambdaweb): start environments only from the kept code

Lambda Web is in no release yet, so every stored revision has its copy and
the S3 fallback could only run changed code. A missing copy is now an error.

At start the copies that no stored revision names are removed, such as
those a restart in memory mode or a failed delete left behind. A failed
write removes its partial file. Path segments escape every byte but
letters, digits, - and _, so two region names never share a directory.

* fix(lambdaweb): stream the code copy instead of holding it in memory

A revision now streams its code object from S3 into its copy, and an environment opens that copy in place through a new ZipExtractor overload. Neither step loads the object into the heap, and a start no longer writes the archive to disk again before unpacking it.

* chore: share one recursive delete across services

FileTrees.delete replaces the copies in Lambda Web, ZipExtractor, CodeStore, Lambda layers, CodeBuild, S3 and CodeArtifact. Each caller keeps its own log message and level. A failure no longer stops the rest of the tree, and the walk stream is always closed.
2026-10-21 00:51:57 -04:00
..
2026-03-15 17:43:56 -05:00