-
Book Overview & Buying
-
Table Of Contents
-
Feedback & Rating

AWS Certified DevOps Engineer - Professional Certification and Beyond
By :

A Lambda layer is a pre-published collection of code dependencies and libraries. If you find that you (or you, as a team) are using the same snippets of code in multiple functions, you can create a layer to get the benefits of Lambda layers. First, when there is a change to one of the dependencies, you no longer have to update each of the functions; instead, you only maintain a single layer that all the functions can take advantage of and only needs to be maintained one time:
Figure 12.7 – Lambda functions with and without layers
Layers are a great way to speed up development between teams. Shared functionality such as logging, networking, or even database connectivity can be programmed and packaged into a layer once and then called from individual functions.
We already have a Lambda function from our previous exercise. Now, let's expand the functionality of our function...