NetEase Cloud Music Tech Team
Mar 17, 2021 · Backend Development
Analyzing Node.js .heapsnapshot Files and Using heapquery for Memory‑Leak Investigation
The article shows how to generate a Node.js V8 heap snapshot with v8.getHeapSnapshot, explains the JSON‑like .heapsnapshot structure of nodes, edges, and strings, and demonstrates using the heapquery tool to import the data into SQLite for SQL queries that locate and trace memory‑leaking objects such as a HugeObj instance.
HeapSnapshotNode.jsSQL
0 likes · 17 min read
