Talk at Node+JS Interactive 2019
Memory Chronicles: Manage,Trace and Fix Memory LeaksGiovanny Gongora@Gioyik
View Slide
Giovanny[email protected]@gioyik
© 2019 NodeSourceWhat is this really?
© 2019 NodeSourceSee you at 2pm!
Who had a memory issue witha Node.js application before?
It happens in real life, happensin TNT
Heap profiler & Timeline
When to use them?
Workflow for diagnosingmemory leaks?
TST
Three Snapshot Technique
What do the Shallow andRetained Size columns represent?
Where should I start digginginto to discover if I have a leak?
Redacted snapshots
Core Dumps
Create a Core dump
--abort-on-uncaught-exception
LLDB
Llnode
Caveats
llnode’s coupling to V8
Promises (?)
Async / Await FTW!
Tips for different situations
Case #1:Server Side Rendering (SSR)
Case #2:Monitoring tools
Case #3Close your connections
Case #4:Look for agnostic serve pages solution
Case #5:Review you packages
Case #6:Keep naming you functions
Case #6:Check how reliable are your 3rd services
Crazy … right?
Thank you!