有谁能帮助我使用Python CDK代码部署Java Lambda的语法吗?下面是Iam用来部署python编写的Lambda的python CDK代码段
handler = lmb.Function(self, 'Handler',
runtime=lmb.Runtime.PYTHON_3_7,
handler='handler.handler',
code=lmb.Code.from_asset(path.join(this_dir, 'lambda')))
下面是我同事使用的Java CDK代码片段:
Function javafunc = new Function(this, CommonFunctions.getPropValues("HANDLER"),
FunctionProps.builder()
.runtime(Runtime.JAVA_8)
.handler(CommonFunctions.getPropValues("Java_LAMBDA"))
.code(Code.fromAsset(tmpBinDir + "/"+CommonFunctions.getPropValues("JAR_FILE_NAME")))
.timeout(Duration.seconds(300))
.memorySize(512)
.functionName(CommonFunctions.getPropValues("FUNCTION_NAME"))
.build());
我不懂Java,我需要使用Python CDK部署Java编译的Lambda jar
我们需要这些进口商品
code
:jar文件路径handler
:mainClassName::methodName相关问题 更多 >
编程相关推荐