fastify / fastify/aws-lambda-fastify

AWS Lambda plans to remove support for callback-based function handlers

未关闭
#268 4 条评论 3 个 reaction 已指派 0 人 在 GitHub 查看

还没有人认领这个 Issue。

主要语言
JavaScript
星标
560
派生
37
PR 合并指标
30 天内没有已合并 PR

描述

Motivation

Ref: https://github.com/aws/aws-lambda-nodejs-runtime-interface-client/issues/137

Callback handler syntax is being deprecated for the new Node 24 Lambda runtime and should be replaced with the async syntax.

I didn't see any open issues or PRs related to this, apologies if this is duplicative or if there is already an option to change this behavior under the hood. Otherwise, if nobody else is working on this I can give it a shot.

Example
exports.handler = (event, context, callback) => {
  // ... handler logic
  callback(null, { statusCode: 200, body: 'Success!' });
};

to:

export const handler = async (event, context) => {
  // ... handler logic
  return { statusCode: 200, body: 'Success!' };
};

贡献指南

打开贡献指南

从这里开始

  1. 先读完整个 Issue,再读项目的贡献指南。
  2. 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
  3. Fork 仓库,在一个分支上完成修改。
  4. 提交 Pull Request,并在描述里引用这个 Issue 编号。

调研方向

该 issue 未指出源文件、测试或入口点。首先定位 Lambda handler 在哪里被调用,以及如何检测或支持 callback 风格的 handler,然后检查 Node 24 runtime 的预期。完成的标准是,相关的 handler 路径使用 async 返回值而不依赖 callback 语法,并且覆盖文档中的示例。

由索引模型根据 Issue 内容生成。

评估

技术栈
aws, javascript, node.js
领域
backend, cloud
Issue 类型
重构
难度
4/5
预计耗时
3-5 天
活跃度
停滞
描述清晰度
基本清楚
新手友好度
38/100

把新 issue 发到你的邮箱

精选适合新手参与的 GitHub issue 摘要。