aws-sdk-lambda 1.38.0 → 1.39.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +5 -5
- data/lib/aws-sdk-lambda.rb +1 -1
- data/lib/aws-sdk-lambda/client.rb +963 -200
- metadata +3 -3
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
|
-
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
2
|
+
SHA256:
|
3
|
+
metadata.gz: c1452fdce3dc72b05460b7537f8c8d4aeb0a0c44eb1ed762759a6a1348ac4b0c
|
4
|
+
data.tar.gz: 2941c79e410a80689f20abc733214102b37fedaa87a04642f39e50a6160ab0ad
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 50c48a2d83d1af74885800006a70641efad8052299700c4f7f24fd280631862c6a151d988f2c83b674aa6645576d279a1f6f2ac3540f1edf1e6bb9f865949444
|
7
|
+
data.tar.gz: f06046de395a7bde4f654311c7cc365be806cc984e212ebc9aeccd99c145963acce5dafe65f970a063005352493c54b0924e562cdbdfb14c51e2f7ccfc009151
|
data/lib/aws-sdk-lambda.rb
CHANGED
@@ -351,6 +351,25 @@ module Aws::Lambda
|
|
351
351
|
# * {Types::AddLayerVersionPermissionResponse#statement #statement} => String
|
352
352
|
# * {Types::AddLayerVersionPermissionResponse#revision_id #revision_id} => String
|
353
353
|
#
|
354
|
+
#
|
355
|
+
# @example Example: To add permissions to a layer version
|
356
|
+
#
|
357
|
+
# # The following example grants permission for the account 223456789012 to use version 1 of a layer named my-layer.
|
358
|
+
#
|
359
|
+
# resp = client.add_layer_version_permission({
|
360
|
+
# action: "lambda:GetLayerVersion",
|
361
|
+
# layer_name: "my-layer",
|
362
|
+
# principal: "223456789012",
|
363
|
+
# statement_id: "xaccount",
|
364
|
+
# version_number: 1,
|
365
|
+
# })
|
366
|
+
#
|
367
|
+
# resp.to_h outputs the following:
|
368
|
+
# {
|
369
|
+
# revision_id: "35d87451-f796-4a3f-a618-95a3671b0a0c",
|
370
|
+
# statement: "{\"Sid\":\"xaccount\",\"Effect\":\"Allow\",\"Principal\":{\"AWS\":\"arn:aws:iam::223456789012:root\"},\"Action\":\"lambda:GetLayerVersion\",\"Resource\":\"arn:aws:lambda:us-east-2:123456789012:layer:my-layer:1\"}",
|
371
|
+
# }
|
372
|
+
#
|
354
373
|
# @example Request syntax with placeholder values
|
355
374
|
#
|
356
375
|
# resp = client.add_layer_version_permission({
|
@@ -458,22 +477,39 @@ module Aws::Lambda
|
|
458
477
|
# * {Types::AddPermissionResponse#statement #statement} => String
|
459
478
|
#
|
460
479
|
#
|
461
|
-
# @example Example:
|
480
|
+
# @example Example: To grant Amazon S3 permission to invoke a function
|
462
481
|
#
|
463
|
-
# #
|
482
|
+
# # The following example adds permission for Amazon S3 to invoke a Lambda function named my-function for notifications from
|
483
|
+
# # a bucket named my-bucket-1xpuxmplzrlbh in account 123456789012.
|
464
484
|
#
|
465
485
|
# resp = client.add_permission({
|
466
486
|
# action: "lambda:InvokeFunction",
|
467
|
-
# function_name: "
|
487
|
+
# function_name: "my-function",
|
468
488
|
# principal: "s3.amazonaws.com",
|
469
489
|
# source_account: "123456789012",
|
470
|
-
# source_arn: "arn:aws:s3:::
|
471
|
-
# statement_id: "
|
490
|
+
# source_arn: "arn:aws:s3:::my-bucket-1xpuxmplzrlbh/*",
|
491
|
+
# statement_id: "s3",
|
472
492
|
# })
|
473
493
|
#
|
474
494
|
# resp.to_h outputs the following:
|
475
495
|
# {
|
476
|
-
# statement: "
|
496
|
+
# statement: "{\"Sid\":\"s3\",\"Effect\":\"Allow\",\"Principal\":{\"Service\":\"s3.amazonaws.com\"},\"Action\":\"lambda:InvokeFunction\",\"Resource\":\"arn:aws:lambda:us-east-2:123456789012:function:my-function\",\"Condition\":{\"StringEquals\":{\"AWS:SourceAccount\":\"123456789012\"},\"ArnLike\":{\"AWS:SourceArn\":\"arn:aws:s3:::my-bucket-1xpuxmplzrlbh\"}}}",
|
497
|
+
# }
|
498
|
+
#
|
499
|
+
# @example Example: To grant another account permission to invoke a function
|
500
|
+
#
|
501
|
+
# # The following example adds permission for account 223456789012 invoke a Lambda function named my-function.
|
502
|
+
#
|
503
|
+
# resp = client.add_permission({
|
504
|
+
# action: "lambda:InvokeFunction",
|
505
|
+
# function_name: "my-function",
|
506
|
+
# principal: "223456789012",
|
507
|
+
# statement_id: "xaccount",
|
508
|
+
# })
|
509
|
+
#
|
510
|
+
# resp.to_h outputs the following:
|
511
|
+
# {
|
512
|
+
# statement: "{\"Sid\":\"xaccount\",\"Effect\":\"Allow\",\"Principal\":{\"AWS\":\"arn:aws:iam::223456789012:root\"},\"Action\":\"lambda:InvokeFunction\",\"Resource\":\"arn:aws:lambda:us-east-2:123456789012:function:my-function\"}",
|
477
513
|
# }
|
478
514
|
#
|
479
515
|
# @example Request syntax with placeholder values
|
@@ -555,6 +591,27 @@ module Aws::Lambda
|
|
555
591
|
# * {Types::AliasConfiguration#routing_config #routing_config} => Types::AliasRoutingConfiguration
|
556
592
|
# * {Types::AliasConfiguration#revision_id #revision_id} => String
|
557
593
|
#
|
594
|
+
#
|
595
|
+
# @example Example: To create an alias for a Lambda function
|
596
|
+
#
|
597
|
+
# # The following example creates an alias named LIVE that points to version 1 of the my-function Lambda function.
|
598
|
+
#
|
599
|
+
# resp = client.create_alias({
|
600
|
+
# description: "alias for live version of function",
|
601
|
+
# function_name: "my-function",
|
602
|
+
# function_version: "1",
|
603
|
+
# name: "LIVE",
|
604
|
+
# })
|
605
|
+
#
|
606
|
+
# resp.to_h outputs the following:
|
607
|
+
# {
|
608
|
+
# alias_arn: "arn:aws:lambda:us-east-2:123456789012:function:my-function:LIVE",
|
609
|
+
# description: "alias for live version of function",
|
610
|
+
# function_version: "1",
|
611
|
+
# name: "LIVE",
|
612
|
+
# revision_id: "873282ed-xmpl-4dc8-a069-d0c647e470c6",
|
613
|
+
# }
|
614
|
+
#
|
558
615
|
# @example Request syntax with placeholder values
|
559
616
|
#
|
560
617
|
# resp = client.create_alias({
|
@@ -713,6 +770,28 @@ module Aws::Lambda
|
|
713
770
|
# * {Types::EventSourceMappingConfiguration#bisect_batch_on_function_error #bisect_batch_on_function_error} => Boolean
|
714
771
|
# * {Types::EventSourceMappingConfiguration#maximum_retry_attempts #maximum_retry_attempts} => Integer
|
715
772
|
#
|
773
|
+
#
|
774
|
+
# @example Example: To create a mapping between an event source and an AWS Lambda function
|
775
|
+
#
|
776
|
+
# # The following example creates a mapping between an SQS queue and the my-function Lambda function.
|
777
|
+
#
|
778
|
+
# resp = client.create_event_source_mapping({
|
779
|
+
# batch_size: 5,
|
780
|
+
# event_source_arn: "arn:aws:sqs:us-west-2:123456789012:my-queue",
|
781
|
+
# function_name: "my-function",
|
782
|
+
# })
|
783
|
+
#
|
784
|
+
# resp.to_h outputs the following:
|
785
|
+
# {
|
786
|
+
# batch_size: 5,
|
787
|
+
# event_source_arn: "arn:aws:sqs:us-west-2:123456789012:my-queue",
|
788
|
+
# function_arn: "arn:aws:lambda:us-west-2:123456789012:function:my-function",
|
789
|
+
# last_modified: Time.parse(1569284520.333),
|
790
|
+
# state: "Creating",
|
791
|
+
# state_transition_reason: "USER_INITIATED",
|
792
|
+
# uuid: "a1b2c3d4-5678-90ab-cdef-11111EXAMPLE",
|
793
|
+
# }
|
794
|
+
#
|
716
795
|
# @example Request syntax with placeholder values
|
717
796
|
#
|
718
797
|
# resp = client.create_event_source_mapping({
|
@@ -942,41 +1021,66 @@ module Aws::Lambda
|
|
942
1021
|
# * {Types::FunctionConfiguration#last_update_status_reason_code #last_update_status_reason_code} => String
|
943
1022
|
#
|
944
1023
|
#
|
945
|
-
# @example Example:
|
1024
|
+
# @example Example: To update an asynchronous invocation configuration
|
946
1025
|
#
|
947
|
-
# #
|
1026
|
+
# # The following example creates a function with a deployment package in Amazon S3 and enables X-Ray tracing and
|
1027
|
+
# # environment variable encryption.
|
948
1028
|
#
|
949
1029
|
# resp = client.create_function({
|
950
1030
|
# code: {
|
1031
|
+
# s3_bucket: "my-bucket-1xpuxmplzrlbh",
|
1032
|
+
# s3_key: "function.zip",
|
951
1033
|
# },
|
952
|
-
# description: "",
|
953
|
-
#
|
954
|
-
#
|
955
|
-
#
|
1034
|
+
# description: "Process image objects from Amazon S3.",
|
1035
|
+
# environment: {
|
1036
|
+
# variables: {
|
1037
|
+
# "BUCKET" => "my-bucket-1xpuxmplzrlbh",
|
1038
|
+
# "PREFIX" => "inbound",
|
1039
|
+
# },
|
1040
|
+
# },
|
1041
|
+
# function_name: "my-function",
|
1042
|
+
# handler: "index.handler",
|
1043
|
+
# kms_key_arn: "arn:aws:kms:us-west-2:123456789012:key/b0844d6c-xmpl-4463-97a4-d49f50839966",
|
1044
|
+
# memory_size: 256,
|
956
1045
|
# publish: true,
|
957
|
-
# role: "arn:aws:iam::123456789012:role/
|
1046
|
+
# role: "arn:aws:iam::123456789012:role/lambda-role",
|
958
1047
|
# runtime: "nodejs12.x",
|
1048
|
+
# tags: {
|
1049
|
+
# "DEPARTMENT" => "Assets",
|
1050
|
+
# },
|
959
1051
|
# timeout: 15,
|
960
|
-
#
|
1052
|
+
# tracing_config: {
|
1053
|
+
# mode: "Active",
|
961
1054
|
# },
|
962
1055
|
# })
|
963
1056
|
#
|
964
1057
|
# resp.to_h outputs the following:
|
965
1058
|
# {
|
966
|
-
# code_sha_256: "",
|
967
|
-
# code_size:
|
968
|
-
# description: "",
|
969
|
-
#
|
970
|
-
#
|
971
|
-
#
|
972
|
-
#
|
973
|
-
#
|
974
|
-
#
|
1059
|
+
# code_sha_256: "YFgDgEKG3ugvF1+pX64gV6tu9qNuIYNUdgJm8nCxsm4=",
|
1060
|
+
# code_size: 5797206,
|
1061
|
+
# description: "Process image objects from Amazon S3.",
|
1062
|
+
# environment: {
|
1063
|
+
# variables: {
|
1064
|
+
# "BUCKET" => "my-bucket-1xpuxmplzrlbh",
|
1065
|
+
# "PREFIX" => "inbound",
|
1066
|
+
# },
|
1067
|
+
# },
|
1068
|
+
# function_arn: "arn:aws:lambda:us-west-2:123456789012:function:my-function",
|
1069
|
+
# function_name: "my-function",
|
1070
|
+
# handler: "index.handler",
|
1071
|
+
# kms_key_arn: "arn:aws:kms:us-west-2:123456789012:key/b0844d6c-xmpl-4463-97a4-d49f50839966",
|
1072
|
+
# last_modified: Time.parse("2020-04-10T19:06:32.563+0000"),
|
1073
|
+
# last_update_status: "Successful",
|
1074
|
+
# memory_size: 256,
|
1075
|
+
# revision_id: "b75dcd81-xmpl-48a8-a75a-93ba8b5b9727",
|
1076
|
+
# role: "arn:aws:iam::123456789012:role/lambda-role",
|
975
1077
|
# runtime: "nodejs12.x",
|
976
|
-
#
|
977
|
-
#
|
978
|
-
#
|
1078
|
+
# state: "Active",
|
1079
|
+
# timeout: 15,
|
1080
|
+
# tracing_config: {
|
1081
|
+
# mode: "Active",
|
979
1082
|
# },
|
1083
|
+
# version: "1",
|
980
1084
|
# }
|
981
1085
|
#
|
982
1086
|
# @example Request syntax with placeholder values
|
@@ -1094,11 +1198,11 @@ module Aws::Lambda
|
|
1094
1198
|
#
|
1095
1199
|
# @example Example: To delete a Lambda function alias
|
1096
1200
|
#
|
1097
|
-
# #
|
1201
|
+
# # The following example deletes an alias named BLUE from a function named my-function
|
1098
1202
|
#
|
1099
1203
|
# resp = client.delete_alias({
|
1100
|
-
# function_name: "
|
1101
|
-
# name: "
|
1204
|
+
# function_name: "my-function",
|
1205
|
+
# name: "BLUE",
|
1102
1206
|
# })
|
1103
1207
|
#
|
1104
1208
|
# @example Request syntax with placeholder values
|
@@ -1150,22 +1254,21 @@ module Aws::Lambda
|
|
1150
1254
|
#
|
1151
1255
|
# @example Example: To delete a Lambda function event source mapping
|
1152
1256
|
#
|
1153
|
-
# #
|
1257
|
+
# # The following example deletes an event source mapping. To get a mapping's UUID, use ListEventSourceMappings.
|
1154
1258
|
#
|
1155
1259
|
# resp = client.delete_event_source_mapping({
|
1156
|
-
# uuid: "
|
1260
|
+
# uuid: "14e0db71-xmpl-4eb5-b481-8945cf9d10c2",
|
1157
1261
|
# })
|
1158
1262
|
#
|
1159
1263
|
# resp.to_h outputs the following:
|
1160
1264
|
# {
|
1161
|
-
# batch_size:
|
1162
|
-
# event_source_arn: "arn:aws:
|
1163
|
-
# function_arn: "arn:aws:lambda:us-
|
1164
|
-
# last_modified: Time.parse("
|
1165
|
-
#
|
1166
|
-
#
|
1167
|
-
#
|
1168
|
-
# uuid: "12345kxodurf3443",
|
1265
|
+
# batch_size: 5,
|
1266
|
+
# event_source_arn: "arn:aws:sqs:us-west-2:123456789012:my-queue",
|
1267
|
+
# function_arn: "arn:aws:lambda:us-east-2:123456789012:function:my-function",
|
1268
|
+
# last_modified: Time.parse("${timestamp}"),
|
1269
|
+
# state: "Enabled",
|
1270
|
+
# state_transition_reason: "USER_INITIATED",
|
1271
|
+
# uuid: "14e0db71-xmpl-4eb5-b481-8945cf9d10c2",
|
1169
1272
|
# }
|
1170
1273
|
#
|
1171
1274
|
# @example Request syntax with placeholder values
|
@@ -1234,12 +1337,12 @@ module Aws::Lambda
|
|
1234
1337
|
# @return [Struct] Returns an empty {Seahorse::Client::Response response}.
|
1235
1338
|
#
|
1236
1339
|
#
|
1237
|
-
# @example Example: To delete a Lambda function
|
1340
|
+
# @example Example: To delete a version of a Lambda function
|
1238
1341
|
#
|
1239
|
-
# #
|
1342
|
+
# # The following example deletes version 1 of a Lambda function named my-function.
|
1240
1343
|
#
|
1241
1344
|
# resp = client.delete_function({
|
1242
|
-
# function_name: "
|
1345
|
+
# function_name: "my-function",
|
1243
1346
|
# qualifier: "1",
|
1244
1347
|
# })
|
1245
1348
|
#
|
@@ -1278,6 +1381,15 @@ module Aws::Lambda
|
|
1278
1381
|
#
|
1279
1382
|
# @return [Struct] Returns an empty {Seahorse::Client::Response response}.
|
1280
1383
|
#
|
1384
|
+
#
|
1385
|
+
# @example Example: To remove the reserved concurrent execution limit from a function
|
1386
|
+
#
|
1387
|
+
# # The following example deletes the reserved concurrent execution limit from a function named my-function.
|
1388
|
+
#
|
1389
|
+
# resp = client.delete_function_concurrency({
|
1390
|
+
# function_name: "my-function",
|
1391
|
+
# })
|
1392
|
+
#
|
1281
1393
|
# @example Request syntax with placeholder values
|
1282
1394
|
#
|
1283
1395
|
# resp = client.delete_function_concurrency({
|
@@ -1321,6 +1433,17 @@ module Aws::Lambda
|
|
1321
1433
|
#
|
1322
1434
|
# @return [Struct] Returns an empty {Seahorse::Client::Response response}.
|
1323
1435
|
#
|
1436
|
+
#
|
1437
|
+
# @example Example: To delete an asynchronous invocation configuration
|
1438
|
+
#
|
1439
|
+
# # The following example deletes the asynchronous invocation configuration for the GREEN alias of a function named
|
1440
|
+
# # my-function.
|
1441
|
+
#
|
1442
|
+
# resp = client.delete_function_event_invoke_config({
|
1443
|
+
# function_name: "my-function",
|
1444
|
+
# qualifier: "GREEN",
|
1445
|
+
# })
|
1446
|
+
#
|
1324
1447
|
# @example Request syntax with placeholder values
|
1325
1448
|
#
|
1326
1449
|
# resp = client.delete_function_event_invoke_config({
|
@@ -1353,6 +1476,16 @@ module Aws::Lambda
|
|
1353
1476
|
#
|
1354
1477
|
# @return [Struct] Returns an empty {Seahorse::Client::Response response}.
|
1355
1478
|
#
|
1479
|
+
#
|
1480
|
+
# @example Example: To delete a version of a Lambda layer
|
1481
|
+
#
|
1482
|
+
# # The following example deletes version 2 of a layer named my-layer.
|
1483
|
+
#
|
1484
|
+
# resp = client.delete_layer_version({
|
1485
|
+
# layer_name: "my-layer",
|
1486
|
+
# version_number: 2,
|
1487
|
+
# })
|
1488
|
+
#
|
1356
1489
|
# @example Request syntax with placeholder values
|
1357
1490
|
#
|
1358
1491
|
# resp = client.delete_layer_version({
|
@@ -1391,6 +1524,17 @@ module Aws::Lambda
|
|
1391
1524
|
#
|
1392
1525
|
# @return [Struct] Returns an empty {Seahorse::Client::Response response}.
|
1393
1526
|
#
|
1527
|
+
#
|
1528
|
+
# @example Example: To delete a provisioned concurrency configuration
|
1529
|
+
#
|
1530
|
+
# # The following example deletes the provisioned concurrency configuration for the GREEN alias of a function named
|
1531
|
+
# # my-function.
|
1532
|
+
#
|
1533
|
+
# resp = client.delete_provisioned_concurrency_config({
|
1534
|
+
# function_name: "my-function",
|
1535
|
+
# qualifier: "GREEN",
|
1536
|
+
# })
|
1537
|
+
#
|
1394
1538
|
# @example Request syntax with placeholder values
|
1395
1539
|
#
|
1396
1540
|
# resp = client.delete_provisioned_concurrency_config({
|
@@ -1420,9 +1564,9 @@ module Aws::Lambda
|
|
1420
1564
|
# * {Types::GetAccountSettingsResponse#account_usage #account_usage} => Types::AccountUsage
|
1421
1565
|
#
|
1422
1566
|
#
|
1423
|
-
# @example Example: To
|
1567
|
+
# @example Example: To get account settings
|
1424
1568
|
#
|
1425
|
-
# # This operation
|
1569
|
+
# # This operation takes no parameters and returns details about storage and concurrency quotas in the current Region.
|
1426
1570
|
#
|
1427
1571
|
# resp = client.get_account_settings({
|
1428
1572
|
# })
|
@@ -1430,8 +1574,15 @@ module Aws::Lambda
|
|
1430
1574
|
# resp.to_h outputs the following:
|
1431
1575
|
# {
|
1432
1576
|
# account_limit: {
|
1577
|
+
# code_size_unzipped: 262144000,
|
1578
|
+
# code_size_zipped: 52428800,
|
1579
|
+
# concurrent_executions: 1000,
|
1580
|
+
# total_code_size: 80530636800,
|
1581
|
+
# unreserved_concurrent_executions: 1000,
|
1433
1582
|
# },
|
1434
1583
|
# account_usage: {
|
1584
|
+
# function_count: 4,
|
1585
|
+
# total_code_size: 9426,
|
1435
1586
|
# },
|
1436
1587
|
# }
|
1437
1588
|
#
|
@@ -1488,21 +1639,22 @@ module Aws::Lambda
|
|
1488
1639
|
# * {Types::AliasConfiguration#revision_id #revision_id} => String
|
1489
1640
|
#
|
1490
1641
|
#
|
1491
|
-
# @example Example: To
|
1642
|
+
# @example Example: To get a Lambda function alias
|
1492
1643
|
#
|
1493
|
-
# #
|
1644
|
+
# # The following example returns details about an alias named BLUE for a function named my-function
|
1494
1645
|
#
|
1495
1646
|
# resp = client.get_alias({
|
1496
|
-
# function_name: "
|
1497
|
-
# name: "
|
1647
|
+
# function_name: "my-function",
|
1648
|
+
# name: "BLUE",
|
1498
1649
|
# })
|
1499
1650
|
#
|
1500
1651
|
# resp.to_h outputs the following:
|
1501
1652
|
# {
|
1502
|
-
# alias_arn: "arn:aws:lambda:us-west-2:123456789012:function:
|
1503
|
-
# description: "",
|
1504
|
-
# function_version: "
|
1505
|
-
# name: "
|
1653
|
+
# alias_arn: "arn:aws:lambda:us-west-2:123456789012:function:my-function:BLUE",
|
1654
|
+
# description: "Production environment BLUE.",
|
1655
|
+
# function_version: "3",
|
1656
|
+
# name: "BLUE",
|
1657
|
+
# revision_id: "594f41fb-xmpl-4c20-95c7-6ca5f2a92c93",
|
1506
1658
|
# }
|
1507
1659
|
#
|
1508
1660
|
# @example Request syntax with placeholder values
|
@@ -1555,24 +1707,30 @@ module Aws::Lambda
|
|
1555
1707
|
# * {Types::EventSourceMappingConfiguration#maximum_retry_attempts #maximum_retry_attempts} => Integer
|
1556
1708
|
#
|
1557
1709
|
#
|
1558
|
-
# @example Example: To
|
1710
|
+
# @example Example: To get a Lambda function's event source mapping
|
1559
1711
|
#
|
1560
|
-
# #
|
1712
|
+
# # The following example returns details about an event source mapping. To get a mapping's UUID, use
|
1713
|
+
# # ListEventSourceMappings.
|
1561
1714
|
#
|
1562
1715
|
# resp = client.get_event_source_mapping({
|
1563
|
-
# uuid: "
|
1716
|
+
# uuid: "14e0db71-xmpl-4eb5-b481-8945cf9d10c2",
|
1564
1717
|
# })
|
1565
1718
|
#
|
1566
1719
|
# resp.to_h outputs the following:
|
1567
1720
|
# {
|
1568
|
-
# batch_size:
|
1569
|
-
#
|
1570
|
-
#
|
1571
|
-
#
|
1572
|
-
#
|
1573
|
-
#
|
1574
|
-
#
|
1575
|
-
#
|
1721
|
+
# batch_size: 500,
|
1722
|
+
# bisect_batch_on_function_error: false,
|
1723
|
+
# destination_config: {
|
1724
|
+
# },
|
1725
|
+
# event_source_arn: "arn:aws:sqs:us-east-2:123456789012:mySQSqueue",
|
1726
|
+
# function_arn: "arn:aws:lambda:us-east-2:123456789012:function:myFunction",
|
1727
|
+
# last_modified: Time.parse("${timestamp}"),
|
1728
|
+
# last_processing_result: "No records processed",
|
1729
|
+
# maximum_record_age_in_seconds: 604800,
|
1730
|
+
# maximum_retry_attempts: 10000,
|
1731
|
+
# state: "Creating",
|
1732
|
+
# state_transition_reason: "User action",
|
1733
|
+
# uuid: "14e0db71-xmpl-4eb5-b481-8945cf9d10c2",
|
1576
1734
|
# }
|
1577
1735
|
#
|
1578
1736
|
# @example Request syntax with placeholder values
|
@@ -1642,45 +1800,50 @@ module Aws::Lambda
|
|
1642
1800
|
# * {Types::GetFunctionResponse#concurrency #concurrency} => Types::Concurrency
|
1643
1801
|
#
|
1644
1802
|
#
|
1645
|
-
# @example Example: To
|
1803
|
+
# @example Example: To get a Lambda function
|
1646
1804
|
#
|
1647
|
-
# #
|
1805
|
+
# # The following example returns code and configuration details for version 1 of a function named my-function.
|
1648
1806
|
#
|
1649
1807
|
# resp = client.get_function({
|
1650
|
-
# function_name: "
|
1808
|
+
# function_name: "my-function",
|
1651
1809
|
# qualifier: "1",
|
1652
1810
|
# })
|
1653
1811
|
#
|
1654
1812
|
# resp.to_h outputs the following:
|
1655
1813
|
# {
|
1656
1814
|
# code: {
|
1657
|
-
# location: "
|
1815
|
+
# location: "https://awslambda-us-west-2-tasks.s3.us-west-2.amazonaws.com/snapshots/123456789012/my-function-e7d9d1ed-xmpl-4f79-904a-4b87f2681f30?versionId=sH3TQwBOaUy...",
|
1658
1816
|
# repository_type: "S3",
|
1659
1817
|
# },
|
1660
1818
|
# configuration: {
|
1661
|
-
# code_sha_256: "
|
1662
|
-
# code_size:
|
1663
|
-
# description: "
|
1819
|
+
# code_sha_256: "YFgDgEKG3ugvF1+pX64gV6tu9qNuIYNUdgJm8nCxsm4=",
|
1820
|
+
# code_size: 5797206,
|
1821
|
+
# description: "Process image objects from Amazon S3.",
|
1664
1822
|
# environment: {
|
1665
1823
|
# variables: {
|
1666
|
-
# "
|
1824
|
+
# "BUCKET" => "my-bucket-1xpuxmplzrlbh",
|
1825
|
+
# "PREFIX" => "inbound",
|
1667
1826
|
# },
|
1668
1827
|
# },
|
1669
|
-
# function_arn: "arn:aws:lambda:us-west-2:123456789012:function:
|
1670
|
-
# function_name: "
|
1828
|
+
# function_arn: "arn:aws:lambda:us-west-2:123456789012:function:my-function",
|
1829
|
+
# function_name: "my-function",
|
1671
1830
|
# handler: "index.handler",
|
1672
|
-
#
|
1673
|
-
#
|
1674
|
-
#
|
1831
|
+
# kms_key_arn: "arn:aws:kms:us-west-2:123456789012:key/b0844d6c-xmpl-4463-97a4-d49f50839966",
|
1832
|
+
# last_modified: Time.parse("2020-04-10T19:06:32.563+0000"),
|
1833
|
+
# last_update_status: "Successful",
|
1834
|
+
# memory_size: 256,
|
1835
|
+
# revision_id: "b75dcd81-xmpl-48a8-a75a-93ba8b5b9727",
|
1836
|
+
# role: "arn:aws:iam::123456789012:role/lambda-role",
|
1675
1837
|
# runtime: "nodejs12.x",
|
1676
|
-
#
|
1677
|
-
#
|
1678
|
-
#
|
1679
|
-
#
|
1680
|
-
# ],
|
1681
|
-
# subnet_ids: [
|
1682
|
-
# ],
|
1838
|
+
# state: "Active",
|
1839
|
+
# timeout: 15,
|
1840
|
+
# tracing_config: {
|
1841
|
+
# mode: "Active",
|
1683
1842
|
# },
|
1843
|
+
# version: "$LATEST",
|
1844
|
+
# },
|
1845
|
+
# tags: {
|
1846
|
+
# "DEPARTMENT" => "Assets",
|
1684
1847
|
# },
|
1685
1848
|
# }
|
1686
1849
|
#
|
@@ -1771,6 +1934,20 @@ module Aws::Lambda
|
|
1771
1934
|
#
|
1772
1935
|
# * {Types::GetFunctionConcurrencyResponse#reserved_concurrent_executions #reserved_concurrent_executions} => Integer
|
1773
1936
|
#
|
1937
|
+
#
|
1938
|
+
# @example Example: To get the reserved concurrency setting for a function
|
1939
|
+
#
|
1940
|
+
# # The following example returns the reserved concurrency setting for a function named my-function.
|
1941
|
+
#
|
1942
|
+
# resp = client.get_function_concurrency({
|
1943
|
+
# function_name: "my-function",
|
1944
|
+
# })
|
1945
|
+
#
|
1946
|
+
# resp.to_h outputs the following:
|
1947
|
+
# {
|
1948
|
+
# reserved_concurrent_executions: 250,
|
1949
|
+
# }
|
1950
|
+
#
|
1774
1951
|
# @example Request syntax with placeholder values
|
1775
1952
|
#
|
1776
1953
|
# resp = client.get_function_concurrency({
|
@@ -1848,36 +2025,42 @@ module Aws::Lambda
|
|
1848
2025
|
# * {Types::FunctionConfiguration#last_update_status_reason_code #last_update_status_reason_code} => String
|
1849
2026
|
#
|
1850
2027
|
#
|
1851
|
-
# @example Example: To
|
2028
|
+
# @example Example: To get a Lambda function's event source mapping
|
1852
2029
|
#
|
1853
|
-
# #
|
2030
|
+
# # The following example returns and configuration details for version 1 of a function named my-function.
|
1854
2031
|
#
|
1855
2032
|
# resp = client.get_function_configuration({
|
1856
|
-
# function_name: "
|
2033
|
+
# function_name: "my-function",
|
1857
2034
|
# qualifier: "1",
|
1858
2035
|
# })
|
1859
2036
|
#
|
1860
2037
|
# resp.to_h outputs the following:
|
1861
2038
|
# {
|
1862
|
-
# code_sha_256: "
|
1863
|
-
# code_size:
|
1864
|
-
#
|
1865
|
-
# },
|
1866
|
-
# description: "",
|
2039
|
+
# code_sha_256: "YFgDgEKG3ugvF1+pX64gV6tu9qNuIYNUdgJm8nCxsm4=",
|
2040
|
+
# code_size: 5797206,
|
2041
|
+
# description: "Process image objects from Amazon S3.",
|
1867
2042
|
# environment: {
|
2043
|
+
# variables: {
|
2044
|
+
# "BUCKET" => "my-bucket-1xpuxmplzrlbh",
|
2045
|
+
# "PREFIX" => "inbound",
|
2046
|
+
# },
|
1868
2047
|
# },
|
1869
|
-
# function_arn: "arn:aws:lambda:us-west-2:123456789012:function:
|
1870
|
-
# function_name: "
|
2048
|
+
# function_arn: "arn:aws:lambda:us-west-2:123456789012:function:my-function",
|
2049
|
+
# function_name: "my-function",
|
1871
2050
|
# handler: "index.handler",
|
1872
|
-
# kms_key_arn: "",
|
1873
|
-
# last_modified: Time.parse("
|
1874
|
-
#
|
1875
|
-
#
|
1876
|
-
#
|
1877
|
-
#
|
1878
|
-
#
|
1879
|
-
#
|
2051
|
+
# kms_key_arn: "arn:aws:kms:us-west-2:123456789012:key/b0844d6c-xmpl-4463-97a4-d49f50839966",
|
2052
|
+
# last_modified: Time.parse("2020-04-10T19:06:32.563+0000"),
|
2053
|
+
# last_update_status: "Successful",
|
2054
|
+
# memory_size: 256,
|
2055
|
+
# revision_id: "b75dcd81-xmpl-48a8-a75a-93ba8b5b9727",
|
2056
|
+
# role: "arn:aws:iam::123456789012:role/lambda-role",
|
2057
|
+
# runtime: "nodejs12.x",
|
2058
|
+
# state: "Active",
|
2059
|
+
# timeout: 15,
|
2060
|
+
# tracing_config: {
|
2061
|
+
# mode: "Active",
|
1880
2062
|
# },
|
2063
|
+
# version: "$LATEST",
|
1881
2064
|
# }
|
1882
2065
|
#
|
1883
2066
|
# @example Request syntax with placeholder values
|
@@ -1974,6 +2157,32 @@ module Aws::Lambda
|
|
1974
2157
|
# * {Types::FunctionEventInvokeConfig#maximum_event_age_in_seconds #maximum_event_age_in_seconds} => Integer
|
1975
2158
|
# * {Types::FunctionEventInvokeConfig#destination_config #destination_config} => Types::DestinationConfig
|
1976
2159
|
#
|
2160
|
+
#
|
2161
|
+
# @example Example: To get an asynchronous invocation configuration
|
2162
|
+
#
|
2163
|
+
# # The following example returns the asynchronous invocation configuration for the BLUE alias of a function named
|
2164
|
+
# # my-function.
|
2165
|
+
#
|
2166
|
+
# resp = client.get_function_event_invoke_config({
|
2167
|
+
# function_name: "my-function",
|
2168
|
+
# qualifier: "BLUE",
|
2169
|
+
# })
|
2170
|
+
#
|
2171
|
+
# resp.to_h outputs the following:
|
2172
|
+
# {
|
2173
|
+
# destination_config: {
|
2174
|
+
# on_failure: {
|
2175
|
+
# destination: "arn:aws:sqs:us-east-2:123456789012:failed-invocations",
|
2176
|
+
# },
|
2177
|
+
# on_success: {
|
2178
|
+
# },
|
2179
|
+
# },
|
2180
|
+
# function_arn: "arn:aws:lambda:us-east-2:123456789012:function:my-function:BLUE",
|
2181
|
+
# last_modified: Time.parse("${timestamp}"),
|
2182
|
+
# maximum_event_age_in_seconds: 3600,
|
2183
|
+
# maximum_retry_attempts: 0,
|
2184
|
+
# }
|
2185
|
+
#
|
1977
2186
|
# @example Request syntax with placeholder values
|
1978
2187
|
#
|
1979
2188
|
# resp = client.get_function_event_invoke_config({
|
@@ -2023,6 +2232,35 @@ module Aws::Lambda
|
|
2023
2232
|
# * {Types::GetLayerVersionResponse#compatible_runtimes #compatible_runtimes} => Array<String>
|
2024
2233
|
# * {Types::GetLayerVersionResponse#license_info #license_info} => String
|
2025
2234
|
#
|
2235
|
+
#
|
2236
|
+
# @example Example: To get information about a Lambda layer version
|
2237
|
+
#
|
2238
|
+
# # The following example returns information for version 1 of a layer named my-layer.
|
2239
|
+
#
|
2240
|
+
# resp = client.get_layer_version({
|
2241
|
+
# layer_name: "my-layer",
|
2242
|
+
# version_number: 1,
|
2243
|
+
# })
|
2244
|
+
#
|
2245
|
+
# resp.to_h outputs the following:
|
2246
|
+
# {
|
2247
|
+
# compatible_runtimes: [
|
2248
|
+
# "python3.6",
|
2249
|
+
# "python3.7",
|
2250
|
+
# ],
|
2251
|
+
# content: {
|
2252
|
+
# code_sha_256: "tv9jJO+rPbXUUXuRKi7CwHzKtLDkDRJLB3cC3Z/ouXo=",
|
2253
|
+
# code_size: 169,
|
2254
|
+
# location: "https://awslambda-us-east-2-layers.s3.us-east-2.amazonaws.com/snapshots/123456789012/my-layer-4aaa2fbb-ff77-4b0a-ad92-5b78a716a96a?versionId=27iWyA73cCAYqyH...",
|
2255
|
+
# },
|
2256
|
+
# created_date: Time.parse("2018-11-14T23:03:52.894+0000"),
|
2257
|
+
# description: "My Python layer",
|
2258
|
+
# layer_arn: "arn:aws:lambda:us-east-2:123456789012:layer:my-layer",
|
2259
|
+
# layer_version_arn: "arn:aws:lambda:us-east-2:123456789012:layer:my-layer:1",
|
2260
|
+
# license_info: "MIT",
|
2261
|
+
# version: 1,
|
2262
|
+
# }
|
2263
|
+
#
|
2026
2264
|
# @example Request syntax with placeholder values
|
2027
2265
|
#
|
2028
2266
|
# resp = client.get_layer_version({
|
@@ -2074,6 +2312,32 @@ module Aws::Lambda
|
|
2074
2312
|
# * {Types::GetLayerVersionResponse#compatible_runtimes #compatible_runtimes} => Array<String>
|
2075
2313
|
# * {Types::GetLayerVersionResponse#license_info #license_info} => String
|
2076
2314
|
#
|
2315
|
+
#
|
2316
|
+
# @example Example: To get information about a Lambda layer version
|
2317
|
+
#
|
2318
|
+
# # The following example returns information about the layer version with the specified Amazon Resource Name (ARN).
|
2319
|
+
#
|
2320
|
+
# resp = client.get_layer_version_by_arn({
|
2321
|
+
# arn: "arn:aws:lambda:ca-central-1:123456789012:layer:blank-python-lib:3",
|
2322
|
+
# })
|
2323
|
+
#
|
2324
|
+
# resp.to_h outputs the following:
|
2325
|
+
# {
|
2326
|
+
# compatible_runtimes: [
|
2327
|
+
# "python3.8",
|
2328
|
+
# ],
|
2329
|
+
# content: {
|
2330
|
+
# code_sha_256: "6x+xmpl/M3BnQUk7gS9sGmfeFsR/npojXoA3fZUv4eU=",
|
2331
|
+
# code_size: 9529009,
|
2332
|
+
# location: "https://awslambda-us-east-2-layers.s3.us-east-2.amazonaws.com/snapshots/123456789012/blank-python-lib-e5212378-xmpl-44ee-8398-9d8ec5113949?versionId=WbZnvf...",
|
2333
|
+
# },
|
2334
|
+
# created_date: Time.parse("2020-03-31T00:35:18.949+0000"),
|
2335
|
+
# description: "Dependencies for the blank-python sample app.",
|
2336
|
+
# layer_arn: "arn:aws:lambda:us-east-2:123456789012:layer:blank-python-lib",
|
2337
|
+
# layer_version_arn: "arn:aws:lambda:us-east-2:123456789012:layer:blank-python-lib:3",
|
2338
|
+
# version: 3,
|
2339
|
+
# }
|
2340
|
+
#
|
2077
2341
|
# @example Request syntax with placeholder values
|
2078
2342
|
#
|
2079
2343
|
# resp = client.get_layer_version_by_arn({
|
@@ -2177,16 +2441,17 @@ module Aws::Lambda
|
|
2177
2441
|
#
|
2178
2442
|
# @example Example: To retrieve a Lambda function policy
|
2179
2443
|
#
|
2180
|
-
# #
|
2444
|
+
# # The following example returns the resource-based policy for version 1 of a Lambda function named my-function.
|
2181
2445
|
#
|
2182
2446
|
# resp = client.get_policy({
|
2183
|
-
# function_name: "
|
2447
|
+
# function_name: "my-function",
|
2184
2448
|
# qualifier: "1",
|
2185
2449
|
# })
|
2186
2450
|
#
|
2187
2451
|
# resp.to_h outputs the following:
|
2188
2452
|
# {
|
2189
|
-
# policy: "",
|
2453
|
+
# policy: "{\"Version\":\"2012-10-17\",\"Id\":\"default\",\"Statement\":[{\"Sid\":\"xaccount\",\"Effect\":\"Allow\",\"Principal\":{\"AWS\":\"arn:aws:iam::123456789012:root\"},\"Action\":\"lambda:InvokeFunction\",\"Resource\":\"arn:aws:lambda:us-east-2:123456789012:function:my-function:1\"}]}",
|
2454
|
+
# revision_id: "4843f2f6-7c59-4fda-b484-afd0bc0e22b8",
|
2190
2455
|
# }
|
2191
2456
|
#
|
2192
2457
|
# @example Request syntax with placeholder values
|
@@ -2240,6 +2505,45 @@ module Aws::Lambda
|
|
2240
2505
|
# * {Types::GetProvisionedConcurrencyConfigResponse#status_reason #status_reason} => String
|
2241
2506
|
# * {Types::GetProvisionedConcurrencyConfigResponse#last_modified #last_modified} => Time
|
2242
2507
|
#
|
2508
|
+
#
|
2509
|
+
# @example Example: To get a provisioned concurrency configuration
|
2510
|
+
#
|
2511
|
+
# # The following example returns details for the provisioned concurrency configuration for the BLUE alias of the specified
|
2512
|
+
# # function.
|
2513
|
+
#
|
2514
|
+
# resp = client.get_provisioned_concurrency_config({
|
2515
|
+
# function_name: "my-function",
|
2516
|
+
# qualifier: "BLUE",
|
2517
|
+
# })
|
2518
|
+
#
|
2519
|
+
# resp.to_h outputs the following:
|
2520
|
+
# {
|
2521
|
+
# allocated_provisioned_concurrent_executions: 100,
|
2522
|
+
# available_provisioned_concurrent_executions: 100,
|
2523
|
+
# last_modified: Time.parse("2019-12-31T20:28:49+0000"),
|
2524
|
+
# requested_provisioned_concurrent_executions: 100,
|
2525
|
+
# status: "READY",
|
2526
|
+
# }
|
2527
|
+
#
|
2528
|
+
# @example Example: To view a provisioned concurrency configuration
|
2529
|
+
#
|
2530
|
+
# # The following example displays details for the provisioned concurrency configuration for the BLUE alias of the specified
|
2531
|
+
# # function.
|
2532
|
+
#
|
2533
|
+
# resp = client.get_provisioned_concurrency_config({
|
2534
|
+
# function_name: "my-function",
|
2535
|
+
# qualifier: "BLUE",
|
2536
|
+
# })
|
2537
|
+
#
|
2538
|
+
# resp.to_h outputs the following:
|
2539
|
+
# {
|
2540
|
+
# allocated_provisioned_concurrent_executions: 100,
|
2541
|
+
# available_provisioned_concurrent_executions: 100,
|
2542
|
+
# last_modified: Time.parse("2019-12-31T20:28:49+0000"),
|
2543
|
+
# requested_provisioned_concurrent_executions: 100,
|
2544
|
+
# status: "READY",
|
2545
|
+
# }
|
2546
|
+
#
|
2243
2547
|
# @example Request syntax with placeholder values
|
2244
2548
|
#
|
2245
2549
|
# resp = client.get_provisioned_concurrency_config({
|
@@ -2301,7 +2605,7 @@ module Aws::Lambda
|
|
2301
2605
|
# your HTTP client, SDK, firewall, proxy, or operating system to allow
|
2302
2606
|
# for long connections with timeout or keep-alive settings.
|
2303
2607
|
#
|
2304
|
-
# This operation requires permission for the
|
2608
|
+
# This operation requires permission for the [lambda:InvokeFunction][8]
|
2305
2609
|
# action.
|
2306
2610
|
#
|
2307
2611
|
#
|
@@ -2313,6 +2617,7 @@ module Aws::Lambda
|
|
2313
2617
|
# [5]: https://docs.aws.amazon.com/lambda/latest/dg/invocation-async.html
|
2314
2618
|
# [6]: https://docs.aws.amazon.com/lambda/latest/dg/invocation-async.html#dlq
|
2315
2619
|
# [7]: https://docs.aws.amazon.com/lambda/latest/dg/limits.html
|
2620
|
+
# [8]: https://docs.aws.amazon.com/IAM/latest/UserGuide/list_awslambda.html
|
2316
2621
|
#
|
2317
2622
|
# @option params [required, String] :function_name
|
2318
2623
|
# The name of the Lambda function, version, or alias.
|
@@ -2371,23 +2676,35 @@ module Aws::Lambda
|
|
2371
2676
|
#
|
2372
2677
|
# @example Example: To invoke a Lambda function
|
2373
2678
|
#
|
2374
|
-
# #
|
2679
|
+
# # The following example invokes version 1 of a function named my-function with an empty event payload.
|
2680
|
+
#
|
2681
|
+
# resp = client.invoke({
|
2682
|
+
# function_name: "my-function",
|
2683
|
+
# payload: "{}",
|
2684
|
+
# qualifier: "1",
|
2685
|
+
# })
|
2686
|
+
#
|
2687
|
+
# resp.to_h outputs the following:
|
2688
|
+
# {
|
2689
|
+
# payload: "200 SUCCESS",
|
2690
|
+
# status_code: 200,
|
2691
|
+
# }
|
2692
|
+
#
|
2693
|
+
# @example Example: To invoke a Lambda function asynchronously
|
2694
|
+
#
|
2695
|
+
# # The following example invokes version 1 of a function named my-function asynchronously.
|
2375
2696
|
#
|
2376
2697
|
# resp = client.invoke({
|
2377
|
-
#
|
2378
|
-
# function_name: "MyFunction",
|
2698
|
+
# function_name: "my-function",
|
2379
2699
|
# invocation_type: "Event",
|
2380
|
-
#
|
2381
|
-
# payload: "fileb://file-path/input.json",
|
2700
|
+
# payload: "{}",
|
2382
2701
|
# qualifier: "1",
|
2383
2702
|
# })
|
2384
2703
|
#
|
2385
2704
|
# resp.to_h outputs the following:
|
2386
2705
|
# {
|
2387
|
-
#
|
2388
|
-
#
|
2389
|
-
# payload: "?",
|
2390
|
-
# status_code: 123,
|
2706
|
+
# payload: "",
|
2707
|
+
# status_code: 202,
|
2391
2708
|
# }
|
2392
2709
|
#
|
2393
2710
|
# @example Request syntax with placeholder values
|
@@ -2447,16 +2764,16 @@ module Aws::Lambda
|
|
2447
2764
|
#
|
2448
2765
|
# @example Example: To invoke a Lambda function asynchronously
|
2449
2766
|
#
|
2450
|
-
# #
|
2767
|
+
# # The following example invokes a Lambda function asynchronously
|
2451
2768
|
#
|
2452
2769
|
# resp = client.invoke_async({
|
2453
|
-
# function_name: "
|
2454
|
-
# invoke_args: "
|
2770
|
+
# function_name: "my-function",
|
2771
|
+
# invoke_args: "{}",
|
2455
2772
|
# })
|
2456
2773
|
#
|
2457
2774
|
# resp.to_h outputs the following:
|
2458
2775
|
# {
|
2459
|
-
# status:
|
2776
|
+
# status: 202,
|
2460
2777
|
# }
|
2461
2778
|
#
|
2462
2779
|
# @example Request syntax with placeholder values
|
@@ -2519,22 +2836,37 @@ module Aws::Lambda
|
|
2519
2836
|
# The returned {Seahorse::Client::Response response} is a pageable response and is Enumerable. For details on usage see {Aws::PageableResponse PageableResponse}.
|
2520
2837
|
#
|
2521
2838
|
#
|
2522
|
-
# @example Example: To
|
2839
|
+
# @example Example: To list a function's aliases
|
2523
2840
|
#
|
2524
|
-
# #
|
2841
|
+
# # The following example returns a list of aliases for a function named my-function.
|
2525
2842
|
#
|
2526
2843
|
# resp = client.list_aliases({
|
2527
|
-
# function_name: "
|
2528
|
-
# function_version: "1",
|
2529
|
-
# marker: "",
|
2530
|
-
# max_items: 123,
|
2844
|
+
# function_name: "my-function",
|
2531
2845
|
# })
|
2532
2846
|
#
|
2533
2847
|
# resp.to_h outputs the following:
|
2534
2848
|
# {
|
2535
2849
|
# aliases: [
|
2850
|
+
# {
|
2851
|
+
# alias_arn: "arn:aws:lambda:us-west-2:123456789012:function:my-function:BETA",
|
2852
|
+
# description: "Production environment BLUE.",
|
2853
|
+
# function_version: "2",
|
2854
|
+
# name: "BLUE",
|
2855
|
+
# revision_id: "a410117f-xmpl-494e-8035-7e204bb7933b",
|
2856
|
+
# routing_config: {
|
2857
|
+
# additional_version_weights: {
|
2858
|
+
# "1" => 0.7,
|
2859
|
+
# },
|
2860
|
+
# },
|
2861
|
+
# },
|
2862
|
+
# {
|
2863
|
+
# alias_arn: "arn:aws:lambda:us-west-2:123456789012:function:my-function:LIVE",
|
2864
|
+
# description: "Production environment GREEN.",
|
2865
|
+
# function_version: "1",
|
2866
|
+
# name: "GREEN",
|
2867
|
+
# revision_id: "21d40116-xmpl-40ba-9360-3ea284da1bb5",
|
2868
|
+
# },
|
2536
2869
|
# ],
|
2537
|
-
# next_marker: "",
|
2538
2870
|
# }
|
2539
2871
|
#
|
2540
2872
|
# @example Request syntax with placeholder values
|
@@ -2611,6 +2943,30 @@ module Aws::Lambda
|
|
2611
2943
|
#
|
2612
2944
|
# The returned {Seahorse::Client::Response response} is a pageable response and is Enumerable. For details on usage see {Aws::PageableResponse PageableResponse}.
|
2613
2945
|
#
|
2946
|
+
#
|
2947
|
+
# @example Example: To list the event source mappings for a function
|
2948
|
+
#
|
2949
|
+
# # The following example returns a list of the event source mappings for a function named my-function.
|
2950
|
+
#
|
2951
|
+
# resp = client.list_event_source_mappings({
|
2952
|
+
# function_name: "my-function",
|
2953
|
+
# })
|
2954
|
+
#
|
2955
|
+
# resp.to_h outputs the following:
|
2956
|
+
# {
|
2957
|
+
# event_source_mappings: [
|
2958
|
+
# {
|
2959
|
+
# batch_size: 5,
|
2960
|
+
# event_source_arn: "arn:aws:sqs:us-west-2:123456789012:mySQSqueue",
|
2961
|
+
# function_arn: "arn:aws:lambda:us-west-2:123456789012:function:my-function",
|
2962
|
+
# last_modified: Time.parse(1569284520.333),
|
2963
|
+
# state: "Enabled",
|
2964
|
+
# state_transition_reason: "USER_INITIATED",
|
2965
|
+
# uuid: "a1b2c3d4-5678-90ab-cdef-11111EXAMPLE",
|
2966
|
+
# },
|
2967
|
+
# ],
|
2968
|
+
# }
|
2969
|
+
#
|
2614
2970
|
# @example Request syntax with placeholder values
|
2615
2971
|
#
|
2616
2972
|
# resp = client.list_event_source_mappings({
|
@@ -2684,6 +3040,33 @@ module Aws::Lambda
|
|
2684
3040
|
#
|
2685
3041
|
# The returned {Seahorse::Client::Response response} is a pageable response and is Enumerable. For details on usage see {Aws::PageableResponse PageableResponse}.
|
2686
3042
|
#
|
3043
|
+
#
|
3044
|
+
# @example Example: To view a list of asynchronous invocation configurations
|
3045
|
+
#
|
3046
|
+
# # The following example returns a list of asynchronous invocation configurations for a function named my-function.
|
3047
|
+
#
|
3048
|
+
# resp = client.list_function_event_invoke_configs({
|
3049
|
+
# function_name: "my-function",
|
3050
|
+
# })
|
3051
|
+
#
|
3052
|
+
# resp.to_h outputs the following:
|
3053
|
+
# {
|
3054
|
+
# function_event_invoke_configs: [
|
3055
|
+
# {
|
3056
|
+
# function_arn: "arn:aws:lambda:us-east-2:123456789012:function:my-function:GREEN",
|
3057
|
+
# last_modified: Time.parse(1577824406.719),
|
3058
|
+
# maximum_event_age_in_seconds: 1800,
|
3059
|
+
# maximum_retry_attempts: 2,
|
3060
|
+
# },
|
3061
|
+
# {
|
3062
|
+
# function_arn: "arn:aws:lambda:us-east-2:123456789012:function:my-function:BLUE",
|
3063
|
+
# last_modified: Time.parse(1577824396.653),
|
3064
|
+
# maximum_event_age_in_seconds: 3600,
|
3065
|
+
# maximum_retry_attempts: 0,
|
3066
|
+
# },
|
3067
|
+
# ],
|
3068
|
+
# }
|
3069
|
+
#
|
2687
3070
|
# @example Request syntax with placeholder values
|
2688
3071
|
#
|
2689
3072
|
# resp = client.list_function_event_invoke_configs({
|
@@ -2744,18 +3127,59 @@ module Aws::Lambda
|
|
2744
3127
|
# The returned {Seahorse::Client::Response response} is a pageable response and is Enumerable. For details on usage see {Aws::PageableResponse PageableResponse}.
|
2745
3128
|
#
|
2746
3129
|
#
|
2747
|
-
# @example Example: To
|
3130
|
+
# @example Example: To get a list of Lambda functions
|
2748
3131
|
#
|
2749
|
-
# # This operation
|
3132
|
+
# # This operation returns a list of Lambda functions.
|
2750
3133
|
#
|
2751
3134
|
# resp = client.list_functions({
|
2752
|
-
# marker: "",
|
2753
|
-
# max_items: 25,
|
2754
3135
|
# })
|
2755
3136
|
#
|
2756
3137
|
# resp.to_h outputs the following:
|
2757
3138
|
# {
|
2758
3139
|
# functions: [
|
3140
|
+
# {
|
3141
|
+
# code_sha_256: "dBG9m8SGdmlEjw/JYXlhhvCrAv5TxvXsbL/RMr0fT/I=",
|
3142
|
+
# code_size: 294,
|
3143
|
+
# description: "",
|
3144
|
+
# function_arn: "arn:aws:lambda:us-west-2:123456789012:function:helloworld",
|
3145
|
+
# function_name: "helloworld",
|
3146
|
+
# handler: "helloworld.handler",
|
3147
|
+
# last_modified: Time.parse("2019-09-23T18:32:33.857+0000"),
|
3148
|
+
# memory_size: 128,
|
3149
|
+
# revision_id: "1718e831-badf-4253-9518-d0644210af7b",
|
3150
|
+
# role: "arn:aws:iam::123456789012:role/service-role/MyTestFunction-role-zgur6bf4",
|
3151
|
+
# runtime: "nodejs10.x",
|
3152
|
+
# timeout: 3,
|
3153
|
+
# tracing_config: {
|
3154
|
+
# mode: "PassThrough",
|
3155
|
+
# },
|
3156
|
+
# version: "$LATEST",
|
3157
|
+
# },
|
3158
|
+
# {
|
3159
|
+
# code_sha_256: "sU0cJ2/hOZevwV/lTxCuQqK3gDZP3i8gUoqUUVRmY6E=",
|
3160
|
+
# code_size: 266,
|
3161
|
+
# description: "",
|
3162
|
+
# function_arn: "arn:aws:lambda:us-west-2:123456789012:function:my-function",
|
3163
|
+
# function_name: "my-function",
|
3164
|
+
# handler: "index.handler",
|
3165
|
+
# last_modified: Time.parse("2019-10-01T16:47:28.490+0000"),
|
3166
|
+
# memory_size: 256,
|
3167
|
+
# revision_id: "93017fc9-59cb-41dc-901b-4845ce4bf668",
|
3168
|
+
# role: "arn:aws:iam::123456789012:role/service-role/helloWorldPython-role-uy3l9qyq",
|
3169
|
+
# runtime: "nodejs10.x",
|
3170
|
+
# timeout: 3,
|
3171
|
+
# tracing_config: {
|
3172
|
+
# mode: "PassThrough",
|
3173
|
+
# },
|
3174
|
+
# version: "$LATEST",
|
3175
|
+
# vpc_config: {
|
3176
|
+
# security_group_ids: [
|
3177
|
+
# ],
|
3178
|
+
# subnet_ids: [
|
3179
|
+
# ],
|
3180
|
+
# vpc_id: "",
|
3181
|
+
# },
|
3182
|
+
# },
|
2759
3183
|
# ],
|
2760
3184
|
# next_marker: "",
|
2761
3185
|
# }
|
@@ -2847,6 +3271,39 @@ module Aws::Lambda
|
|
2847
3271
|
#
|
2848
3272
|
# The returned {Seahorse::Client::Response response} is a pageable response and is Enumerable. For details on usage see {Aws::PageableResponse PageableResponse}.
|
2849
3273
|
#
|
3274
|
+
#
|
3275
|
+
# @example Example: To list versions of a layer
|
3276
|
+
#
|
3277
|
+
# # The following example displays information about the versions for the layer named blank-java-lib
|
3278
|
+
#
|
3279
|
+
# resp = client.list_layer_versions({
|
3280
|
+
# layer_name: "blank-java-lib",
|
3281
|
+
# })
|
3282
|
+
#
|
3283
|
+
# resp.to_h outputs the following:
|
3284
|
+
# {
|
3285
|
+
# layer_versions: [
|
3286
|
+
# {
|
3287
|
+
# compatible_runtimes: [
|
3288
|
+
# "java8",
|
3289
|
+
# ],
|
3290
|
+
# created_date: Time.parse("2020-03-18T23:38:42.284+0000"),
|
3291
|
+
# description: "Dependencies for the blank-java sample app.",
|
3292
|
+
# layer_version_arn: "arn:aws:lambda:us-east-2:123456789012:layer:blank-java-lib:7",
|
3293
|
+
# version: 7,
|
3294
|
+
# },
|
3295
|
+
# {
|
3296
|
+
# compatible_runtimes: [
|
3297
|
+
# "java8",
|
3298
|
+
# ],
|
3299
|
+
# created_date: Time.parse("2020-03-17T07:24:21.960+0000"),
|
3300
|
+
# description: "Dependencies for the blank-java sample app.",
|
3301
|
+
# layer_version_arn: "arn:aws:lambda:us-east-2:123456789012:layer:blank-java-lib:6",
|
3302
|
+
# version: 6,
|
3303
|
+
# },
|
3304
|
+
# ],
|
3305
|
+
# }
|
3306
|
+
#
|
2850
3307
|
# @example Request syntax with placeholder values
|
2851
3308
|
#
|
2852
3309
|
# resp = client.list_layer_versions({
|
@@ -2902,6 +3359,35 @@ module Aws::Lambda
|
|
2902
3359
|
#
|
2903
3360
|
# The returned {Seahorse::Client::Response response} is a pageable response and is Enumerable. For details on usage see {Aws::PageableResponse PageableResponse}.
|
2904
3361
|
#
|
3362
|
+
#
|
3363
|
+
# @example Example: To list the layers that are compatible with your function's runtime
|
3364
|
+
#
|
3365
|
+
# # The following example returns information about layers that are compatible with the Python 3.7 runtime.
|
3366
|
+
#
|
3367
|
+
# resp = client.list_layers({
|
3368
|
+
# compatible_runtime: "python3.7",
|
3369
|
+
# })
|
3370
|
+
#
|
3371
|
+
# resp.to_h outputs the following:
|
3372
|
+
# {
|
3373
|
+
# layers: [
|
3374
|
+
# {
|
3375
|
+
# latest_matching_version: {
|
3376
|
+
# compatible_runtimes: [
|
3377
|
+
# "python3.6",
|
3378
|
+
# "python3.7",
|
3379
|
+
# ],
|
3380
|
+
# created_date: Time.parse("2018-11-15T00:37:46.592+0000"),
|
3381
|
+
# description: "My layer",
|
3382
|
+
# layer_version_arn: "arn:aws:lambda:us-east-2:123456789012:layer:my-layer:2",
|
3383
|
+
# version: 2,
|
3384
|
+
# },
|
3385
|
+
# layer_arn: "arn:aws:lambda:us-east-2:123456789012:layer:my-layer",
|
3386
|
+
# layer_name: "my-layer",
|
3387
|
+
# },
|
3388
|
+
# ],
|
3389
|
+
# }
|
3390
|
+
#
|
2905
3391
|
# @example Request syntax with placeholder values
|
2906
3392
|
#
|
2907
3393
|
# resp = client.list_layers({
|
@@ -2965,6 +3451,37 @@ module Aws::Lambda
|
|
2965
3451
|
#
|
2966
3452
|
# The returned {Seahorse::Client::Response response} is a pageable response and is Enumerable. For details on usage see {Aws::PageableResponse PageableResponse}.
|
2967
3453
|
#
|
3454
|
+
#
|
3455
|
+
# @example Example: To get a list of provisioned concurrency configurations
|
3456
|
+
#
|
3457
|
+
# # The following example returns a list of provisioned concurrency configurations for a function named my-function.
|
3458
|
+
#
|
3459
|
+
# resp = client.list_provisioned_concurrency_configs({
|
3460
|
+
# function_name: "my-function",
|
3461
|
+
# })
|
3462
|
+
#
|
3463
|
+
# resp.to_h outputs the following:
|
3464
|
+
# {
|
3465
|
+
# provisioned_concurrency_configs: [
|
3466
|
+
# {
|
3467
|
+
# allocated_provisioned_concurrent_executions: 100,
|
3468
|
+
# available_provisioned_concurrent_executions: 100,
|
3469
|
+
# function_arn: "arn:aws:lambda:us-east-2:123456789012:function:my-function:GREEN",
|
3470
|
+
# last_modified: Time.parse("2019-12-31T20:29:00+0000"),
|
3471
|
+
# requested_provisioned_concurrent_executions: 100,
|
3472
|
+
# status: "READY",
|
3473
|
+
# },
|
3474
|
+
# {
|
3475
|
+
# allocated_provisioned_concurrent_executions: 100,
|
3476
|
+
# available_provisioned_concurrent_executions: 100,
|
3477
|
+
# function_arn: "arn:aws:lambda:us-east-2:123456789012:function:my-function:BLUE",
|
3478
|
+
# last_modified: Time.parse("2019-12-31T20:28:49+0000"),
|
3479
|
+
# requested_provisioned_concurrent_executions: 100,
|
3480
|
+
# status: "READY",
|
3481
|
+
# },
|
3482
|
+
# ],
|
3483
|
+
# }
|
3484
|
+
#
|
2968
3485
|
# @example Request syntax with placeholder values
|
2969
3486
|
#
|
2970
3487
|
# resp = client.list_provisioned_concurrency_configs({
|
@@ -3008,6 +3525,23 @@ module Aws::Lambda
|
|
3008
3525
|
#
|
3009
3526
|
# * {Types::ListTagsResponse#tags #tags} => Hash<String,String>
|
3010
3527
|
#
|
3528
|
+
#
|
3529
|
+
# @example Example: To retrieve the list of tags for a Lambda function
|
3530
|
+
#
|
3531
|
+
# # The following example displays the tags attached to the my-function Lambda function.
|
3532
|
+
#
|
3533
|
+
# resp = client.list_tags({
|
3534
|
+
# resource: "arn:aws:lambda:us-west-2:123456789012:function:my-function",
|
3535
|
+
# })
|
3536
|
+
#
|
3537
|
+
# resp.to_h outputs the following:
|
3538
|
+
# {
|
3539
|
+
# tags: {
|
3540
|
+
# "Category" => "Web Tools",
|
3541
|
+
# "Department" => "Sales",
|
3542
|
+
# },
|
3543
|
+
# }
|
3544
|
+
#
|
3011
3545
|
# @example Request syntax with placeholder values
|
3012
3546
|
#
|
3013
3547
|
# resp = client.list_tags({
|
@@ -3065,20 +3599,67 @@ module Aws::Lambda
|
|
3065
3599
|
# The returned {Seahorse::Client::Response response} is a pageable response and is Enumerable. For details on usage see {Aws::PageableResponse PageableResponse}.
|
3066
3600
|
#
|
3067
3601
|
#
|
3068
|
-
# @example Example: To
|
3602
|
+
# @example Example: To list versions of a function
|
3069
3603
|
#
|
3070
|
-
# #
|
3604
|
+
# # The following example returns a list of versions of a function named my-function
|
3071
3605
|
#
|
3072
3606
|
# resp = client.list_versions_by_function({
|
3073
|
-
# function_name: "
|
3074
|
-
# marker: "",
|
3075
|
-
# max_items: 25,
|
3607
|
+
# function_name: "my-function",
|
3076
3608
|
# })
|
3077
3609
|
#
|
3078
3610
|
# resp.to_h outputs the following:
|
3079
3611
|
# {
|
3080
|
-
# next_marker: "",
|
3081
3612
|
# versions: [
|
3613
|
+
# {
|
3614
|
+
# code_sha_256: "YFgDgEKG3ugvF1+pX64gV6tu9qNuIYNUdgJm8nCxsm4=",
|
3615
|
+
# code_size: 5797206,
|
3616
|
+
# description: "Process image objects from Amazon S3.",
|
3617
|
+
# environment: {
|
3618
|
+
# variables: {
|
3619
|
+
# "BUCKET" => "my-bucket-1xpuxmplzrlbh",
|
3620
|
+
# "PREFIX" => "inbound",
|
3621
|
+
# },
|
3622
|
+
# },
|
3623
|
+
# function_arn: "arn:aws:lambda:us-west-2:123456789012:function:my-function",
|
3624
|
+
# function_name: "my-function",
|
3625
|
+
# handler: "index.handler",
|
3626
|
+
# kms_key_arn: "arn:aws:kms:us-west-2:123456789012:key/b0844d6c-xmpl-4463-97a4-d49f50839966",
|
3627
|
+
# last_modified: Time.parse("2020-04-10T19:06:32.563+0000"),
|
3628
|
+
# memory_size: 256,
|
3629
|
+
# revision_id: "850ca006-2d98-4ff4-86db-8766e9d32fe9",
|
3630
|
+
# role: "arn:aws:iam::123456789012:role/lambda-role",
|
3631
|
+
# runtime: "nodejs12.x",
|
3632
|
+
# timeout: 15,
|
3633
|
+
# tracing_config: {
|
3634
|
+
# mode: "Active",
|
3635
|
+
# },
|
3636
|
+
# version: "$LATEST",
|
3637
|
+
# },
|
3638
|
+
# {
|
3639
|
+
# code_sha_256: "YFgDgEKG3ugvF1+pX64gV6tu9qNuIYNUdgJm8nCxsm4=",
|
3640
|
+
# code_size: 5797206,
|
3641
|
+
# description: "Process image objects from Amazon S3.",
|
3642
|
+
# environment: {
|
3643
|
+
# variables: {
|
3644
|
+
# "BUCKET" => "my-bucket-1xpuxmplzrlbh",
|
3645
|
+
# "PREFIX" => "inbound",
|
3646
|
+
# },
|
3647
|
+
# },
|
3648
|
+
# function_arn: "arn:aws:lambda:us-west-2:123456789012:function:my-function",
|
3649
|
+
# function_name: "my-function",
|
3650
|
+
# handler: "index.handler",
|
3651
|
+
# kms_key_arn: "arn:aws:kms:us-west-2:123456789012:key/b0844d6c-xmpl-4463-97a4-d49f50839966",
|
3652
|
+
# last_modified: Time.parse("2020-04-10T19:06:32.563+0000"),
|
3653
|
+
# memory_size: 256,
|
3654
|
+
# revision_id: "b75dcd81-xmpl-48a8-a75a-93ba8b5b9727",
|
3655
|
+
# role: "arn:aws:iam::123456789012:role/lambda-role",
|
3656
|
+
# runtime: "nodejs12.x",
|
3657
|
+
# timeout: 5,
|
3658
|
+
# tracing_config: {
|
3659
|
+
# mode: "Active",
|
3660
|
+
# },
|
3661
|
+
# version: "1",
|
3662
|
+
# },
|
3082
3663
|
# ],
|
3083
3664
|
# }
|
3084
3665
|
#
|
@@ -3192,6 +3773,45 @@ module Aws::Lambda
|
|
3192
3773
|
# * {Types::PublishLayerVersionResponse#compatible_runtimes #compatible_runtimes} => Array<String>
|
3193
3774
|
# * {Types::PublishLayerVersionResponse#license_info #license_info} => String
|
3194
3775
|
#
|
3776
|
+
#
|
3777
|
+
# @example Example: To create a Lambda layer version
|
3778
|
+
#
|
3779
|
+
# # The following example creates a new Python library layer version. The command retrieves the layer content a file named
|
3780
|
+
# # layer.zip in the specified S3 bucket.
|
3781
|
+
#
|
3782
|
+
# resp = client.publish_layer_version({
|
3783
|
+
# compatible_runtimes: [
|
3784
|
+
# "python3.6",
|
3785
|
+
# "python3.7",
|
3786
|
+
# ],
|
3787
|
+
# content: {
|
3788
|
+
# s3_bucket: "lambda-layers-us-west-2-123456789012",
|
3789
|
+
# s3_key: "layer.zip",
|
3790
|
+
# },
|
3791
|
+
# description: "My Python layer",
|
3792
|
+
# layer_name: "my-layer",
|
3793
|
+
# license_info: "MIT",
|
3794
|
+
# })
|
3795
|
+
#
|
3796
|
+
# resp.to_h outputs the following:
|
3797
|
+
# {
|
3798
|
+
# compatible_runtimes: [
|
3799
|
+
# "python3.6",
|
3800
|
+
# "python3.7",
|
3801
|
+
# ],
|
3802
|
+
# content: {
|
3803
|
+
# code_sha_256: "tv9jJO+rPbXUUXuRKi7CwHzKtLDkDRJLB3cC3Z/ouXo=",
|
3804
|
+
# code_size: 169,
|
3805
|
+
# location: "https://awslambda-us-west-2-layers.s3.us-west-2.amazonaws.com/snapshots/123456789012/my-layer-4aaa2fbb-ff77-4b0a-ad92-5b78a716a96a?versionId=27iWyA73cCAYqyH...",
|
3806
|
+
# },
|
3807
|
+
# created_date: Time.parse("2018-11-14T23:03:52.894+0000"),
|
3808
|
+
# description: "My Python layer",
|
3809
|
+
# layer_arn: "arn:aws:lambda:us-west-2:123456789012:layer:my-layer",
|
3810
|
+
# layer_version_arn: "arn:aws:lambda:us-west-2:123456789012:layer:my-layer:1",
|
3811
|
+
# license_info: "MIT",
|
3812
|
+
# version: 1,
|
3813
|
+
# }
|
3814
|
+
#
|
3195
3815
|
# @example Request syntax with placeholder values
|
3196
3816
|
#
|
3197
3817
|
# resp = client.publish_layer_version({
|
@@ -3319,20 +3939,31 @@ module Aws::Lambda
|
|
3319
3939
|
#
|
3320
3940
|
# resp.to_h outputs the following:
|
3321
3941
|
# {
|
3322
|
-
# code_sha_256: "",
|
3323
|
-
# code_size:
|
3324
|
-
# description: "",
|
3325
|
-
#
|
3326
|
-
#
|
3942
|
+
# code_sha_256: "YFgDgEKG3ugvF1+pX64gV6tu9qNuIYNUdgJm8nCxsm4=",
|
3943
|
+
# code_size: 5797206,
|
3944
|
+
# description: "Process image objects from Amazon S3.",
|
3945
|
+
# environment: {
|
3946
|
+
# variables: {
|
3947
|
+
# "BUCKET" => "my-bucket-1xpuxmplzrlbh",
|
3948
|
+
# "PREFIX" => "inbound",
|
3949
|
+
# },
|
3950
|
+
# },
|
3951
|
+
# function_arn: "arn:aws:lambda:us-west-2:123456789012:function:my-function",
|
3952
|
+
# function_name: "my-function",
|
3327
3953
|
# handler: "index.handler",
|
3328
|
-
#
|
3329
|
-
#
|
3330
|
-
#
|
3331
|
-
#
|
3332
|
-
#
|
3333
|
-
#
|
3334
|
-
#
|
3954
|
+
# kms_key_arn: "arn:aws:kms:us-west-2:123456789012:key/b0844d6c-xmpl-4463-97a4-d49f50839966",
|
3955
|
+
# last_modified: Time.parse("2020-04-10T19:06:32.563+0000"),
|
3956
|
+
# last_update_status: "Successful",
|
3957
|
+
# memory_size: 256,
|
3958
|
+
# revision_id: "b75dcd81-xmpl-48a8-a75a-93ba8b5b9727",
|
3959
|
+
# role: "arn:aws:iam::123456789012:role/lambda-role",
|
3960
|
+
# runtime: "nodejs12.x",
|
3961
|
+
# state: "Active",
|
3962
|
+
# timeout: 5,
|
3963
|
+
# tracing_config: {
|
3964
|
+
# mode: "Active",
|
3335
3965
|
# },
|
3966
|
+
# version: "1",
|
3336
3967
|
# }
|
3337
3968
|
#
|
3338
3969
|
# @example Request syntax with placeholder values
|
@@ -3432,6 +4063,21 @@ module Aws::Lambda
|
|
3432
4063
|
#
|
3433
4064
|
# * {Types::Concurrency#reserved_concurrent_executions #reserved_concurrent_executions} => Integer
|
3434
4065
|
#
|
4066
|
+
#
|
4067
|
+
# @example Example: To configure a reserved concurrency limit for a function
|
4068
|
+
#
|
4069
|
+
# # The following example configures 100 reserved concurrent executions for the my-function function.
|
4070
|
+
#
|
4071
|
+
# resp = client.put_function_concurrency({
|
4072
|
+
# function_name: "my-function",
|
4073
|
+
# reserved_concurrent_executions: 100,
|
4074
|
+
# })
|
4075
|
+
#
|
4076
|
+
# resp.to_h outputs the following:
|
4077
|
+
# {
|
4078
|
+
# reserved_concurrent_executions: 100,
|
4079
|
+
# }
|
4080
|
+
#
|
3435
4081
|
# @example Request syntax with placeholder values
|
3436
4082
|
#
|
3437
4083
|
# resp = client.put_function_concurrency({
|
@@ -3526,6 +4172,31 @@ module Aws::Lambda
|
|
3526
4172
|
# * {Types::FunctionEventInvokeConfig#maximum_event_age_in_seconds #maximum_event_age_in_seconds} => Integer
|
3527
4173
|
# * {Types::FunctionEventInvokeConfig#destination_config #destination_config} => Types::DestinationConfig
|
3528
4174
|
#
|
4175
|
+
#
|
4176
|
+
# @example Example: To configure error handling for asynchronous invocation
|
4177
|
+
#
|
4178
|
+
# # The following example sets a maximum event age of one hour and disables retries for the specified function.
|
4179
|
+
#
|
4180
|
+
# resp = client.put_function_event_invoke_config({
|
4181
|
+
# function_name: "my-function",
|
4182
|
+
# maximum_event_age_in_seconds: 3600,
|
4183
|
+
# maximum_retry_attempts: 0,
|
4184
|
+
# })
|
4185
|
+
#
|
4186
|
+
# resp.to_h outputs the following:
|
4187
|
+
# {
|
4188
|
+
# destination_config: {
|
4189
|
+
# on_failure: {
|
4190
|
+
# },
|
4191
|
+
# on_success: {
|
4192
|
+
# },
|
4193
|
+
# },
|
4194
|
+
# function_arn: "arn:aws:lambda:us-east-2:123456789012:function:my-function:$LATEST",
|
4195
|
+
# last_modified: Time.parse("${timestamp}"),
|
4196
|
+
# maximum_event_age_in_seconds: 3600,
|
4197
|
+
# maximum_retry_attempts: 0,
|
4198
|
+
# }
|
4199
|
+
#
|
3529
4200
|
# @example Request syntax with placeholder values
|
3530
4201
|
#
|
3531
4202
|
# resp = client.put_function_event_invoke_config({
|
@@ -3595,6 +4266,25 @@ module Aws::Lambda
|
|
3595
4266
|
# * {Types::PutProvisionedConcurrencyConfigResponse#status_reason #status_reason} => String
|
3596
4267
|
# * {Types::PutProvisionedConcurrencyConfigResponse#last_modified #last_modified} => Time
|
3597
4268
|
#
|
4269
|
+
#
|
4270
|
+
# @example Example: To allocate provisioned concurrency
|
4271
|
+
#
|
4272
|
+
# # The following example allocates 100 provisioned concurrency for the BLUE alias of the specified function.
|
4273
|
+
#
|
4274
|
+
# resp = client.put_provisioned_concurrency_config({
|
4275
|
+
# function_name: "my-function",
|
4276
|
+
# provisioned_concurrent_executions: 100,
|
4277
|
+
# qualifier: "BLUE",
|
4278
|
+
# })
|
4279
|
+
#
|
4280
|
+
# resp.to_h outputs the following:
|
4281
|
+
# {
|
4282
|
+
# allocated_provisioned_concurrent_executions: 0,
|
4283
|
+
# last_modified: Time.parse("2019-11-21T19:32:12+0000"),
|
4284
|
+
# requested_provisioned_concurrent_executions: 100,
|
4285
|
+
# status: "IN_PROGRESS",
|
4286
|
+
# }
|
4287
|
+
#
|
3598
4288
|
# @example Request syntax with placeholder values
|
3599
4289
|
#
|
3600
4290
|
# resp = client.put_provisioned_concurrency_config({
|
@@ -3645,6 +4335,17 @@ module Aws::Lambda
|
|
3645
4335
|
#
|
3646
4336
|
# @return [Struct] Returns an empty {Seahorse::Client::Response response}.
|
3647
4337
|
#
|
4338
|
+
#
|
4339
|
+
# @example Example: To delete layer-version permissions
|
4340
|
+
#
|
4341
|
+
# # The following example deletes permission for an account to configure a layer version.
|
4342
|
+
#
|
4343
|
+
# resp = client.remove_layer_version_permission({
|
4344
|
+
# layer_name: "my-layer",
|
4345
|
+
# statement_id: "xaccount",
|
4346
|
+
# version_number: 1,
|
4347
|
+
# })
|
4348
|
+
#
|
3648
4349
|
# @example Request syntax with placeholder values
|
3649
4350
|
#
|
3650
4351
|
# resp = client.remove_layer_version_permission({
|
@@ -3701,12 +4402,13 @@ module Aws::Lambda
|
|
3701
4402
|
#
|
3702
4403
|
# @example Example: To remove a Lambda function's permissions
|
3703
4404
|
#
|
3704
|
-
# #
|
4405
|
+
# # The following example removes a permissions statement named xaccount from the PROD alias of a function named
|
4406
|
+
# # my-function.
|
3705
4407
|
#
|
3706
4408
|
# resp = client.remove_permission({
|
3707
|
-
# function_name: "
|
3708
|
-
# qualifier: "
|
3709
|
-
# statement_id: "
|
4409
|
+
# function_name: "my-function",
|
4410
|
+
# qualifier: "PROD",
|
4411
|
+
# statement_id: "xaccount",
|
3710
4412
|
# })
|
3711
4413
|
#
|
3712
4414
|
# @example Request syntax with placeholder values
|
@@ -3741,6 +4443,19 @@ module Aws::Lambda
|
|
3741
4443
|
#
|
3742
4444
|
# @return [Struct] Returns an empty {Seahorse::Client::Response response}.
|
3743
4445
|
#
|
4446
|
+
#
|
4447
|
+
# @example Example: To add tags to an existing Lambda function
|
4448
|
+
#
|
4449
|
+
# # The following example adds a tag with the key name DEPARTMENT and a value of 'Department A' to the specified Lambda
|
4450
|
+
# # function.
|
4451
|
+
#
|
4452
|
+
# resp = client.tag_resource({
|
4453
|
+
# resource: "arn:aws:lambda:us-west-2:123456789012:function:my-function",
|
4454
|
+
# tags: {
|
4455
|
+
# "DEPARTMENT" => "Department A",
|
4456
|
+
# },
|
4457
|
+
# })
|
4458
|
+
#
|
3744
4459
|
# @example Request syntax with placeholder values
|
3745
4460
|
#
|
3746
4461
|
# resp = client.tag_resource({
|
@@ -3773,6 +4488,18 @@ module Aws::Lambda
|
|
3773
4488
|
#
|
3774
4489
|
# @return [Struct] Returns an empty {Seahorse::Client::Response response}.
|
3775
4490
|
#
|
4491
|
+
#
|
4492
|
+
# @example Example: To remove tags from an existing Lambda function
|
4493
|
+
#
|
4494
|
+
# # The following example removes the tag with the key name DEPARTMENT tag from the my-function Lambda function.
|
4495
|
+
#
|
4496
|
+
# resp = client.untag_resource({
|
4497
|
+
# resource: "arn:aws:lambda:us-west-2:123456789012:function:my-function",
|
4498
|
+
# tag_keys: [
|
4499
|
+
# "DEPARTMENT",
|
4500
|
+
# ],
|
4501
|
+
# })
|
4502
|
+
#
|
3776
4503
|
# @example Request syntax with placeholder values
|
3777
4504
|
#
|
3778
4505
|
# resp = client.untag_resource({
|
@@ -3841,23 +4568,33 @@ module Aws::Lambda
|
|
3841
4568
|
# * {Types::AliasConfiguration#revision_id #revision_id} => String
|
3842
4569
|
#
|
3843
4570
|
#
|
3844
|
-
# @example Example: To update a
|
4571
|
+
# @example Example: To update a function alias
|
3845
4572
|
#
|
3846
|
-
# #
|
4573
|
+
# # The following example updates the alias named BLUE to send 30% of traffic to version 2 and 70% to version 1.
|
3847
4574
|
#
|
3848
4575
|
# resp = client.update_alias({
|
3849
|
-
#
|
3850
|
-
#
|
3851
|
-
#
|
3852
|
-
#
|
4576
|
+
# function_name: "my-function",
|
4577
|
+
# function_version: "2",
|
4578
|
+
# name: "BLUE",
|
4579
|
+
# routing_config: {
|
4580
|
+
# additional_version_weights: {
|
4581
|
+
# "1" => 0.7,
|
4582
|
+
# },
|
4583
|
+
# },
|
3853
4584
|
# })
|
3854
4585
|
#
|
3855
4586
|
# resp.to_h outputs the following:
|
3856
4587
|
# {
|
3857
|
-
# alias_arn: "arn:aws:lambda:us-west-2:123456789012:function:
|
3858
|
-
# description: "",
|
3859
|
-
# function_version: "
|
3860
|
-
# name: "
|
4588
|
+
# alias_arn: "arn:aws:lambda:us-west-2:123456789012:function:my-function:BLUE",
|
4589
|
+
# description: "Production environment BLUE.",
|
4590
|
+
# function_version: "2",
|
4591
|
+
# name: "BLUE",
|
4592
|
+
# revision_id: "594f41fb-xmpl-4c20-95c7-6ca5f2a92c93",
|
4593
|
+
# routing_config: {
|
4594
|
+
# additional_version_weights: {
|
4595
|
+
# "1" => 0.7,
|
4596
|
+
# },
|
4597
|
+
# },
|
3861
4598
|
# }
|
3862
4599
|
#
|
3863
4600
|
# @example Request syntax with placeholder values
|
@@ -4144,33 +4881,33 @@ module Aws::Lambda
|
|
4144
4881
|
#
|
4145
4882
|
# @example Example: To update a Lambda function's code
|
4146
4883
|
#
|
4147
|
-
# #
|
4884
|
+
# # The following example replaces the code of the unpublished ($LATEST) version of a function named my-function with the
|
4885
|
+
# # contents of the specified zip file in Amazon S3.
|
4148
4886
|
#
|
4149
4887
|
# resp = client.update_function_code({
|
4150
|
-
# function_name: "
|
4151
|
-
#
|
4152
|
-
#
|
4153
|
-
# s3_key: "myKey",
|
4154
|
-
# s3_object_version: "1",
|
4155
|
-
# zip_file: "fileb://file-path/file.zip",
|
4888
|
+
# function_name: "my-function",
|
4889
|
+
# s3_bucket: "my-bucket-1xpuxmplzrlbh",
|
4890
|
+
# s3_key: "function.zip",
|
4156
4891
|
# })
|
4157
4892
|
#
|
4158
4893
|
# resp.to_h outputs the following:
|
4159
4894
|
# {
|
4160
|
-
# code_sha_256: "
|
4161
|
-
# code_size:
|
4895
|
+
# code_sha_256: "PFn4S+er27qk+UuZSTKEQfNKG/XNn7QJs90mJgq6oH8=",
|
4896
|
+
# code_size: 308,
|
4162
4897
|
# description: "",
|
4163
|
-
# function_arn: "arn:aws:lambda:us-
|
4164
|
-
# function_name: "
|
4898
|
+
# function_arn: "arn:aws:lambda:us-east-2:123456789012:function:my-function",
|
4899
|
+
# function_name: "my-function",
|
4165
4900
|
# handler: "index.handler",
|
4166
|
-
# last_modified: Time.parse("
|
4901
|
+
# last_modified: Time.parse("2019-08-14T22:26:11.234+0000"),
|
4167
4902
|
# memory_size: 128,
|
4168
|
-
#
|
4169
|
-
#
|
4170
|
-
#
|
4171
|
-
#
|
4172
|
-
#
|
4903
|
+
# revision_id: "873282ed-xmpl-4dc8-a069-d0c647e470c6",
|
4904
|
+
# role: "arn:aws:iam::123456789012:role/lambda-role",
|
4905
|
+
# runtime: "nodejs12.x",
|
4906
|
+
# timeout: 3,
|
4907
|
+
# tracing_config: {
|
4908
|
+
# mode: "PassThrough",
|
4173
4909
|
# },
|
4910
|
+
# version: "$LATEST",
|
4174
4911
|
# }
|
4175
4912
|
#
|
4176
4913
|
# @example Request syntax with placeholder values
|
@@ -4382,36 +5119,32 @@ module Aws::Lambda
|
|
4382
5119
|
#
|
4383
5120
|
# @example Example: To update a Lambda function's configuration
|
4384
5121
|
#
|
4385
|
-
# #
|
5122
|
+
# # The following example modifies the memory size to be 256 MB for the unpublished ($LATEST) version of a function named
|
5123
|
+
# # my-function.
|
4386
5124
|
#
|
4387
5125
|
# resp = client.update_function_configuration({
|
4388
|
-
#
|
4389
|
-
#
|
4390
|
-
# handler: "index.handler",
|
4391
|
-
# memory_size: 128,
|
4392
|
-
# role: "arn:aws:iam::123456789012:role/lambda_basic_execution",
|
4393
|
-
# runtime: "python2.7",
|
4394
|
-
# timeout: 123,
|
4395
|
-
# vpc_config: {
|
4396
|
-
# },
|
5126
|
+
# function_name: "my-function",
|
5127
|
+
# memory_size: 256,
|
4397
5128
|
# })
|
4398
5129
|
#
|
4399
5130
|
# resp.to_h outputs the following:
|
4400
5131
|
# {
|
4401
|
-
# code_sha_256: "
|
4402
|
-
# code_size:
|
5132
|
+
# code_sha_256: "PFn4S+er27qk+UuZSTKEQfNKG/XNn7QJs90mJgq6oH8=",
|
5133
|
+
# code_size: 308,
|
4403
5134
|
# description: "",
|
4404
|
-
# function_arn: "arn:aws:lambda:us-
|
4405
|
-
# function_name: "
|
5135
|
+
# function_arn: "arn:aws:lambda:us-east-2:123456789012:function:my-function",
|
5136
|
+
# function_name: "my-function",
|
4406
5137
|
# handler: "index.handler",
|
4407
|
-
# last_modified: Time.parse("
|
4408
|
-
# memory_size:
|
4409
|
-
#
|
4410
|
-
#
|
4411
|
-
#
|
4412
|
-
#
|
4413
|
-
#
|
5138
|
+
# last_modified: Time.parse("2019-08-14T22:26:11.234+0000"),
|
5139
|
+
# memory_size: 256,
|
5140
|
+
# revision_id: "873282ed-xmpl-4dc8-a069-d0c647e470c6",
|
5141
|
+
# role: "arn:aws:iam::123456789012:role/lambda-role",
|
5142
|
+
# runtime: "nodejs12.x",
|
5143
|
+
# timeout: 3,
|
5144
|
+
# tracing_config: {
|
5145
|
+
# mode: "PassThrough",
|
4414
5146
|
# },
|
5147
|
+
# version: "$LATEST",
|
4415
5148
|
# }
|
4416
5149
|
#
|
4417
5150
|
# @example Request syntax with placeholder values
|
@@ -4547,6 +5280,36 @@ module Aws::Lambda
|
|
4547
5280
|
# * {Types::FunctionEventInvokeConfig#maximum_event_age_in_seconds #maximum_event_age_in_seconds} => Integer
|
4548
5281
|
# * {Types::FunctionEventInvokeConfig#destination_config #destination_config} => Types::DestinationConfig
|
4549
5282
|
#
|
5283
|
+
#
|
5284
|
+
# @example Example: To update an asynchronous invocation configuration
|
5285
|
+
#
|
5286
|
+
# # The following example adds an on-failure destination to the existing asynchronous invocation configuration for a
|
5287
|
+
# # function named my-function.
|
5288
|
+
#
|
5289
|
+
# resp = client.update_function_event_invoke_config({
|
5290
|
+
# destination_config: {
|
5291
|
+
# on_failure: {
|
5292
|
+
# destination: "arn:aws:sqs:us-east-2:123456789012:destination",
|
5293
|
+
# },
|
5294
|
+
# },
|
5295
|
+
# function_name: "my-function",
|
5296
|
+
# })
|
5297
|
+
#
|
5298
|
+
# resp.to_h outputs the following:
|
5299
|
+
# {
|
5300
|
+
# destination_config: {
|
5301
|
+
# on_failure: {
|
5302
|
+
# destination: "arn:aws:sqs:us-east-2:123456789012:destination",
|
5303
|
+
# },
|
5304
|
+
# on_success: {
|
5305
|
+
# },
|
5306
|
+
# },
|
5307
|
+
# function_arn: "arn:aws:lambda:us-east-2:123456789012:function:my-function:$LATEST",
|
5308
|
+
# last_modified: Time.parse(1573687896.493),
|
5309
|
+
# maximum_event_age_in_seconds: 3600,
|
5310
|
+
# maximum_retry_attempts: 0,
|
5311
|
+
# }
|
5312
|
+
#
|
4550
5313
|
# @example Request syntax with placeholder values
|
4551
5314
|
#
|
4552
5315
|
# resp = client.update_function_event_invoke_config({
|
@@ -4595,7 +5358,7 @@ module Aws::Lambda
|
|
4595
5358
|
params: params,
|
4596
5359
|
config: config)
|
4597
5360
|
context[:gem_name] = 'aws-sdk-lambda'
|
4598
|
-
context[:gem_version] = '1.
|
5361
|
+
context[:gem_version] = '1.39.0'
|
4599
5362
|
Seahorse::Client::Request.new(handlers, context)
|
4600
5363
|
end
|
4601
5364
|
|