Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

doc: add document for profile and takeHeapSnapshot command of node inspect #43018

Closed
wants to merge 1 commit into from

Conversation

cola119
Copy link
Member

@cola119 cola119 commented May 9, 2022

Currently profile and takeHeapSnapshot command are undocumented in the debugger doc.

profile Start CPU profiling session.
profileEnd Stop current CPU profiling session.
profiles Array of completed CPU profiling sessions.
profiles[n].save(filepath = 'node.cpuprofile')
Save CPU profiling session to disk as JSON.
takeHeapSnapshot(filepath = 'node.heapsnapshot')
Take a heap snapshot and save to disk as JSON.

@nodejs-github-bot nodejs-github-bot added debugger Issues and PRs related to the debugger subsystem. doc Issues and PRs related to the documentations. labels May 9, 2022
Trott
Trott previously requested changes May 9, 2022
Copy link
Member

@Trott Trott left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

One question about the unwatch addition....

doc/api/debugger.md Outdated Show resolved Hide resolved
@Trott
Copy link
Member

Trott commented May 9, 2022

@nodejs/documentation I think this is fine, but it does deviate from our usual docs (using default parameter syntax rather than **Default:**, although this is an unusual case and previous elements in the list already deviate from the standard approach). Since this isn't a programmatic API but an interactive REPL, I think it's fine. What do you think?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
debugger Issues and PRs related to the debugger subsystem. doc Issues and PRs related to the documentations.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants