Lambda - amresh087/newronaRepos GitHub Wiki

AWS Lambda is a serverless, event-driven compute service that lets you run code for virtually any type of application or backend service without provisioning or managing servers. You can trigger Lambda from over 200 AWS services and software as a service (SaaS) applications, and only pay for what you use.

Suppose we want create a Lambda function for s3. If any one upload file in s3 then it will process data in DynamoDB.

Now login aws console and search lambda on services

image

Now create new lammda

image

image

Then you will get succeed message

image

After creation of lamda we need to open lamda function then click on configuration tab

Now we need to check permission by click on permission section

image

Now you need to check role in IAM

search IAM on service

image

Now open it

Now you need to search your role like below

image

Now open you roles

image

After click on the attach policy then search the policy in search bar

image

image

Now, same like we need to give permission for cloud watch

image

Now we need to create table in dyanmodb. Then we need to search it on service

image

Now click on the table section. Then create table

image

Now we need to create s3 bucket THen we need to search s3 it on service

image

Now click on the create button

image

image

Now we need to add trigger in lamda fuction with event then you need to open lamda function after that click on the configuratiion

image

image

Now we need to go your lammdda fuction under code tab

image

Upload your jar files by import below code

https://github.com/amresh087/aws-lambda-s3-dynamodb-demo

Now we need to edit runtime setting

image

image

Now we need to upload data file in your s3 bucket

save below data in json file like employee.json

{ "empId": "1009", "name": "anish", "email": "[email protected]" }