我正在使用带有 AWS Lambda 和 API Gateway 的 Spring 云功能。
以下是我的功能:
@Bean
public Function<String, User> testFunction() {
return (input) -> {
return new User(1, input);
};
此外,我在 AWS Lambda 控制台中指定了如下处理程序:org.springframework.cloud.function.adapter.aws.FunctionInvoker::handleRequest
如果我发送一个带有字符串正文的请求,它就能够成功地收集输入。
但是我不明白,如何访问函数内部的请求查询参数?像这样:https://[apigateway].aws.com/[path]?param1=value
有人可以指导我吗?提前致谢。