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 - npm Package Compare versions

Comparing version 4.0.0-pre-05c5dd4 to 4.0.0-pre-2f3b78c

prebuilds/darwin-arm64/node-120.node

4

out/src/profile-serializer.d.ts

@@ -18,3 +18,3 @@ /**

import { SourceMapper } from './sourcemapper/sourcemapper';
import { AllocationProfileNode, LabelSet, TimeProfile } from './v8-types';
import { AllocationProfileNode, LabelSet, TimeProfile, TimeProfileNodeContext } from './v8-types';
/**

@@ -27,3 +27,3 @@ * Converts v8 time profile into into a profile proto.

*/
export declare function serializeTimeProfile(prof: TimeProfile, intervalMicros: number, sourceMapper?: SourceMapper, recomputeSamplingInterval?: boolean, generateLabels?: (context: object) => LabelSet): Profile;
export declare function serializeTimeProfile(prof: TimeProfile, intervalMicros: number, sourceMapper?: SourceMapper, recomputeSamplingInterval?: boolean, generateLabels?: (context: TimeProfileNodeContext) => LabelSet): Profile;
/**

@@ -30,0 +30,0 @@ * Converts v8 heap profile into into a profile proto.

@@ -186,3 +186,3 @@ "use strict";

for (const context of entry.node.contexts || []) {
const labels = generateLabels ? generateLabels(context) : context;
const labels = generateLabels ? generateLabels(context) : context.context;
if (Object.keys(labels).length > 0) {

@@ -223,12 +223,17 @@ const sample = new pprof_format_1.Sample({

for (const [key, value] of Object.entries(labelSet)) {
if (typeof value === 'number' || typeof value === 'string') {
const label = new pprof_format_1.Label({
key: stringTable.dedup(key),
num: typeof value === 'number' ? value : undefined,
str: typeof value === 'string'
? stringTable.dedup(value)
: undefined,
});
labels.push(label);
const labelInput = {
key: stringTable.dedup(key),
};
switch (typeof value) {
case 'string':
labelInput.str = stringTable.dedup(value);
break;
case 'number':
case 'bigint':
labelInput.num = value;
break;
default:
continue;
}
labels.push(new pprof_format_1.Label(labelInput));
}

@@ -235,0 +240,0 @@ return labels;

@@ -17,3 +17,3 @@ /**

import { SourceMapper } from './sourcemapper/sourcemapper';
import { LabelSet } from './v8-types';
import { LabelSet, TimeProfileNodeContext } from './v8-types';
type Microseconds = number;

@@ -39,3 +39,3 @@ type Milliseconds = number;

export declare function start({ intervalMicros, durationMillis, sourceMapper, lineNumbers, withContexts, workaroundV8Bug, }: TimeProfilerOptions): void;
export declare function stop(restart?: boolean, generateLabels?: (context: object) => LabelSet): import("pprof-format").Profile;
export declare function stop(restart?: boolean, generateLabels?: (context: TimeProfileNodeContext) => LabelSet): import("pprof-format").Profile;
export declare function getState(): any;

@@ -42,0 +42,0 @@ export declare function setContext(context?: object): void;

@@ -31,5 +31,9 @@ /**

}
export interface TimeProfileNodeContext {
context: object;
timestamp: bigint;
}
export interface TimeProfileNode extends ProfileNode {
hitCount: number;
contexts?: object[];
contexts?: TimeProfileNodeContext[];
}

@@ -36,0 +40,0 @@ export interface AllocationProfileNode extends ProfileNode {

{
"name": "@datadog/pprof",
"version": "4.0.0-pre-05c5dd4",
"version": "4.0.0-pre-2f3b78c",
"description": "pprof support for Node.js",

@@ -50,3 +50,3 @@ "repository": "datadog/pprof-nodejs",

"mocha": "^10.2.0",
"nan": "^2.17.0",
"nan": "^2.18.0",
"nyc": "^15.1.0",

@@ -53,0 +53,0 @@ "sinon": "^15.2.0",

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

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