30 Commits
Author SHA1 Message Date
Cody Peter Mello ee86dd42d6 chrisa/node-dtrace-provider#126 Some tests are flaky under newer node versions due to probe getting GC'd 2019-07-23 22:49:22 +00:00
Cody Peter Mello 6ef2a247fc chrisa/node-dtrace-provider#120 Failed assertion when firing unregistered probe name 2018-05-30 00:22:42 +00:00
Cody Peter Mello a1594b0ea1 chrisa/node-dtrace-provider#90 Probes should hold a reference to their providers 2017-02-24 16:13:43 -08:00
Cody Peter Mello c80caf18c2 Pass extra args to callback via .fire() 2016-10-25 23:36:58 +00:00
Chris Andrews 447d692987 Update libusdt for "prevent fire after disable" bug.
Also updates tests which were actually expecting a fired probe on
a disabled provider.
2013-10-15 12:58:01 +01:00
Chris Andrews be8ad6e7de Test showing we can add probes to an existing provider. 2013-07-18 09:11:45 +01:00
Chris Andrews ae94e89b60 Remove need for execSync from tests. 2013-02-04 20:17:23 +00:00
Chris Andrews 8fe1c361e1 Fix up handling of DTraceArgument objects.
This change adds a destructor for the DTraceArgument base class,
improves handling of probe argument values, and adds tests for
more argument cases.
2012-12-09 11:41:07 +00:00
Chris Andrews c7ed19c7c1 Merge branch 'libusdt_issue5' into json-args 2012-12-08 18:22:22 +00:00
Chris Andrews 270f93e1ce Skip JSON tests if the json() subroutine isn't available.
Shell out to dtrace(1M) before checking the results of tests involving
the json() subroutine.
2012-12-02 19:22:12 +00:00
Chris Andrews 739e1a7098 Support an argument type of "json", serialising argument values.
This change allows objects to be passed as argument values, using a
"json" type which is implemented as a regular char * argument, but
with serialising of the object to JSON.
2012-12-02 00:21:52 +00:00
Chris Andrews 2fdd920201 Account for user_addr_t / uintptr_t difference. 2012-11-24 12:28:08 +00:00
Chris Andrews 54cb28795b Wait for dtrace stdio to complete before checking output, and use full path.
dtrace may not be on the path.
2012-11-24 12:10:51 +00:00
Chris Andrews 305af8e4dd Make test/*.js into a proper testsuite. 2012-11-23 22:06:45 +00:00
Chris Andrews 5a212e34e2 Use libusdt's memory-management calls on object destruction.
libusdt now allows us to deallocate providers and probes properly.
We call the appropriate library routines from our object destructors,
and allow probes to be garbage-collected.
2012-11-20 22:23:29 +00:00
Chris Andrews 3336f6ebd2 Tests and version bump for module name disambiguation change. 2012-10-31 23:59:05 +00:00
Chris Andrews 29d100af59 Merge branch 'libusdt' 2012-08-21 21:33:05 +01:00
Chris Andrews 68c7833167 Add support for "disable provider" and "remove probe". 2012-08-21 18:30:28 +01:00
Chris Andrews 664da20628 Update tests. 2012-05-01 21:28:15 +01:00
Chris Andrews dbe27e083d Fix issues with >6 args on x86_64.
Fixes in both this module and in libusdt.
2012-05-01 17:14:21 +01:00
Chris Andrews e9f4e4444e Add regression tests for not-enabled / enabled-again issues. 2012-04-29 16:03:21 +01:00
Chris Andrews 15467cb483 Use Persistent handles for probe objects. 2012-04-27 17:57:12 +01:00
Chris Andrews 89d8efed33 Update for current libusdt. 2012-04-27 15:49:12 +01:00
Chris Andrews cc61ab0eb3 Prevent attempted re-enabling of providers breaking existing probes.
It was possible to call enable() on a provider more than once, which would
simply attempt to repeat the work required - creating stubs and the appropriate DOF.
However the kernel will in most cases ignore new DOF, leaving the old provider
in place, while the newly-created stubs are elsewhere.

This change simply no-ops subsequent calls to enable() on a provider, which still
doesn't allow changes to be made, but does prevent inadvertent breaking of existing
probes.
2012-04-04 13:25:44 +01:00
Chris Andrews 4fb31592d0 Test for segfault found when firing non-enabled probes. 2012-02-06 20:53:01 +00:00
Chris Andrews 11fbc56061 Revert "Expose DTraceProbeDef objects into JS as probe holders."
This reverts commit 3c0cffd412.
2011-12-13 21:11:33 +00:00
Chris Andrews 43d2017d93 Use libusdt instead of local DOF/tracepoints implementation.
Remove all the platform-dependent code from node-dtrace-provider, and
defers to the libusdt source which should be in a "libusdt" subdirectory.
2011-11-19 18:45:06 +00:00
Chris Andrews 3c0cffd412 Expose DTraceProbeDef objects into JS as probe holders.
Once the provider is enabled, you can call pd.fire(...) on the
ProbeDef objects, and avoid the provider's search-by-name.

Needs tidying up - creating an instance of a different class using
the same args appears to be tricky
2011-09-04 16:59:57 +01:00
Mark Cavage f028d034af Stub out non-sun/mac platforms 2011-08-30 14:38:05 -07:00
Chris Andrews 3dc9025f99 Initial import of working dtrace-provider extension. 2011-01-27 17:51:42 +00:00