DEV Community

Discussion on: How to debug serverless apps

Collapse
 
embedthis profile image
Michael O'Brien

Not sure. If Lightrun can put data into CloudWatch, then SenseDeep would ingest that and trigger alarms.

Lightrun seems to be pretty intrusive requiring an agent and runtime code modification. The approach we use is 100% external to your Lambda code yes is still dynamic.

Collapse
 
codenameone profile image
Shai Almog

Yes it requires an agent but not runtime code modification. The plus side is snapshots, metrics and deep logging capabilities. Sort of like debugging a local app directly in production.

Thread Thread
 
embedthis profile image
Michael O'Brien

How does it take snapshots without VM or code modification? I've seen this technique where you use the VM debugging API but it is not without performance cost. We use EMF for metrics which works great.

Thread Thread
 
embedthis profile image
Michael O'Brien

Can you emit your log data into CloudWatch so the SenseDeep viewer & alarms could process? That would be cool.

Thread Thread
 
codenameone profile image
Shai Almog

It very much depends on the platform you're in. E.g. in Java it uses the low level native JVMTI API which we invoke from C++. The overhead when this is unused is negligible. You do pay an overhead when it's on but only for the actual snapshot/applicable code. Once the snapshot is grabbed the overhead is gone.

We have code that detects overuse of CPU and throttles down logs/conditions etc.