简体   繁体   English

我可以使用一个S3存储桶上传不同的Java Lambda函数吗?

[英]Can I use one S3 bucket for upload different java lambda function?

Currently I am using different S3 bucket for every function. 目前,我为每个功能使用不同的S3 bucket

Ex. 例如 I have 3 Java Lambda Function created on Eclipse IDE . 我在Eclipse IDE上创建了3个Java Lambda函数

  1. RegisterUser 注册用户
  2. LoginUser 登录用户
  3. ResetPassword 重设密码

I am uploading lambda function through Eclipse IDE , 我正在通过Eclipse IDE上传lambda函数,

I have to upload function through Amazon S3 Bucket . 我必须通过Amazon S3 Bucket上传功能。

I create 3 Amazon S3 Bucket for upload all 3 function. 我创建了3个Amazon S3 Bucket用于上传所有3个功能。

My Question is : Can I upload all 3 Lambda Function using one Amazon S3 Bucket ? 我的问题是:我可以使用一个Amazon S3 Bucket上传所有3个Lambda函数吗?

or 要么

I have to create separate Amazon S3 Bucket for all function.? 我必须为所有功能创建单独的Amazon S3 Bucket

You don't need to upload to a bucket. 您无需上传到存储桶。 You can upload the function code via the command line as well. 您也可以通过命令行上传功能代码。 They only recommend not using the web interface for large Lambda functions, all other methods are ok, and command line is a very good option. 他们只建议不要对大型Lambda函数使用Web界面,其他所有方法都可以,命令行是一个很好的选择。

However, if you really want to upload to a bucket first, just give each zip file that contains the function code a different filename and you're good. 但是,如果您真的要首先上传到存储桶,只需为每个包含功能代码的zip文件指定一个不同的文件名,就可以了。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM