-
Notifications
You must be signed in to change notification settings - Fork 819
Open
Labels
Description
Is this feature request related to a new or existing Amplify category?
No response
Is this related to another service?
No response
Describe the feature you'd like to request
In Gen1, its possible to create functions in various languages:
? Choose the runtime that you want to use: (Use arrow keys)
.NET 8
Go
Java
❯ NodeJS
PythonWe currently only support the NodeJS runtime - we should support all.
Describe the solution you'd like
In Gen2, non JS runtimes are supported via a flavor of the defineFunction API:
export const sayHelloFunctionHandler = defineFunction(
(scope) =>
new Function(scope, "say-hello", {
handler: "index.handler",
runtime: Runtime.PYTHON_3_9, // or any other python version
timeout: Duration.seconds(20), // default is 3 seconds
code: ...
);More information here: https://docs.amplify.aws/vue/build-a-backend/functions/custom-functions/.
Implementation Notes
- Since the CDK
Functionconstruct exposes the same API regardless of runtime - we expect common logic to support all different languages. If however we see that special handling is needed per language, we should prioritize python and go first.
Describe alternatives you've considered
None
Additional context
No response
Is this something that you'd be interested in working on?
- 👋 I may be able to implement this feature request
Would this feature include a breaking change?
-
⚠️ This feature might incur a breaking change
Reactions are currently unavailable