line |
stmt |
bran |
cond |
sub |
pod |
time |
code |
1
|
|
|
|
|
|
|
|
2
|
|
|
|
|
|
|
package Paws::Lambda::CreateFunction; |
3
|
1
|
|
|
1
|
|
297
|
use Moose; |
|
1
|
|
|
1
|
|
4
|
|
|
1
|
|
|
|
|
7
|
|
|
1
|
|
|
|
|
560
|
|
|
1
|
|
|
|
|
3
|
|
|
1
|
|
|
|
|
7
|
|
4
|
|
|
|
|
|
|
has Code => (is => 'ro', isa => 'Paws::Lambda::FunctionCode', required => 1); |
5
|
|
|
|
|
|
|
has DeadLetterConfig => (is => 'ro', isa => 'Paws::Lambda::DeadLetterConfig'); |
6
|
|
|
|
|
|
|
has Description => (is => 'ro', isa => 'Str'); |
7
|
|
|
|
|
|
|
has Environment => (is => 'ro', isa => 'Paws::Lambda::Environment'); |
8
|
|
|
|
|
|
|
has FunctionName => (is => 'ro', isa => 'Str', required => 1); |
9
|
|
|
|
|
|
|
has Handler => (is => 'ro', isa => 'Str', required => 1); |
10
|
|
|
|
|
|
|
has KMSKeyArn => (is => 'ro', isa => 'Str'); |
11
|
|
|
|
|
|
|
has MemorySize => (is => 'ro', isa => 'Int'); |
12
|
|
|
|
|
|
|
has Publish => (is => 'ro', isa => 'Bool'); |
13
|
|
|
|
|
|
|
has Role => (is => 'ro', isa => 'Str', required => 1); |
14
|
|
|
|
|
|
|
has Runtime => (is => 'ro', isa => 'Str', required => 1); |
15
|
|
|
|
|
|
|
has Tags => (is => 'ro', isa => 'Paws::Lambda::Tags'); |
16
|
|
|
|
|
|
|
has Timeout => (is => 'ro', isa => 'Int'); |
17
|
|
|
|
|
|
|
has TracingConfig => (is => 'ro', isa => 'Paws::Lambda::TracingConfig'); |
18
|
|
|
|
|
|
|
has VpcConfig => (is => 'ro', isa => 'Paws::Lambda::VpcConfig'); |
19
|
|
|
|
|
|
|
|
20
|
1
|
|
|
1
|
|
5457
|
use MooseX::ClassAttribute; |
|
1
|
|
|
1
|
|
3
|
|
|
1
|
|
|
|
|
8
|
|
|
1
|
|
|
|
|
6136
|
|
|
1
|
|
|
|
|
2
|
|
|
1
|
|
|
|
|
9
|
|
21
|
|
|
|
|
|
|
|
22
|
|
|
|
|
|
|
class_has _api_call => (isa => 'Str', is => 'ro', default => 'CreateFunction'); |
23
|
|
|
|
|
|
|
class_has _api_uri => (isa => 'Str', is => 'ro', default => '/2015-03-31/functions'); |
24
|
|
|
|
|
|
|
class_has _api_method => (isa => 'Str', is => 'ro', default => 'POST'); |
25
|
|
|
|
|
|
|
class_has _returns => (isa => 'Str', is => 'ro', default => 'Paws::Lambda::FunctionConfiguration'); |
26
|
|
|
|
|
|
|
class_has _result_key => (isa => 'Str', is => 'ro'); |
27
|
|
|
|
|
|
|
1; |
28
|
|
|
|
|
|
|
|
29
|
|
|
|
|
|
|
### main pod documentation begin ### |
30
|
|
|
|
|
|
|
|
31
|
|
|
|
|
|
|
=head1 NAME |
32
|
|
|
|
|
|
|
|
33
|
|
|
|
|
|
|
Paws::Lambda::CreateFunction - Arguments for method CreateFunction on Paws::Lambda |
34
|
|
|
|
|
|
|
|
35
|
|
|
|
|
|
|
=head1 DESCRIPTION |
36
|
|
|
|
|
|
|
|
37
|
|
|
|
|
|
|
This class represents the parameters used for calling the method CreateFunction on the |
38
|
|
|
|
|
|
|
AWS Lambda service. Use the attributes of this class |
39
|
|
|
|
|
|
|
as arguments to method CreateFunction. |
40
|
|
|
|
|
|
|
|
41
|
|
|
|
|
|
|
You shouldn't make instances of this class. Each attribute should be used as a named argument in the call to CreateFunction. |
42
|
|
|
|
|
|
|
|
43
|
|
|
|
|
|
|
As an example: |
44
|
|
|
|
|
|
|
|
45
|
|
|
|
|
|
|
$service_obj->CreateFunction(Att1 => $value1, Att2 => $value2, ...); |
46
|
|
|
|
|
|
|
|
47
|
|
|
|
|
|
|
Values for attributes that are native types (Int, String, Float, etc) can passed as-is (scalar values). Values for complex Types (objects) can be passed as a HashRef. The keys and values of the hashref will be used to instance the underlying object. |
48
|
|
|
|
|
|
|
|
49
|
|
|
|
|
|
|
=head1 ATTRIBUTES |
50
|
|
|
|
|
|
|
|
51
|
|
|
|
|
|
|
|
52
|
|
|
|
|
|
|
=head2 B<REQUIRED> Code => L<Paws::Lambda::FunctionCode> |
53
|
|
|
|
|
|
|
|
54
|
|
|
|
|
|
|
The code for the Lambda function. |
55
|
|
|
|
|
|
|
|
56
|
|
|
|
|
|
|
|
57
|
|
|
|
|
|
|
|
58
|
|
|
|
|
|
|
=head2 DeadLetterConfig => L<Paws::Lambda::DeadLetterConfig> |
59
|
|
|
|
|
|
|
|
60
|
|
|
|
|
|
|
The parent object that contains the target ARN (Amazon Resource Name) |
61
|
|
|
|
|
|
|
of an Amazon SQS queue or Amazon SNS topic. |
62
|
|
|
|
|
|
|
|
63
|
|
|
|
|
|
|
|
64
|
|
|
|
|
|
|
|
65
|
|
|
|
|
|
|
=head2 Description => Str |
66
|
|
|
|
|
|
|
|
67
|
|
|
|
|
|
|
A short, user-defined function description. Lambda does not use this |
68
|
|
|
|
|
|
|
value. Assign a meaningful description as you see fit. |
69
|
|
|
|
|
|
|
|
70
|
|
|
|
|
|
|
|
71
|
|
|
|
|
|
|
|
72
|
|
|
|
|
|
|
=head2 Environment => L<Paws::Lambda::Environment> |
73
|
|
|
|
|
|
|
|
74
|
|
|
|
|
|
|
|
75
|
|
|
|
|
|
|
|
76
|
|
|
|
|
|
|
|
77
|
|
|
|
|
|
|
|
78
|
|
|
|
|
|
|
=head2 B<REQUIRED> FunctionName => Str |
79
|
|
|
|
|
|
|
|
80
|
|
|
|
|
|
|
The name you want to assign to the function you are uploading. The |
81
|
|
|
|
|
|
|
function names appear in the console and are returned in the |
82
|
|
|
|
|
|
|
ListFunctions API. Function names are used to specify functions to |
83
|
|
|
|
|
|
|
other AWS Lambda API operations, such as Invoke. Note that the length |
84
|
|
|
|
|
|
|
constraint applies only to the ARN. If you specify only the function |
85
|
|
|
|
|
|
|
name, it is limited to 64 characters in length. |
86
|
|
|
|
|
|
|
|
87
|
|
|
|
|
|
|
|
88
|
|
|
|
|
|
|
|
89
|
|
|
|
|
|
|
=head2 B<REQUIRED> Handler => Str |
90
|
|
|
|
|
|
|
|
91
|
|
|
|
|
|
|
The function within your code that Lambda calls to begin execution. For |
92
|
|
|
|
|
|
|
Node.js, it is the I<module-name>.I<export> value in your function. For |
93
|
|
|
|
|
|
|
Java, it can be C<package.class-name::handler> or |
94
|
|
|
|
|
|
|
C<package.class-name>. For more information, see Lambda Function |
95
|
|
|
|
|
|
|
Handler (Java). |
96
|
|
|
|
|
|
|
|
97
|
|
|
|
|
|
|
|
98
|
|
|
|
|
|
|
|
99
|
|
|
|
|
|
|
=head2 KMSKeyArn => Str |
100
|
|
|
|
|
|
|
|
101
|
|
|
|
|
|
|
The Amazon Resource Name (ARN) of the KMS key used to encrypt your |
102
|
|
|
|
|
|
|
function's environment variables. If not provided, AWS Lambda will use |
103
|
|
|
|
|
|
|
a default service key. |
104
|
|
|
|
|
|
|
|
105
|
|
|
|
|
|
|
|
106
|
|
|
|
|
|
|
|
107
|
|
|
|
|
|
|
=head2 MemorySize => Int |
108
|
|
|
|
|
|
|
|
109
|
|
|
|
|
|
|
The amount of memory, in MB, your Lambda function is given. Lambda uses |
110
|
|
|
|
|
|
|
this memory size to infer the amount of CPU and memory allocated to |
111
|
|
|
|
|
|
|
your function. Your function use-case determines your CPU and memory |
112
|
|
|
|
|
|
|
requirements. For example, a database operation might need less memory |
113
|
|
|
|
|
|
|
compared to an image processing function. The default value is 128 MB. |
114
|
|
|
|
|
|
|
The value must be a multiple of 64 MB. |
115
|
|
|
|
|
|
|
|
116
|
|
|
|
|
|
|
|
117
|
|
|
|
|
|
|
|
118
|
|
|
|
|
|
|
=head2 Publish => Bool |
119
|
|
|
|
|
|
|
|
120
|
|
|
|
|
|
|
This boolean parameter can be used to request AWS Lambda to create the |
121
|
|
|
|
|
|
|
Lambda function and publish a version as an atomic operation. |
122
|
|
|
|
|
|
|
|
123
|
|
|
|
|
|
|
|
124
|
|
|
|
|
|
|
|
125
|
|
|
|
|
|
|
=head2 B<REQUIRED> Role => Str |
126
|
|
|
|
|
|
|
|
127
|
|
|
|
|
|
|
The Amazon Resource Name (ARN) of the IAM role that Lambda assumes when |
128
|
|
|
|
|
|
|
it executes your function to access any other Amazon Web Services (AWS) |
129
|
|
|
|
|
|
|
resources. For more information, see AWS Lambda: How it Works. |
130
|
|
|
|
|
|
|
|
131
|
|
|
|
|
|
|
|
132
|
|
|
|
|
|
|
|
133
|
|
|
|
|
|
|
=head2 B<REQUIRED> Runtime => Str |
134
|
|
|
|
|
|
|
|
135
|
|
|
|
|
|
|
The runtime environment for the Lambda function you are uploading. |
136
|
|
|
|
|
|
|
|
137
|
|
|
|
|
|
|
To use the Python runtime v3.6, set the value to "python3.6". To use |
138
|
|
|
|
|
|
|
the Python runtime v2.7, set the value to "python2.7". To use the |
139
|
|
|
|
|
|
|
Node.js runtime v6.10, set the value to "nodejs6.10". To use the |
140
|
|
|
|
|
|
|
Node.js runtime v4.3, set the value to "nodejs4.3". |
141
|
|
|
|
|
|
|
|
142
|
|
|
|
|
|
|
Node v0.10.42 is currently marked as deprecated. You must migrate |
143
|
|
|
|
|
|
|
existing functions to the newer Node.js runtime versions available on |
144
|
|
|
|
|
|
|
AWS Lambda (nodejs4.3 or nodejs6.10) as soon as possible. You can |
145
|
|
|
|
|
|
|
request a one-time extension until June 30, 2017 by going to the Lambda |
146
|
|
|
|
|
|
|
console and following the instructions provided. Failure to do so will |
147
|
|
|
|
|
|
|
result in an invalid parmaeter error being returned. Note that you will |
148
|
|
|
|
|
|
|
have to follow this procedure for each region that contains functions |
149
|
|
|
|
|
|
|
written in the Node v0.10.42 runtime. |
150
|
|
|
|
|
|
|
|
151
|
|
|
|
|
|
|
Valid values are: C<"nodejs">, C<"nodejs4.3">, C<"nodejs6.10">, C<"java8">, C<"python2.7">, C<"python3.6">, C<"dotnetcore1.0">, C<"nodejs4.3-edge"> |
152
|
|
|
|
|
|
|
|
153
|
|
|
|
|
|
|
=head2 Tags => L<Paws::Lambda::Tags> |
154
|
|
|
|
|
|
|
|
155
|
|
|
|
|
|
|
The list of tags (key-value pairs) assigned to the new function. |
156
|
|
|
|
|
|
|
|
157
|
|
|
|
|
|
|
|
158
|
|
|
|
|
|
|
|
159
|
|
|
|
|
|
|
=head2 Timeout => Int |
160
|
|
|
|
|
|
|
|
161
|
|
|
|
|
|
|
The function execution time at which Lambda should terminate the |
162
|
|
|
|
|
|
|
function. Because the execution time has cost implications, we |
163
|
|
|
|
|
|
|
recommend you set this value based on your expected execution time. The |
164
|
|
|
|
|
|
|
default is 3 seconds. |
165
|
|
|
|
|
|
|
|
166
|
|
|
|
|
|
|
|
167
|
|
|
|
|
|
|
|
168
|
|
|
|
|
|
|
=head2 TracingConfig => L<Paws::Lambda::TracingConfig> |
169
|
|
|
|
|
|
|
|
170
|
|
|
|
|
|
|
The parent object that contains your function's tracing settings. |
171
|
|
|
|
|
|
|
|
172
|
|
|
|
|
|
|
|
173
|
|
|
|
|
|
|
|
174
|
|
|
|
|
|
|
=head2 VpcConfig => L<Paws::Lambda::VpcConfig> |
175
|
|
|
|
|
|
|
|
176
|
|
|
|
|
|
|
If your Lambda function accesses resources in a VPC, you provide this |
177
|
|
|
|
|
|
|
parameter identifying the list of security group IDs and subnet IDs. |
178
|
|
|
|
|
|
|
These must belong to the same VPC. You must provide at least one |
179
|
|
|
|
|
|
|
security group and one subnet ID. |
180
|
|
|
|
|
|
|
|
181
|
|
|
|
|
|
|
|
182
|
|
|
|
|
|
|
|
183
|
|
|
|
|
|
|
|
184
|
|
|
|
|
|
|
=head1 SEE ALSO |
185
|
|
|
|
|
|
|
|
186
|
|
|
|
|
|
|
This class forms part of L<Paws>, documenting arguments for method CreateFunction in L<Paws::Lambda> |
187
|
|
|
|
|
|
|
|
188
|
|
|
|
|
|
|
=head1 BUGS and CONTRIBUTIONS |
189
|
|
|
|
|
|
|
|
190
|
|
|
|
|
|
|
The source code is located here: https://github.com/pplu/aws-sdk-perl |
191
|
|
|
|
|
|
|
|
192
|
|
|
|
|
|
|
Please report bugs to: https://github.com/pplu/aws-sdk-perl/issues |
193
|
|
|
|
|
|
|
|
194
|
|
|
|
|
|
|
=cut |
195
|
|
|
|
|
|
|
|