-
Notifications
You must be signed in to change notification settings - Fork 13
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Feature: A dummy Rust Lambda extension #1
Comments
Should be pretty straightforward with the new |
Is it available as a cargo crate? |
Not yet, but you can use it from git at the moment :) lambda-extension = { git = "https://github.com/awslabs/aws-lambda-rust-runtime", branch = "master" } |
Apparently you can just call /register RAPID API as an “internal extension”
and you also get the SIGTERM Benefit without needing s Layer and such
…On Thu, 27 Jan 2022 at 16:58, Nicolas Moutschen ***@***.***> wrote:
Not yet, but you can use it from git at the moment :)
lambda-extension = { git = "https://github.com/awslabs/aws-lambda-rust-runtime", branch = "master" }
—
Reply to this email directly, view it on GitHub
<#1 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AAZPQBBAPHKQKO4MDYX34UDUYFTQPANCNFSM5M56QK6A>
.
You are receiving this because you authored the thread.Message ID:
***@***.***
com>
|
@heitorlessa could you explain what you mean by "call/register RAPID API as an internal extension"? Thanks in advance! |
@luigidragone96 an internal extension is a thread in a lambda function that talks to the extension API. We have some examples. I will post it here once I found it. |
Thank you! The examples would be very useful. |
@bnusunny thanks for sharing this example.
NodeJS lambdas don't support internal extensions? |
Could you share your test code? Extension registration should happen during the init phase (before the handler function is called). |
So we can't use the graceful shutdown if we don't use any external extensions? Is there a way to create a dummy extension in Node.js that would serve only to catch the SIGTERM signal in lambda handler? |
Both external and internal extensions can enable graceful shutdown. You can create an internal extension in node.js following the python example I posted above. |
@bnusunny Thank you! Do you have an example of an internal extension written for Node.js, or maybe just a code example with some descriptions of what we should do and why? |
Firstly, thank you for creating this repository. It's a great finding to know any External Lambda Extension gives customers the ability to handle SIGTERM signal.
It'd be great to have a dummy extension instead of Lambda Insights, since the latter can incur charges.
The text was updated successfully, but these errors were encountered: