You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: versions/2016-10-31.md
+37-1Lines changed: 37 additions & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -30,6 +30,7 @@ In order to include objects defined by AWS SAM within a CloudFormation template,
30
30
-[Resource types](#resource-types)
31
31
-[Event source types](#event-source-types)
32
32
-[Property types](#property-types)
33
+
-[Globals Section](#globals-section)
33
34
34
35
35
36
### Example: AWS SAM template
@@ -48,6 +49,24 @@ Resources:
48
49
49
50
All property names in AWS SAM are **case sensitive**.
50
51
52
+
### Globals Section
53
+
Lambda functions within a SAM template tend to have shared configuration such as Runtime, Memory, VPC Settings, Environment Variables etc. Instead of duplicating this information in every function, you can write them once in the Globals section and let all Functions inhert it.
54
+
55
+
Example:
56
+
57
+
```
58
+
Globals:
59
+
Function:
60
+
Runtime: nodejs6.10
61
+
Timeout: 180
62
+
Handler: index.handler
63
+
Environment:
64
+
Variables:
65
+
TABLE_NAME: data-table
66
+
```
67
+
68
+
Read the [Globals Guide](../docs/globals.rst) for more detailed information.
@@ -77,7 +96,7 @@ Tags | Map of `string` to `string` | A map (string to string) that specifies the
77
96
Tracing | `string` | String that specifies the function's [X-Ray tracing mode](http://docs.aws.amazon.com/lambda/latest/dg/lambda-x-ray.html). Accepted values are `Active` and `PassThrough`
78
97
KmsKeyArn | `string` | The Amazon Resource Name (ARN) of an AWS Key Management Service (AWS KMS) key that Lambda uses to encrypt and decrypt your function's environment variables.
79
98
DeadLetterQueue | `map` <span>|</span> [DeadLetterQueue Object](#deadletterqueue-object) | Configures SNS topic or SQS queue where Lambda sends events that it can't process.
DeploymentPreference | [DeploymentPreference Object](#deploymentpreference-object) | Settings to enable Safe Lambda Deployments. Read the [usage guide](../docs/safe_lambda_deployments.rst) for detailed information.
81
100
AutoPublishAlias | `string` | Name of the Alias. Read [AutoPublishAlias Guide](../docs/safe_lambda_deployments.rst#instant-traffic-shifting-using-lambda-aliases) for how it works
82
101
83
102
##### Return values
@@ -487,3 +506,20 @@ DeadLetterQueue:
487
506
Type: `SQS` or `SNS`
488
507
TargetArn: ARN of the SQS queue or SNS topic to use as DLQ.
489
508
```
509
+
510
+
#### DeploymentPreference Object
511
+
Specifies the configurations to enable Safe Lambda Deployments. Read the [usage guide](../docs/safe_lambda_deployments.rst) for detailed information. The following shows all available properties of this object
0 commit comments