@overkill-dev/bench 0.0.12 → 0.0.14
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/bench/async-measurement-resources.js +123 -0
- package/bench/async-measurement-resources.js.map +1 -0
- package/bench/benchmark-budget-definition.d.ts +1 -1
- package/bench/benchmark-budget-definition.d.ts.map +1 -1
- package/bench/benchmark-definition.d.ts +2 -1
- package/bench/benchmark-definition.d.ts.map +1 -1
- package/bench/benchmark-garbage-collection.js +5 -7
- package/bench/benchmark-garbage-collection.js.map +1 -1
- package/bench/benchmark-lifecycle-policy.d.ts +1 -1
- package/bench/benchmark-lifecycle-policy.d.ts.map +1 -1
- package/bench/benchmark-lifecycle.js +13 -5
- package/bench/benchmark-lifecycle.js.map +1 -1
- package/bench/benchmark-observation-set.js.map +1 -1
- package/bench/benchmark-observations.js +14 -1
- package/bench/benchmark-observations.js.map +1 -1
- package/bench/benchmark-sample-lifetime.js +31 -9
- package/bench/benchmark-sample-lifetime.js.map +1 -1
- package/bench/benchmark-sampling-evidence.js +6 -3
- package/bench/benchmark-sampling-evidence.js.map +1 -1
- package/bench/benchmark-sampling.js +1 -1
- package/bench/benchmark-sampling.js.map +1 -1
- package/bench/calibrated-measurement.d.ts.map +1 -1
- package/bench/calibrated-measurement.js +4 -1
- package/bench/calibrated-measurement.js.map +1 -1
- package/bench/calibration-definition.d.ts +2 -1
- package/bench/calibration-definition.d.ts.map +1 -1
- package/bench/calibration-observations.js.map +1 -1
- package/bench/calibration-sampling.js +1 -1
- package/bench/calibration-sampling.js.map +1 -1
- package/bench/collector-lifetime.js +108 -0
- package/bench/collector-lifetime.js.map +1 -0
- package/bench/collector-result.js +39 -0
- package/bench/collector-result.js.map +1 -0
- package/bench/default-normalization.js +4 -0
- package/bench/default-normalization.js.map +1 -1
- package/bench/measurement-attribution.js +18 -0
- package/bench/measurement-attribution.js.map +1 -0
- package/bench/measurement-context.js +32 -0
- package/bench/measurement-context.js.map +1 -0
- package/bench/measurement-definition.d.ts.map +1 -1
- package/bench/measurement-definition.js +10 -0
- package/bench/measurement-definition.js.map +1 -1
- package/bench/measurement-evidence.js +69 -0
- package/bench/measurement-evidence.js.map +1 -0
- package/bench/measurement-region-lifetime.js +47 -0
- package/bench/measurement-region-lifetime.js.map +1 -0
- package/bench/measurement-region-readings.js +25 -0
- package/bench/measurement-region-readings.js.map +1 -0
- package/bench/measurement-region.js +49 -80
- package/bench/measurement-region.js.map +1 -1
- package/bench/measurement-resources.js +79 -88
- package/bench/measurement-resources.js.map +1 -1
- package/bench/measurement-shutdown.js +58 -0
- package/bench/measurement-shutdown.js.map +1 -0
- package/bench/measurement-strategy.d.ts.map +1 -1
- package/bench/measurement-strategy.js +2 -1
- package/bench/measurement-strategy.js.map +1 -1
- package/bench/measurement-target-cooldown.js +21 -0
- package/bench/measurement-target-cooldown.js.map +1 -0
- package/bench/measurement-target.d.ts +36 -0
- package/bench/measurement-target.d.ts.map +1 -0
- package/bench/measurement-target.js +94 -0
- package/bench/measurement-target.js.map +1 -0
- package/bench/measurement-types.d.ts +37 -11
- package/bench/measurement-types.d.ts.map +1 -1
- package/bench/metric-reading.d.ts +1 -1
- package/bench/metric-reading.d.ts.map +1 -1
- package/bench/module-import-session.js +41 -10
- package/bench/module-import-session.js.map +1 -1
- package/bench/module-measurement.d.ts +1 -1
- package/bench/module-measurement.d.ts.map +1 -1
- package/bench/native-metric-collectors.d.ts.map +1 -1
- package/bench/native-metric-collectors.js +21 -23
- package/bench/native-metric-collectors.js.map +1 -1
- package/bench/process-child.js +78 -54
- package/bench/process-child.js.map +1 -1
- package/bench/process-evidence.js +2 -16
- package/bench/process-evidence.js.map +1 -1
- package/bench/process-execution.js +19 -9
- package/bench/process-execution.js.map +1 -1
- package/bench/process-helper.js +29 -13
- package/bench/process-helper.js.map +1 -1
- package/bench/process-node-observation.js +33 -14
- package/bench/process-node-observation.js.map +1 -1
- package/bench/process-observation.d.ts +16 -16
- package/bench/process-probe-report.js +53 -40
- package/bench/process-probe-report.js.map +1 -1
- package/bench/process-probe-session.js +18 -7
- package/bench/process-probe-session.js.map +1 -1
- package/bench/process-sampling.js +7 -3
- package/bench/process-sampling.js.map +1 -1
- package/bench/runtime-health-collector.d.ts.map +1 -1
- package/bench/runtime-health-collector.js +20 -22
- package/bench/runtime-health-collector.js.map +1 -1
- package/bench/sampling-policy.d.ts +1 -1
- package/bench/sampling-policy.d.ts.map +1 -1
- package/package.json +8 -4
- package/packages/bench/bench.entry-point.d.ts +9 -2
- package/packages/bench/bench.entry-point.d.ts.map +1 -1
- package/packages/bench/bench.entry-point.js +2 -0
- package/packages/bench/bench.entry-point.js.map +1 -1
- package/packages/bench/calibration.entry-point.d.ts +1 -1
- package/packages/bench/calibration.entry-point.d.ts.map +1 -1
- package/readme.md +54 -11
- package/software-bill-of-materials.cyclonedx.json +19 -19
package/readme.md
CHANGED
|
@@ -161,10 +161,55 @@ resource acquisition, and teardown are outside the measured callback.
|
|
|
161
161
|
Built-in collectors are `threadCpuCollector`, `processCpuCollector`,
|
|
162
162
|
`memoryCollector`, `processResourceCollector`, and `runtimeHealthCollector`.
|
|
163
163
|
Runtime health needs an async strategy to prime and drain its observers.
|
|
164
|
-
Custom collectors declare
|
|
165
|
-
|
|
166
|
-
|
|
167
|
-
`
|
|
164
|
+
Custom collectors declare `name`, `version`, `mode`, and metric names, units,
|
|
165
|
+
and scopes. `prepare(context)` acknowledges readiness and returns `start`,
|
|
166
|
+
`stop`, and `finalize`. Register allocation release with
|
|
167
|
+
`context.cleanup.defer(signal => ...)` before acquisition can fail. The harness
|
|
168
|
+
releases registered allocations in reverse order, including partial preparation.
|
|
169
|
+
Collectors release their own allocations; shared resources keep their declared lifetime.
|
|
170
|
+
|
|
171
|
+
`finalize(context)` returns `context.readings(metricReadings)`. This binds the
|
|
172
|
+
readings to their invocation and target. For incomplete capture, return the same
|
|
173
|
+
envelope with `completeness: { kind: 'incomplete', reasons: [...] }`.
|
|
174
|
+
Missing or incomplete readings remain unavailable; required metrics cannot pass
|
|
175
|
+
budgets. Available readings must match the collector's declared provenance.
|
|
176
|
+
|
|
177
|
+
Synchronous collectors keep every lifecycle hook synchronous. Async collectors
|
|
178
|
+
may await preparation, start, stop, and finalization. All starts complete before
|
|
179
|
+
the operation. The harness stops started sessions and finalizes prepared sessions
|
|
180
|
+
once, then releases allocations, preserving operation and shutdown failures together.
|
|
181
|
+
Cancellation uses a fresh cleanup signal. Stop, finalization, and release share
|
|
182
|
+
one two-second deadline per invocation; late results cannot enter another sample.
|
|
183
|
+
Synchronous hooks cannot be forcibly preempted within their executing thread.
|
|
184
|
+
|
|
185
|
+
`withMeasurementTarget(target, strategy)` selects a `MeasurementTarget` for
|
|
186
|
+
sync or async strategies. It supplies a synchronous local monotonic clock and
|
|
187
|
+
explicit cooldown and GC capabilities. Its identity declares name, version,
|
|
188
|
+
scope, clock domain, and semantic facts such as instrumentation, endpoints, and
|
|
189
|
+
reset/cache policy. Instance and document identities attribute concrete readings;
|
|
190
|
+
they do not enter comparison identity. Both clock endpoints must use that target's
|
|
191
|
+
clock domain. Cross-clock subtraction and automatic host timing substitution are
|
|
192
|
+
unsupported.
|
|
193
|
+
|
|
194
|
+
Without an explicit target, function regions measure the executing Node runtime.
|
|
195
|
+
Requested cooldown or GC must exist on the selected target before warmup starts.
|
|
196
|
+
External-process and cold-module strategies reject requested target settling or
|
|
197
|
+
GC because their measured processes do not expose those capabilities. Explicit
|
|
198
|
+
GC remains off by default; ambient host exposure does not enable it.
|
|
199
|
+
|
|
200
|
+
Targets with `normalization: 'raw'` receive no default CPU calibration. Select
|
|
201
|
+
`'node-cpu'` only for a target compatible with that calibration model. Target
|
|
202
|
+
selection survives raw, calibrated, and timeline wrappers.
|
|
203
|
+
|
|
204
|
+
Lifecycle evidence records warmup/measured invocation identity, collector
|
|
205
|
+
completeness, target facts, errors, and separate measured/lifecycle durations.
|
|
206
|
+
Raw sample attachments use version 1 envelopes with per-reading invocation
|
|
207
|
+
and target attribution. Use `readRawBenchmarkSamples(value)` to read them.
|
|
208
|
+
Saved performance baselines use version 1 and key stable target and collector
|
|
209
|
+
facts separately from instance IDs. Use `overkill bench baseline apply` to
|
|
210
|
+
replace baselines whose measurement identity changed. Earlier development
|
|
211
|
+
formats require regeneration.
|
|
212
|
+
Returned plain numbers remain custom metrics with unit `number`.
|
|
168
213
|
|
|
169
214
|
CPU metrics are deltas in microseconds. Memory metrics include end snapshots
|
|
170
215
|
and signed byte deltas; RSS and active resource counts describe the process,
|
|
@@ -479,11 +524,10 @@ in the snapshot belong to that observer; execution host arguments retain their
|
|
|
479
524
|
ordinary execution facts.
|
|
480
525
|
|
|
481
526
|
`RunFacts.benchmarkHost` contains the snapshot, configured limits, and check
|
|
482
|
-
results.
|
|
483
|
-
|
|
484
|
-
|
|
485
|
-
|
|
486
|
-
`RunFacts.benchmarkCalibration`, which retains the legacy adapter CPU reference.
|
|
527
|
+
results. Reporter `RunReport.context.facts` provides the same host, placement,
|
|
528
|
+
and normalization context. `RunFacts.benchmarkCalibration` retains the adapter CPU
|
|
529
|
+
reference. These describe execution of the consumer's benchmark workload;
|
|
530
|
+
they do not measure Overkill's own performance.
|
|
487
531
|
The snapshot describes its recorded moment; collection and fixture startup may
|
|
488
532
|
change conditions afterward. Sampling does not recheck host conditions.
|
|
489
533
|
|
|
@@ -600,8 +644,7 @@ Inference retains the independent, stationary observation assumption.
|
|
|
600
644
|
|
|
601
645
|
Results retain raw summaries, calibration samples, reference selection, factors,
|
|
602
646
|
normalized summaries, and converted display budgets. JSON and HTML preserve both
|
|
603
|
-
scales. `RunFacts.benchmarkNormalization`
|
|
604
|
-
record reference inputs; older artifacts remain readable. Direct engine execution
|
|
647
|
+
scales. `RunFacts.benchmarkNormalization` records reference inputs. Direct engine execution
|
|
605
648
|
also supplies automatic calibration context.
|
|
606
649
|
|
|
607
650
|
Capture and baseline cleanup emit a `calibration-references` report, readable with
|
|
@@ -16,9 +16,9 @@
|
|
|
16
16
|
"component": {
|
|
17
17
|
"type": "library",
|
|
18
18
|
"name": "@overkill-dev/bench",
|
|
19
|
-
"version": "0.0.
|
|
20
|
-
"bom-ref": "pkg:npm/@overkill-dev/bench@0.0.
|
|
21
|
-
"purl": "pkg:npm/@overkill-dev/bench@0.0.
|
|
19
|
+
"version": "0.0.14",
|
|
20
|
+
"bom-ref": "pkg:npm/@overkill-dev/bench@0.0.14",
|
|
21
|
+
"purl": "pkg:npm/@overkill-dev/bench@0.0.14"
|
|
22
22
|
}
|
|
23
23
|
},
|
|
24
24
|
"components": [
|
|
@@ -38,41 +38,41 @@
|
|
|
38
38
|
{
|
|
39
39
|
"type": "library",
|
|
40
40
|
"name": "@overkill-dev/engine",
|
|
41
|
-
"version": "0.0.
|
|
42
|
-
"bom-ref": "pkg:npm/@overkill-dev/engine@0.0.
|
|
41
|
+
"version": "0.0.84",
|
|
42
|
+
"bom-ref": "pkg:npm/@overkill-dev/engine@0.0.84",
|
|
43
43
|
"scope": "optional",
|
|
44
44
|
"licenses": [
|
|
45
45
|
{
|
|
46
46
|
"expression": "MIT"
|
|
47
47
|
}
|
|
48
48
|
],
|
|
49
|
-
"purl": "pkg:npm/@overkill-dev/engine@0.0.
|
|
49
|
+
"purl": "pkg:npm/@overkill-dev/engine@0.0.84"
|
|
50
50
|
},
|
|
51
51
|
{
|
|
52
52
|
"type": "library",
|
|
53
53
|
"name": "@overkill-dev/resources",
|
|
54
|
-
"version": "0.0.
|
|
55
|
-
"bom-ref": "pkg:npm/@overkill-dev/resources@0.0.
|
|
54
|
+
"version": "0.0.27",
|
|
55
|
+
"bom-ref": "pkg:npm/@overkill-dev/resources@0.0.27",
|
|
56
56
|
"scope": "optional",
|
|
57
57
|
"licenses": [
|
|
58
58
|
{
|
|
59
59
|
"expression": "MIT"
|
|
60
60
|
}
|
|
61
61
|
],
|
|
62
|
-
"purl": "pkg:npm/@overkill-dev/resources@0.0.
|
|
62
|
+
"purl": "pkg:npm/@overkill-dev/resources@0.0.27"
|
|
63
63
|
},
|
|
64
64
|
{
|
|
65
65
|
"type": "library",
|
|
66
66
|
"name": "@overkill-dev/run",
|
|
67
|
-
"version": "0.0.
|
|
68
|
-
"bom-ref": "pkg:npm/@overkill-dev/run@0.0.
|
|
67
|
+
"version": "0.0.106",
|
|
68
|
+
"bom-ref": "pkg:npm/@overkill-dev/run@0.0.106",
|
|
69
69
|
"scope": "optional",
|
|
70
70
|
"licenses": [
|
|
71
71
|
{
|
|
72
72
|
"expression": "MIT"
|
|
73
73
|
}
|
|
74
74
|
],
|
|
75
|
-
"purl": "pkg:npm/@overkill-dev/run@0.0.
|
|
75
|
+
"purl": "pkg:npm/@overkill-dev/run@0.0.106"
|
|
76
76
|
},
|
|
77
77
|
{
|
|
78
78
|
"type": "library",
|
|
@@ -158,12 +158,12 @@
|
|
|
158
158
|
"ref": "pkg:npm/@enormora/clock@0.0.3"
|
|
159
159
|
},
|
|
160
160
|
{
|
|
161
|
-
"ref": "pkg:npm/@overkill-dev/bench@0.0.
|
|
161
|
+
"ref": "pkg:npm/@overkill-dev/bench@0.0.14",
|
|
162
162
|
"dependsOn": [
|
|
163
163
|
"pkg:npm/@enormora/clock@0.0.3",
|
|
164
|
-
"pkg:npm/@overkill-dev/engine@0.0.
|
|
165
|
-
"pkg:npm/@overkill-dev/resources@0.0.
|
|
166
|
-
"pkg:npm/@overkill-dev/run@0.0.
|
|
164
|
+
"pkg:npm/@overkill-dev/engine@0.0.84",
|
|
165
|
+
"pkg:npm/@overkill-dev/resources@0.0.27",
|
|
166
|
+
"pkg:npm/@overkill-dev/run@0.0.106",
|
|
167
167
|
"pkg:npm/@stdlib/stats-base-dists-binomial-quantile@0.2.3",
|
|
168
168
|
"pkg:npm/node-pty@1.2.0-beta.17",
|
|
169
169
|
"pkg:npm/simple-statistics@8.0.0",
|
|
@@ -173,13 +173,13 @@
|
|
|
173
173
|
]
|
|
174
174
|
},
|
|
175
175
|
{
|
|
176
|
-
"ref": "pkg:npm/@overkill-dev/engine@0.0.
|
|
176
|
+
"ref": "pkg:npm/@overkill-dev/engine@0.0.84"
|
|
177
177
|
},
|
|
178
178
|
{
|
|
179
|
-
"ref": "pkg:npm/@overkill-dev/resources@0.0.
|
|
179
|
+
"ref": "pkg:npm/@overkill-dev/resources@0.0.27"
|
|
180
180
|
},
|
|
181
181
|
{
|
|
182
|
-
"ref": "pkg:npm/@overkill-dev/run@0.0.
|
|
182
|
+
"ref": "pkg:npm/@overkill-dev/run@0.0.106"
|
|
183
183
|
},
|
|
184
184
|
{
|
|
185
185
|
"ref": "pkg:npm/@stdlib/stats-base-dists-binomial-quantile@0.2.3"
|