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

feat: add capability to write heap snapshot. #2611

Merged
merged 2 commits into from
Dec 8, 2022
Merged

feat: add capability to write heap snapshot. #2611

merged 2 commits into from
Dec 8, 2022

Conversation

ivarconr
Copy link
Member

@ivarconr ivarconr commented Dec 6, 2022

Is protected behind a config option called enableHeapSnapshotEnpoint. When API endpoint is triggered it will write a heapSnapshot to disk.

Steps to create heap snapshot:

  1. Add env variable ENABLE_HEAP_SNAPSHOT_ENPOINT=true.
  2. Call this endpoint: /internal-backstage/heapSnapshot
  3. Download the created heapdump from the server.

The snapshot can be loaded in the chrome dev-tool to analysis.

Is protected behind a config option called enableHeapSnapshotEnpoint.
When API endpoint is triggered it will write a heapSnapshot to disl.
@vercel
Copy link

vercel bot commented Dec 6, 2022

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated
unleash-docs ✅ Ready (Inspect) Visit Preview 💬 Add your feedback Dec 8, 2022 at 10:09AM (UTC)
unleash-monorepo-frontend ✅ Ready (Inspect) Visit Preview 💬 Add your feedback Dec 8, 2022 at 10:09AM (UTC)

Copy link
Member

@nunogois nunogois left a comment

Choose a reason for hiding this comment

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

LGTM

src/lib/routes/backstage.ts Outdated Show resolved Hide resolved
@ivarconr ivarconr merged commit d9d9f01 into main Dec 8, 2022
@ivarconr ivarconr deleted the feat/heapdump branch December 8, 2022 10:25
ivarconr added a commit that referenced this pull request Dec 9, 2022
Is protected behind a config option called `enableHeapSnapshotEnpoint`.
When API endpoint is triggered it will write a heapSnapshot to disk.

Steps to create heap snapshot:

1. Add env variable `ENABLE_HEAP_SNAPSHOT_ENPOINT=true`. 
2. Call this endpoint: `/internal-backstage/heapSnapshot`
3. Download the created heapdump from the server. 

The snapshot can be loaded in the chrome dev-tool to analysis.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Archived in project
Development

Successfully merging this pull request may close these issues.

None yet

2 participants