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

dtrace-provider

Package Overview
Dependencies
Maintainers
1
Versions
35
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

dtrace-provider - npm Package Compare versions

Comparing version 0.2.4 to 0.2.5

dtrace_argument.cc

7

CHANGES.md

@@ -6,2 +6,9 @@ dtrace-provider - Changes

* 0.2.5:
Add "json" probe argument type, automatically serialising objects as JSON
Trust npm to set PATH appropriately when invoking node (reported by Dave Pacheco)
libusdt update - allow provider memory to be freed (reported by Bryan Cantrill)
Build libusdt with gmake by default (reported by Keith Wesolowski)
Turn the various scripts in test/ into a TAP-based testsuite.
* 0.2.4:

@@ -8,0 +15,0 @@ Improve Node architecture detection to support 0.6.x, and respect

30

package.json
{
"name" : "dtrace-provider",
"version" : "0.2.4",
"description" : "Native DTrace providers for node.js applications",
"keywords" : ["dtrace"],
"homepage" : "https://github.com/chrisa/node-dtrace-provider#readme",
"author" : { "name" : "Chris Andrews", "email": "chris@nodnol.org" },
"main" : "./dtrace-provider.js",
"repository" : { "type" : "git", "url" : "http://github.com/chrisa/node-dtrace-provider.git" },
"engines": { "node" : ">=0.6" }
"name" : "dtrace-provider",
"version" : "0.2.5",
"description" : "Native DTrace providers for node.js applications",
"keywords" : ["dtrace"],
"homepage" : "https://github.com/chrisa/node-dtrace-provider#readme",
"author" : {
"name" : "Chris Andrews",
"email": "chris@nodnol.org"
},
"repository" : {
"type" : "git",
"url" : "http://github.com/chrisa/node-dtrace-provider.git"
},
"engines" : {
"node" : ">=0.6"
},
"devDependencies": {
"tap": ">=0.2.0",
"execSync": ">=0.0.1"
},
"main" : "./dtrace-provider.js"
}

@@ -70,2 +70,26 @@ # dtrace-provider - Native DTrace providers for Node.js apps.

Available argument types are "int", for integer numeric values,
"char *" for strings, and "json" for objects rendered into JSON strings.
Arguments typed as "json" will be created as "char *" probes in
DTrace, but objects passed to these probe arguments will be
automatically serialized to JSON before being passed to DTrace. This
feature is best used in conjunction with the json() D subroutine, but
is available whether or not the platform supports it.
# create a json probe:
var dtp = d.createDTraceProvider("nodeapp");
var p1 = dtp.addProbe("j1", "json");
dtp.enable();
p1.fire(function() { return { "foo" => "bar" }; });
# on a platform supporting json():
$ sudo dtrace -Z -n 'nodeapp*:::j1{ this->j = copyinstr(arg0); \
trace(json(this->j, "foo")) }'
dtrace: description 'nodeapp$target:::j1' matched 0 probes
CPU ID FUNCTION:NAME
0 68712 j1:j1 bar
## PLATFORM SUPPORT

@@ -88,8 +112,2 @@

## LIMITATIONS
The data types supported are "int" and "char *". Support for
structured types is planned, depending on support from the host DTrace
implementation for the necessary translators.
## CAVEATS

@@ -112,2 +130,7 @@

## RUNNING THE TESTS
$ npm install
$ sudo ./node_modules/.bin/tap --tap test/*.test.js
## OTHER IMPLEMENTATIONS

@@ -114,0 +137,0 @@

@@ -1,8 +0,14 @@

// node --expose_gc ...
// expected output:
//
// $ sudo dtrace -Zn 'nodeapp*:::gcprobe{ trace(arg0); }' -c 'node --expose_gc test/gc.js'
// Dtrace: description 'nodeapp*:::gcprobe' matched 0 probes
// dtrace: pid 66257 has exited
// CPU ID FUNCTION:NAME
// 1 1778 gcprobe:gcprobe 4320227343
var d = require('../dtrace-provider');
var dtp = d.createDTraceProvider("testlibusdt");
var dtp = d.createDTraceProvider("nodeapp");
// don't assign the returned probe object anywhere
dtp.addProbe("gcprobe");
dtp.addProbe("gcprobe", "int");
dtp.enable();

@@ -9,0 +15,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

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