AWS Lambda Flashcards

1
Q

What triggers has lambda functions?

A
  • On a CloudWatch log group
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
2
Q

What re the lambda invocation models?

A
  • Synchronous (API GW calls)
  • Asynchronous (events calling)
  • Stream (Kinesis, Dynamo DB calling)
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
3
Q

What is the context object?

A

Provides methods and properties for runtime, this means property like memory, name fo function, version, ARN, mem limit, request ID

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
4
Q

I am in lambda, how cna I get the AWS request ID for tracing?

A

You can get the request-id from the context object.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
5
Q

What is the context logGroupName

A

Each lambda is part of a log group and also is using a logstream

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
6
Q

How cna I find out the time remaining for my lambda function?

A

You use the contect.getTimeRemainingMillis(). this gives you the time the lambda has remaining to execute code before AWS reclaims it.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
7
Q

How can I set the CPU size?

A

You dose not set CPU directly, CPU is proportional to the Memory, for example, if you have 128MB memory and you double it to 256, you get twice the CPU available ot the lambda function.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
8
Q

What is the event object?

A

The caller packed pup the event object with information thet cna be used in the lambda function.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
9
Q

What services can call lambda?

A

API GW (when a request is received)
S3 (When an object is received)
CloudWatch Events (When an event is received)
SNS (when a message is pushed into the topic)
Dynamo DB ‘When an item changes, you cna get the old and new’
CloudWatch edge events.
Kinesis
API GW auth

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
10
Q

What is the lambda execute role?

A

This is the role used by lambda to access other services and resources in aws.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
11
Q

What does lambda proxy do?

A

It forwards the entire request to the lambda, not just the body, what is expected in return is again the complete response.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly