Reputation: 4483
I am working on a Lambda project in Java. Actually, I have already packaged it as a jar. As part of the deployment, I would like to upload this jar to s3 bucket.
While setting up the lambda function, I would like to specify the s3 key of the uploaded jar. I have seen quite a few examples over the internet. But most of them talk about either Js or Python. A few of the articles are there also related to Java but do not specify concretely how to do this.
Could anyone please help here? Thanks.
EDIT
I am using Terraform to create my lambda function, where I have to pass the s3 bucket along with the s3 key of the uploaded Lambda jar.
Upvotes: 0
Views: 410
Reputation: 10704
There are various articles that show you how to use the Java Lambda runtime API to build Lambda functions that perform various use cases. These are in the Java V2 Github repo:
3- Creating scheduled events to invoke Lambda functions
All of these examples provide you with step by step instructions and show you how to build Lambda functions using the Lambda Java runtime API that interact with other AWS Services. For example, the 1st one shows you how to build a Lambda function that can automatically tag images in an Amazon S3 bucket.
Upvotes: 2