Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

@datadog/pprof

Package Overview
Dependencies
Maintainers
1
Versions
72
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@datadog/pprof

pprof support for Node.js

  • 6.0.0-pre-918c1bd
  • Source
  • npm
  • Socket score

Version published
Weekly downloads
2.9M
increased by0.21%
Maintainers
1
Weekly downloads
 
Created

What is @datadog/pprof?

The @datadog/pprof package is a Node.js module provided by Datadog for profiling Node.js applications. It allows developers to generate and analyze CPU and heap profiles to understand the performance characteristics of their applications and identify bottlenecks or memory leaks.

What are @datadog/pprof's main functionalities?

CPU Profiling

This feature enables CPU profiling, allowing developers to understand where their application spends most of its execution time. The code sample demonstrates how to start CPU profiling with a specified duration and sampling rate.

const profiler = require('@datadog/pprof');
profiler.start({
  service: 'my-service',
  // 10 minutes profiling duration
  duration: 600,
  // Profile CPU every 1000 milliseconds
  sampleRate: 1000
});

Heap Profiling

Heap profiling helps in identifying memory leaks and understanding memory allocation patterns. The code sample shows how to start heap profiling with a specified interval between snapshots.

const profiler = require('@datadog/pprof');
profiler.heap.start({
  service: 'my-service',
  // Take a snapshot every 600 seconds
  snapshotInterval: 600
});

Other packages similar to @datadog/pprof

FAQs

Package last updated on 13 May 2024

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc