1
00:00:00,390 --> 00:00:07,500
In this video, we are going to see configurations of a lambda function with a management console.

2
00:00:07,920 --> 00:00:09,300
Let's get started.

3
00:00:09,900 --> 00:00:14,440
Now we are in here in the lambda function code and here is the code section.

4
00:00:14,460 --> 00:00:18,690
Now in this video we will see the configurations of lambda function.

5
00:00:18,780 --> 00:00:24,210
So please select this configuration top and open the configuration section.

6
00:00:24,900 --> 00:00:28,980
This is the lambda configuration section that we will see several options.

7
00:00:29,010 --> 00:00:32,280
Let's start with the general configuration you can see in here.

8
00:00:32,280 --> 00:00:35,640
If you click the first one, this is the general configuration.

9
00:00:36,610 --> 00:00:42,400
And in the general congregation we can see some of the congregations in here and there is an edit button.

10
00:00:42,430 --> 00:00:47,550
If you click the edit button, you can see that we can change these congregation basic settings.

11
00:00:47,560 --> 00:00:51,850
So what we have in these congregations, the first one is the memory.

12
00:00:51,880 --> 00:00:54,700
So basically we can configure memory settings in here.

13
00:00:54,700 --> 00:01:00,460
This is important because memory memory configuration led to provide concurrency capacity of lambda

14
00:01:00,460 --> 00:01:04,210
function so we can set to one gigabyte in here.

15
00:01:04,210 --> 00:01:10,450
You can see now this the 128 and we can increase the one gigabyte.

16
00:01:10,540 --> 00:01:16,390
This is important setting because this memory value will define concurrent capacity of lambda function.

17
00:01:17,080 --> 00:01:21,470
We can also configure function, timeout and also execution role.

18
00:01:21,610 --> 00:01:28,660
You can see in here we can set the increase the timeout in here, the timeout could be the maximum 15

19
00:01:28,660 --> 00:01:31,600
minutes and here you can see the execution load.

20
00:01:31,600 --> 00:01:35,110
We can change the execution role in the general settings.

21
00:01:35,110 --> 00:01:38,230
We can configure the execution role and other permissions.

22
00:01:38,410 --> 00:01:40,270
It is basically created by lambda.

23
00:01:40,270 --> 00:01:43,840
By default, it includes the cloud, which locks permissions.

24
00:01:44,710 --> 00:01:47,420
So these are the general and important settings.

25
00:01:47,470 --> 00:01:55,390
If you go back, let me click the cancel and go back to configuration and see this is the general configuration

26
00:01:55,390 --> 00:01:57,880
and we can see other configurations in here.

27
00:01:57,910 --> 00:02:04,540
If you go back and open the permissions, you can see here in the permissions, click the permissions

28
00:02:04,540 --> 00:02:05,890
and see the details.

29
00:02:06,370 --> 00:02:07,900
In the permissions section.

30
00:02:07,900 --> 00:02:10,210
We can find several sections.

31
00:02:10,210 --> 00:02:15,730
You can see that there is an execution load section and there's the source summary.

32
00:02:15,760 --> 00:02:19,690
And also, if you scroll down, you can see the resource based policy in here.

33
00:02:19,690 --> 00:02:23,710
So let's start with the first first one, which is the execution role.

34
00:02:23,740 --> 00:02:31,360
If you remember that Lambda execution role grants the permission to access services and resources by

35
00:02:31,360 --> 00:02:31,810
default.

36
00:02:31,810 --> 00:02:36,340
Lambda function needs to access to Amazon Cloud Watch logs for log streaming.

37
00:02:36,520 --> 00:02:42,070
So that means when you create any lambda function by default, it comes with the execution role, which

38
00:02:42,070 --> 00:02:43,030
includes Amazon Cloud.

39
00:02:43,210 --> 00:02:50,980
Look, you can click this button, open that, and you can verify that this execution role includes

40
00:02:51,250 --> 00:02:53,890
the Amazon cloud, which logs.

41
00:02:54,890 --> 00:02:56,350
So this is the IBM screen.

42
00:02:56,360 --> 00:03:03,710
If you scroll down and if you expand the policy, you can see that we have Grant create log group and

43
00:03:03,710 --> 00:03:10,190
create log stream and put log events actions to adding logs in the Amazon cloud logs.

44
00:03:10,190 --> 00:03:13,310
So this is create from the lambda.

45
00:03:13,340 --> 00:03:17,270
When we create the lambda function, the execution role is created at the same time.

46
00:03:17,420 --> 00:03:24,290
Okay, this was the execution role and the second permission configuration is resource based policy.

47
00:03:24,320 --> 00:03:29,720
If you scroll down, I would like to come here and would like to explain this.

48
00:03:29,720 --> 00:03:34,610
Your space policy is you remember that we have two permissions from the lambda function.

49
00:03:34,610 --> 00:03:40,040
The first one is execution role and the second one is the resource based policy.

50
00:03:40,310 --> 00:03:44,000
So let's remember what is the resource based policy?

51
00:03:44,150 --> 00:03:46,220
Basically a resource based policy.

52
00:03:46,220 --> 00:03:52,370
Let us to grant permission to other accounts or services on a per resource basis.

53
00:03:52,370 --> 00:03:59,060
So that means if we would like to give grant permission to invoke our lambda function from the other

54
00:03:59,720 --> 00:04:03,800
services, we should add permissions under the resource base policy.

55
00:04:03,830 --> 00:04:06,890
So now we don't have any policy for this function now.

56
00:04:07,040 --> 00:04:14,510
And because we are just creating this function and if you would like to add any grant, any services,

57
00:04:14,510 --> 00:04:16,280
we should click the add permission button.

58
00:04:16,430 --> 00:04:16,730
Okay.

59
00:04:16,820 --> 00:04:22,640
If you scroll up and see the resource summary, another important section is the resource summary.

60
00:04:23,390 --> 00:04:29,270
In the resource summary, we can leave the resources and actions that are function has permission to

61
00:04:29,270 --> 00:04:31,850
access in this place.

62
00:04:31,850 --> 00:04:38,210
So if you see this dropdown box, you can click this button and see that we have only one action, one

63
00:04:38,210 --> 00:04:40,940
resource permission, which is the Amazon Cloud Watch logs.

64
00:04:40,970 --> 00:04:42,950
This comes from the execution rule.

65
00:04:42,950 --> 00:04:48,860
So if we increase the execution roll permissions or adding some resource based policy, we should see

66
00:04:48,860 --> 00:04:49,880
this dropdown box.

67
00:04:49,880 --> 00:04:54,050
And you can see the filtering by resource and also by actions.

68
00:04:54,080 --> 00:04:59,330
Actions you can see that we only have Amazon Cloud, which logs actions and by resource you can see

69
00:04:59,330 --> 00:05:04,190
that we have only adding per giving permission from this resource.

70
00:05:04,670 --> 00:05:05,630
Okay, very good.

71
00:05:05,660 --> 00:05:10,850
If you go back to configurations, we can continue the other configurations.

72
00:05:10,850 --> 00:05:14,570
For example, I would like to open the environment variables.

73
00:05:15,390 --> 00:05:18,580
So please open the mind to this.

74
00:05:18,660 --> 00:05:23,150
We can set the key value pays for lambda function in the execution environment.

75
00:05:23,160 --> 00:05:27,780
So this is the best practice to use environment variables in order to manage our functions.

76
00:05:27,780 --> 00:05:29,820
Conversation outside of the code.

77
00:05:29,850 --> 00:05:34,830
So basically if you click the edit button, we can add environment as a key value paid in here.

78
00:05:34,860 --> 00:05:41,520
And this is important because we can add some of the environment variables in here and in code.

79
00:05:41,520 --> 00:05:47,280
We only use the environment variables and we can change the environment variables without touching.

80
00:05:47,280 --> 00:05:50,670
ENCODE Okay, this was the environment variables.

81
00:05:50,670 --> 00:05:54,990
Please come back to configurations and now I would like to open the text.

82
00:05:55,170 --> 00:05:58,620
There is a text configuration in the text section.

83
00:05:59,010 --> 00:06:03,930
We can set key value pairs that lambda attached to our function resources.

84
00:06:03,930 --> 00:06:09,990
We can use text to organize lambda functions into groups for cost reporting and filtering in the lambda

85
00:06:09,990 --> 00:06:10,590
console.

86
00:06:11,250 --> 00:06:13,560
So we have also another configurations.

87
00:06:13,560 --> 00:06:17,970
Let me open the VPC, which is the virtual private cloud.

88
00:06:18,660 --> 00:06:25,410
We can also configure virtual private cloud if we need to set network access to add resources in this

89
00:06:25,410 --> 00:06:31,080
window and also see another important configurations, which is the concurrency.

90
00:06:32,070 --> 00:06:35,010
You can see the concurrency configuration in this section.

91
00:06:35,340 --> 00:06:41,310
Resolve concurrency for a function to set the maximum number of the simultaneous execution for a function

92
00:06:41,640 --> 00:06:47,550
and provision concurrency to ensure that a function can scale without fluctuations in latency.

93
00:06:47,550 --> 00:06:52,290
So we can configure both reserve and provision concurrency in this window.

94
00:06:53,160 --> 00:06:58,520
And there is also another brand new configuration which is the function neural.

95
00:06:59,130 --> 00:07:01,050
This is the new feature of lambda function.

96
00:07:01,050 --> 00:07:06,810
We can configure a function URL to add a unique https and print to our lambda function.

97
00:07:06,810 --> 00:07:10,560
Basically it is exposing API without using the API gateway.

98
00:07:10,590 --> 00:07:14,610
You can think to expose single microservices to the external world.

99
00:07:14,970 --> 00:07:17,610
So there's lots of configuration you can see in here.

100
00:07:17,610 --> 00:07:24,600
For example, triggers destinations, asynchronous invocation, code signing, database proxies, file

101
00:07:24,600 --> 00:07:25,980
system, state machines.

102
00:07:26,430 --> 00:07:32,130
We will see all these settings when developing different use cases with lambda functions in the during

103
00:07:32,130 --> 00:07:32,520
the course.
