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: README.md
+17-10Lines changed: 17 additions & 10 deletions
Original file line number
Diff line number
Diff line change
@@ -1,8 +1,6 @@
1
1
# 
2
2
3
-
Lambda Live Debugger is an indispensable tool for debugging AWS Lambda functions from your computer, even though they are deployed in the cloud. It supports Lambdas written in JavaScript or TypeScript. It is free and open source.
4
-
5
-
This tool offers similar functionality to [SST](https://sst.dev/) and [Serverless Framework v4](https://www.serverless.com/blog/serverless-framework-v4-general-availability), with the addition of an Observability Mode.
3
+
Lambda Live Debugger is an indispensable tool for debugging AWS Lambda functions from your computer, even though they are deployed in the cloud. The code runs with the same IAM permissions as in the cloud environment, and there's no need to redeploy when you make code changes. It supports Lambdas written in JavaScript or TypeScript. It requires almost no configuration. It is free and open source.
6
4
7
5
It supports the following frameworks:
8
6
@@ -15,16 +13,16 @@ It supports the following frameworks:
15
13
16
14
[](https://www.youtube.com/watch?v=BrhybwyDM0I)
17
15
18
-
## Why?
19
-
20
-
Serverless is amazing and solves many issues with traditional systems. However, writing code for Lambda functions can be challenging. The cycle of writing, deploying, running, fixing, and redeploying is time-consuming and tedious. You could use tools to run Lambda locally or use unit/integration tests; those approaches often don't replicate the actual environment closely enough.
21
-
22
-
Lambda Live Debugger provides several features that aren't supported by SST or Serverless Framework v4:
16
+
It offers similar functionality to [SST](https://sst.dev/) and [Serverless Framework v4](https://www.serverless.com/blog/serverless-framework-v4-general-availability), with the following addition features:
23
17
24
18
-**Observability mode** – Enables debugging without impacting the system, so it can even be used in production.
25
19
-**Quick toggle** – Debug mode can be turned off and back on almost instantly without requiring a redeploy like other solutions.
26
20
-**Selective debugging** – You can debug only one or a few functions at a time, which is crucial for large and complex systems. Running many Lambdas simultaneously on a single machine can be confusing and can slow down your computer.
27
21
22
+
## Why?
23
+
24
+
Serverless is amazing and solves many issues with traditional systems. However, writing code for Lambda functions can be challenging. The cycle of writing, deploying, running, fixing, and redeploying is time-consuming and tedious. You could use tools to run Lambda locally or use unit/integration tests; those approaches often don't replicate the actual environment closely enough.
25
+
28
26
## How It Works
29
27
30
28
Lambda Live Debugger connects to your deployed Lambda, routes requests to your computer, and sends responses back to the deployed Lambda. This allows you to debug locally, but the system behaves as if the code is running in the cloud with the same permissions. In case of code changes, you do not have to redeploy. The code is reloaded automatically without deploying or even restarting the debugger.
@@ -33,7 +31,7 @@ The tool attaches Lambda Extensions (via a Layer), intercepts, and relays calls
33
31
34
32

35
33
36
-
AWS keys generated on the cloud for Lambda are transferred to the local environment, so the code has the same permissions as it would executed on the cloud. There could be a difference in packaging, mainly regarding static files, which are probably in different locations. You can use additional environment variables to adjust the code:
34
+
AWS keys generated on the cloud for Lambda are transferred to the local environment, so the code has the same IAM permissions as it would executed on the cloud. There could be a difference in packaging, mainly regarding static files, which are probably in different locations. You can use additional environment variables to adjust the code:
37
35
38
36
-`IS_LOCAL = true` = Lambda is executed locally
39
37
-`LOCAL_PROJECT_DIR` = directory of the project
@@ -193,6 +191,8 @@ To also remove the Layer:
193
191
lld -r=all
194
192
```
195
193
194
+
**Note:** Be sure to remove Lambda Live Debugger after use in a high-traffic environment—otherwise, IoT messages could generate significant costs.
195
+
196
196
## Development Process
197
197
198
198
Since you deploy code to a real AWS account, it's best to have a dedicated environment only for yourself. It could be your personal environment or an environment created for a feature. That is [common practice when developing serverless systems](https://theburningmonk.com/2019/09/why-you-should-use-temporary-stacks-when-you-do-serverless/). If that's not feasible due to organizational or technical reasons, use Observability Mode.
@@ -201,6 +201,8 @@ Since you deploy code to a real AWS account, it's best to have a dedicated envir
201
201
202
202
In Observability Mode, Lambda Live Debugger intercepts requests and sends them to your computer without waiting for a response. The Lambda continues as usual. The response from your machine is ignored. This mode can be used in the development, testing, or even, if you are adventurous, production environment. It samples requests every 3 seconds by default (configurable with an `interval` setting) to avoid overloading the system.
203
203
204
+
**Note:** Be sure to remove Lambda Live Debugger after use in a high-traffic environment—otherwise, IoT messages could generate significant costs.
205
+
204
206
## Monorepo Setup
205
207
206
208
Set the `subfolder` parameter if your framework is in a subfolder.
@@ -219,7 +221,12 @@ _Serverless, Inc. has deprecated Serverless Framework v3, and v4 is available un
219
221
220
222
### AWS Serverless Application Model (SAM)
221
223
222
-
Use the `config-env` parameter to pass the stage/environment name.
0 commit comments