Add [lambdex].layout to opt-in to soon-to-be-deprecated FaaS behaviour #19072
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This adds a
layout
options to the[lambdex]
scope, so that current users can explicitly opt-in to the current behaviour for building FaaS artifacts (python_awslambda
,python_google_cloud_function
), to allow us to change the default behaviour without breaking them.The current behaviour uses Lambdex to adjust a PEX to be runnable in the FaaS environments, but it's still a PEX under the hood, with dynamic dependency selection on start-up. The new behaviour (#18879, first attempted in #19022) will be to lay out a "normal" zip with the dependencies statically included at the top level, since the serverless environments are fixed and known at build-time. We plan to switch the default to the new behaviour in 2.18, and remove the
lambdex
option in 2.19.The suggestion is to cherry-pick this back to 2.17.x, to allow us to deprecate and remove Lambdex sooner. See #19032 (comment) for discussion.
(This PR is currently stacked on top of #19071.)