@aws-sdk/client-lambda 3.218.0 → 3.222.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (29) hide show
  1. package/dist-cjs/endpoint/ruleset.js +1 -1
  2. package/dist-cjs/models/models_0.js +90 -4
  3. package/dist-cjs/protocols/Aws_restJson1.js +83 -0
  4. package/dist-cjs/waiters/index.js +1 -0
  5. package/dist-cjs/waiters/waitForPublishedVersionActive.js +54 -0
  6. package/dist-es/endpoint/ruleset.js +1 -1
  7. package/dist-es/models/models_0.js +81 -0
  8. package/dist-es/protocols/Aws_restJson1.js +84 -1
  9. package/dist-es/waiters/index.js +1 -0
  10. package/dist-es/waiters/waitForPublishedVersionActive.js +49 -0
  11. package/dist-types/Lambda.d.ts +77 -80
  12. package/dist-types/commands/AddPermissionCommand.d.ts +13 -13
  13. package/dist-types/commands/CreateFunctionCommand.d.ts +26 -27
  14. package/dist-types/commands/DeleteFunctionCommand.d.ts +2 -3
  15. package/dist-types/commands/InvokeCommand.d.ts +10 -8
  16. package/dist-types/commands/ListFunctionsCommand.d.ts +4 -4
  17. package/dist-types/commands/PutFunctionConcurrencyCommand.d.ts +1 -1
  18. package/dist-types/commands/RemovePermissionCommand.d.ts +2 -2
  19. package/dist-types/commands/UpdateFunctionCodeCommand.d.ts +12 -15
  20. package/dist-types/commands/UpdateFunctionConfigurationCommand.d.ts +7 -7
  21. package/dist-types/endpoint/EndpointParameters.d.ts +1 -1
  22. package/dist-types/models/models_0.d.ts +339 -209
  23. package/dist-types/ts3.4/endpoint/EndpointParameters.d.ts +1 -1
  24. package/dist-types/ts3.4/models/models_0.d.ts +70 -0
  25. package/dist-types/ts3.4/waiters/index.d.ts +1 -0
  26. package/dist-types/ts3.4/waiters/waitForPublishedVersionActive.d.ts +11 -0
  27. package/dist-types/waiters/index.d.ts +1 -0
  28. package/dist-types/waiters/waitForPublishedVersionActive.d.ts +14 -0
  29. package/package.json +30 -29
@@ -27,7 +27,7 @@ export declare const resolveClientEndpointParameters: <T>(
27
27
  defaultSigningName: string;
28
28
  };
29
29
  export interface EndpointParameters extends __EndpointParameters {
30
- Region?: string;
30
+ Region: string;
31
31
  UseDualStack?: boolean;
32
32
  UseFIPS?: boolean;
33
33
  Endpoint?: string;
@@ -76,6 +76,7 @@ export declare class ServiceException extends __BaseException {
76
76
  export declare enum ThrottleReason {
77
77
  CallerRateLimitExceeded = "CallerRateLimitExceeded",
78
78
  ConcurrentInvocationLimitExceeded = "ConcurrentInvocationLimitExceeded",
79
+ ConcurrentSnapshotCreateLimitExceeded = "ConcurrentSnapshotCreateLimitExceeded",
79
80
  FunctionInvocationRateLimitExceeded = "FunctionInvocationRateLimitExceeded",
80
81
  ReservedFunctionConcurrentInvocationLimitExceeded = "ReservedFunctionConcurrentInvocationLimitExceeded",
81
82
  ReservedFunctionInvocationRateLimitExceeded = "ReservedFunctionInvocationRateLimitExceeded",
@@ -349,6 +350,13 @@ export declare enum Runtime {
349
350
  ruby25 = "ruby2.5",
350
351
  ruby27 = "ruby2.7",
351
352
  }
353
+ export declare enum SnapStartApplyOn {
354
+ None = "None",
355
+ PublishedVersions = "PublishedVersions",
356
+ }
357
+ export interface SnapStart {
358
+ ApplyOn?: SnapStartApplyOn | string;
359
+ }
352
360
  export declare enum TracingMode {
353
361
  Active = "Active",
354
362
  PassThrough = "PassThrough",
@@ -383,6 +391,7 @@ export interface CreateFunctionRequest {
383
391
  CodeSigningConfigArn?: string;
384
392
  Architectures?: (Architecture | string)[];
385
393
  EphemeralStorage?: EphemeralStorage;
394
+ SnapStart?: SnapStart;
386
395
  }
387
396
  export interface EnvironmentError {
388
397
  ErrorCode?: string;
@@ -406,15 +415,26 @@ export declare enum LastUpdateStatus {
406
415
  Successful = "Successful",
407
416
  }
408
417
  export declare enum LastUpdateStatusReasonCode {
418
+ DisabledKMSKey = "DisabledKMSKey",
419
+ EFSIOError = "EFSIOError",
420
+ EFSMountConnectivityError = "EFSMountConnectivityError",
421
+ EFSMountFailure = "EFSMountFailure",
422
+ EFSMountTimeout = "EFSMountTimeout",
409
423
  EniLimitExceeded = "EniLimitExceeded",
424
+ FunctionError = "FunctionError",
410
425
  ImageAccessDenied = "ImageAccessDenied",
411
426
  ImageDeleted = "ImageDeleted",
412
427
  InsufficientRolePermissions = "InsufficientRolePermissions",
413
428
  InternalError = "InternalError",
414
429
  InvalidConfiguration = "InvalidConfiguration",
415
430
  InvalidImage = "InvalidImage",
431
+ InvalidRuntime = "InvalidRuntime",
416
432
  InvalidSecurityGroup = "InvalidSecurityGroup",
433
+ InvalidStateKMSKey = "InvalidStateKMSKey",
417
434
  InvalidSubnet = "InvalidSubnet",
435
+ InvalidZipFileException = "InvalidZipFileException",
436
+ KMSKeyAccessDenied = "KMSKeyAccessDenied",
437
+ KMSKeyNotFound = "KMSKeyNotFound",
418
438
  SubnetOutOfIPAddresses = "SubnetOutOfIPAddresses",
419
439
  }
420
440
  export interface Layer {
@@ -423,6 +443,14 @@ export interface Layer {
423
443
  SigningProfileVersionArn?: string;
424
444
  SigningJobArn?: string;
425
445
  }
446
+ export declare enum SnapStartOptimizationStatus {
447
+ Off = "Off",
448
+ On = "On",
449
+ }
450
+ export interface SnapStartResponse {
451
+ ApplyOn?: SnapStartApplyOn | string;
452
+ OptimizationStatus?: SnapStartOptimizationStatus | string;
453
+ }
426
454
  export declare enum State {
427
455
  Active = "Active",
428
456
  Failed = "Failed",
@@ -431,7 +459,13 @@ export declare enum State {
431
459
  }
432
460
  export declare enum StateReasonCode {
433
461
  Creating = "Creating",
462
+ DisabledKMSKey = "DisabledKMSKey",
463
+ EFSIOError = "EFSIOError",
464
+ EFSMountConnectivityError = "EFSMountConnectivityError",
465
+ EFSMountFailure = "EFSMountFailure",
466
+ EFSMountTimeout = "EFSMountTimeout",
434
467
  EniLimitExceeded = "EniLimitExceeded",
468
+ FunctionError = "FunctionError",
435
469
  Idle = "Idle",
436
470
  ImageAccessDenied = "ImageAccessDenied",
437
471
  ImageDeleted = "ImageDeleted",
@@ -439,8 +473,13 @@ export declare enum StateReasonCode {
439
473
  InternalError = "InternalError",
440
474
  InvalidConfiguration = "InvalidConfiguration",
441
475
  InvalidImage = "InvalidImage",
476
+ InvalidRuntime = "InvalidRuntime",
442
477
  InvalidSecurityGroup = "InvalidSecurityGroup",
478
+ InvalidStateKMSKey = "InvalidStateKMSKey",
443
479
  InvalidSubnet = "InvalidSubnet",
480
+ InvalidZipFileException = "InvalidZipFileException",
481
+ KMSKeyAccessDenied = "KMSKeyAccessDenied",
482
+ KMSKeyNotFound = "KMSKeyNotFound",
444
483
  Restoring = "Restoring",
445
484
  SubnetOutOfIPAddresses = "SubnetOutOfIPAddresses",
446
485
  }
@@ -486,6 +525,7 @@ export interface FunctionConfiguration {
486
525
  SigningJobArn?: string;
487
526
  Architectures?: (Architecture | string)[];
488
527
  EphemeralStorage?: EphemeralStorage;
528
+ SnapStart?: SnapStartResponse;
489
529
  }
490
530
  export declare class InvalidCodeSignatureException extends __BaseException {
491
531
  readonly name: "InvalidCodeSignatureException";
@@ -903,6 +943,31 @@ export declare class ResourceNotReadyException extends __BaseException {
903
943
  opts: __ExceptionOptionType<ResourceNotReadyException, __BaseException>
904
944
  );
905
945
  }
946
+ export declare class SnapStartException extends __BaseException {
947
+ readonly name: "SnapStartException";
948
+ readonly $fault: "client";
949
+ Type?: string;
950
+ Message?: string;
951
+ constructor(opts: __ExceptionOptionType<SnapStartException, __BaseException>);
952
+ }
953
+ export declare class SnapStartNotReadyException extends __BaseException {
954
+ readonly name: "SnapStartNotReadyException";
955
+ readonly $fault: "client";
956
+ Type?: string;
957
+ Message?: string;
958
+ constructor(
959
+ opts: __ExceptionOptionType<SnapStartNotReadyException, __BaseException>
960
+ );
961
+ }
962
+ export declare class SnapStartTimeoutException extends __BaseException {
963
+ readonly name: "SnapStartTimeoutException";
964
+ readonly $fault: "client";
965
+ Type?: string;
966
+ Message?: string;
967
+ constructor(
968
+ opts: __ExceptionOptionType<SnapStartTimeoutException, __BaseException>
969
+ );
970
+ }
906
971
  export declare class SubnetIPAddressLimitReachedException extends __BaseException {
907
972
  readonly name: "SubnetIPAddressLimitReachedException";
908
973
  readonly $fault: "server";
@@ -1220,6 +1285,7 @@ export interface UpdateFunctionConfigurationRequest {
1220
1285
  FileSystemConfigs?: FileSystemConfig[];
1221
1286
  ImageConfig?: ImageConfig;
1222
1287
  EphemeralStorage?: EphemeralStorage;
1288
+ SnapStart?: SnapStart;
1223
1289
  }
1224
1290
  export interface UpdateFunctionEventInvokeConfigRequest {
1225
1291
  FunctionName: string | undefined;
@@ -1319,6 +1385,7 @@ export declare const FileSystemConfigFilterSensitiveLog: (
1319
1385
  obj: FileSystemConfig
1320
1386
  ) => any;
1321
1387
  export declare const ImageConfigFilterSensitiveLog: (obj: ImageConfig) => any;
1388
+ export declare const SnapStartFilterSensitiveLog: (obj: SnapStart) => any;
1322
1389
  export declare const TracingConfigFilterSensitiveLog: (
1323
1390
  obj: TracingConfig
1324
1391
  ) => any;
@@ -1339,6 +1406,9 @@ export declare const ImageConfigResponseFilterSensitiveLog: (
1339
1406
  obj: ImageConfigResponse
1340
1407
  ) => any;
1341
1408
  export declare const LayerFilterSensitiveLog: (obj: Layer) => any;
1409
+ export declare const SnapStartResponseFilterSensitiveLog: (
1410
+ obj: SnapStartResponse
1411
+ ) => any;
1342
1412
  export declare const TracingConfigResponseFilterSensitiveLog: (
1343
1413
  obj: TracingConfigResponse
1344
1414
  ) => any;
@@ -3,3 +3,4 @@ export * from "./waitForFunctionActiveV2";
3
3
  export * from "./waitForFunctionExists";
4
4
  export * from "./waitForFunctionUpdated";
5
5
  export * from "./waitForFunctionUpdatedV2";
6
+ export * from "./waitForPublishedVersionActive";
@@ -0,0 +1,11 @@
1
+ import { WaiterConfiguration, WaiterResult } from "@aws-sdk/util-waiter";
2
+ import { GetFunctionConfigurationCommandInput } from "../commands/GetFunctionConfigurationCommand";
3
+ import { LambdaClient } from "../LambdaClient";
4
+ export declare const waitForPublishedVersionActive: (
5
+ params: WaiterConfiguration<LambdaClient>,
6
+ input: GetFunctionConfigurationCommandInput
7
+ ) => Promise<WaiterResult>;
8
+ export declare const waitUntilPublishedVersionActive: (
9
+ params: WaiterConfiguration<LambdaClient>,
10
+ input: GetFunctionConfigurationCommandInput
11
+ ) => Promise<WaiterResult>;
@@ -3,3 +3,4 @@ export * from "./waitForFunctionActiveV2";
3
3
  export * from "./waitForFunctionExists";
4
4
  export * from "./waitForFunctionUpdated";
5
5
  export * from "./waitForFunctionUpdatedV2";
6
+ export * from "./waitForPublishedVersionActive";
@@ -0,0 +1,14 @@
1
+ import { WaiterConfiguration, WaiterResult } from "@aws-sdk/util-waiter";
2
+ import { GetFunctionConfigurationCommandInput } from "../commands/GetFunctionConfigurationCommand";
3
+ import { LambdaClient } from "../LambdaClient";
4
+ /**
5
+ * Waits for the published version's State to be Active. This waiter uses GetFunctionConfiguration API. This should be used after new version is published.
6
+ * @deprecated Use waitUntilPublishedVersionActive instead. waitForPublishedVersionActive does not throw error in non-success cases.
7
+ */
8
+ export declare const waitForPublishedVersionActive: (params: WaiterConfiguration<LambdaClient>, input: GetFunctionConfigurationCommandInput) => Promise<WaiterResult>;
9
+ /**
10
+ * Waits for the published version's State to be Active. This waiter uses GetFunctionConfiguration API. This should be used after new version is published.
11
+ * @param params - Waiter configuration options.
12
+ * @param input - The input to GetFunctionConfigurationCommand for polling.
13
+ */
14
+ export declare const waitUntilPublishedVersionActive: (params: WaiterConfiguration<LambdaClient>, input: GetFunctionConfigurationCommandInput) => Promise<WaiterResult>;
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@aws-sdk/client-lambda",
3
3
  "description": "AWS SDK for JavaScript Lambda Client for Node.js, Browser and React Native",
4
- "version": "3.218.0",
4
+ "version": "3.222.0",
5
5
  "scripts": {
6
6
  "build": "concurrently 'yarn:build:cjs' 'yarn:build:es' 'yarn:build:types'",
7
7
  "build:cjs": "tsc -p tsconfig.cjs.json",
@@ -19,39 +19,40 @@
19
19
  "dependencies": {
20
20
  "@aws-crypto/sha256-browser": "2.0.0",
21
21
  "@aws-crypto/sha256-js": "2.0.0",
22
- "@aws-sdk/client-sts": "3.218.0",
23
- "@aws-sdk/config-resolver": "3.215.0",
24
- "@aws-sdk/credential-provider-node": "3.218.0",
25
- "@aws-sdk/fetch-http-handler": "3.215.0",
26
- "@aws-sdk/hash-node": "3.215.0",
27
- "@aws-sdk/invalid-dependency": "3.215.0",
28
- "@aws-sdk/middleware-content-length": "3.215.0",
29
- "@aws-sdk/middleware-endpoint": "3.215.0",
30
- "@aws-sdk/middleware-host-header": "3.215.0",
31
- "@aws-sdk/middleware-logger": "3.215.0",
32
- "@aws-sdk/middleware-recursion-detection": "3.215.0",
33
- "@aws-sdk/middleware-retry": "3.215.0",
34
- "@aws-sdk/middleware-serde": "3.215.0",
35
- "@aws-sdk/middleware-signing": "3.215.0",
36
- "@aws-sdk/middleware-stack": "3.215.0",
37
- "@aws-sdk/middleware-user-agent": "3.215.0",
38
- "@aws-sdk/node-config-provider": "3.215.0",
39
- "@aws-sdk/node-http-handler": "3.215.0",
40
- "@aws-sdk/protocol-http": "3.215.0",
41
- "@aws-sdk/smithy-client": "3.215.0",
42
- "@aws-sdk/types": "3.215.0",
43
- "@aws-sdk/url-parser": "3.215.0",
22
+ "@aws-sdk/client-sts": "3.222.0",
23
+ "@aws-sdk/config-resolver": "3.222.0",
24
+ "@aws-sdk/credential-provider-node": "3.222.0",
25
+ "@aws-sdk/fetch-http-handler": "3.222.0",
26
+ "@aws-sdk/hash-node": "3.222.0",
27
+ "@aws-sdk/invalid-dependency": "3.222.0",
28
+ "@aws-sdk/middleware-content-length": "3.222.0",
29
+ "@aws-sdk/middleware-endpoint": "3.222.0",
30
+ "@aws-sdk/middleware-host-header": "3.222.0",
31
+ "@aws-sdk/middleware-logger": "3.222.0",
32
+ "@aws-sdk/middleware-recursion-detection": "3.222.0",
33
+ "@aws-sdk/middleware-retry": "3.222.0",
34
+ "@aws-sdk/middleware-serde": "3.222.0",
35
+ "@aws-sdk/middleware-signing": "3.222.0",
36
+ "@aws-sdk/middleware-stack": "3.222.0",
37
+ "@aws-sdk/middleware-user-agent": "3.222.0",
38
+ "@aws-sdk/node-config-provider": "3.222.0",
39
+ "@aws-sdk/node-http-handler": "3.222.0",
40
+ "@aws-sdk/protocol-http": "3.222.0",
41
+ "@aws-sdk/smithy-client": "3.222.0",
42
+ "@aws-sdk/types": "3.222.0",
43
+ "@aws-sdk/url-parser": "3.222.0",
44
44
  "@aws-sdk/util-base64": "3.208.0",
45
45
  "@aws-sdk/util-body-length-browser": "3.188.0",
46
46
  "@aws-sdk/util-body-length-node": "3.208.0",
47
- "@aws-sdk/util-defaults-mode-browser": "3.215.0",
48
- "@aws-sdk/util-defaults-mode-node": "3.215.0",
49
- "@aws-sdk/util-endpoints": "3.216.0",
50
- "@aws-sdk/util-user-agent-browser": "3.215.0",
51
- "@aws-sdk/util-user-agent-node": "3.215.0",
47
+ "@aws-sdk/util-defaults-mode-browser": "3.222.0",
48
+ "@aws-sdk/util-defaults-mode-node": "3.222.0",
49
+ "@aws-sdk/util-endpoints": "3.222.0",
50
+ "@aws-sdk/util-retry": "3.222.0",
51
+ "@aws-sdk/util-user-agent-browser": "3.222.0",
52
+ "@aws-sdk/util-user-agent-node": "3.222.0",
52
53
  "@aws-sdk/util-utf8-browser": "3.188.0",
53
54
  "@aws-sdk/util-utf8-node": "3.208.0",
54
- "@aws-sdk/util-waiter": "3.215.0",
55
+ "@aws-sdk/util-waiter": "3.222.0",
55
56
  "tslib": "^2.3.1"
56
57
  },
57
58
  "devDependencies": {