Commit Graph
101 Commits
Author SHA1 Message Date
Jonathan Shook 59d604aed6 fix(virtdata): binding windows warm records without renumbering them
A binding window re-based the reader to zero, so BaseVectors(spec,
'[50000..100000)') exposed indices 0..49999. A workload running the
cycles that window names then indexed past the end and failed, and it
only ever worked from cycle 0, where the re-basing is the identity. It
also disagreed with the two surfaces beside it: VariableFacet and
prefetchCycles both speak absolute ordinals.

The window now selects which records to warm and nothing else. Indices
are absolute everywhere, so cycles address the records they name, and
the fetch still covers only the window — a [50000..100000) slice of a
100k profile warms 74 MiB rather than the full 146 MiB.

Reads outside the window demand-page rather than failing, which is
load-bearing rather than lenient: VirtData probes a newly resolved
function with a small sample index before any cycle runs, so refusing
out-of-window reads leaves a window above zero unable to resolve at
all. A test pins that.

WindowedReader keeps its restricting behaviour for the windowedFacet
expression function, where a caller asks for a restricted reader
directly and no resolver probe is involved.
2026-09-02 19:36:03 +00:00
Jonathan Shook 52dc31bfce feat(virtdata): meter the background prefetch and reach it directly
Asking for a prefetch with progress meant asking for prefetch=false and
then a binding mode — two knobs that read as contradicting each other,
because the background expr function was the one prefetch form that
never got a meter, so the only way to see a background download was to
route it through a binding.

prefetchBackground now announces its plan and watches the handle like
every other form, and prefetchCyclesBackground takes the ordinal range
directly. With the API reachable at the surface, the demo asks for what
it wants in one word: prefetch=load blocks on prefetchCycles before the
run, prefetch=background hands back a metered handle that fetches while
the cycles run, prefetch=none leaves reads to demand-page. The binding
mode knob is gone.
2026-09-02 15:54:14 +00:00
Jonathan Shook 66fc07c15f docs(stdout): correct the demo workload invocation
The documented 'nb5 run vectordata_demo' does not work: run is itself a
command, so the workload name is parsed as a second one and resolves to
no service. The scenario form drops the run — 'nb5 vectordata_demo
dataset=<name>:<profile>' — and the long form names the full bundled
path, 'nb5 run workload=activities/examples/vectordata_demo.yaml'.
Both are now shown in the workload and the guide.

Verified against the 5.25.15-release binary: the workload is bundled
and listed, both corrected forms load it, and a real dataset run meters
the download and reads base, query, and neighbor records.
2026-09-02 01:04:19 +00:00
Jonathan Shook 0b9e16ee20 feat(stdout): bundle the vectordata demo as a runnable workload
The demo only worked from a checkout. It now ships in the stdout
adapter's activities, so 'nb5 run vectordata_demo dataset=<name>:<profile>'
works from the distribution alone, with --cat and --copy for reading or
editing it.

Every catalog-touching expression is guarded on the dataset parameter
being given. Bundled workloads are parsed through the expression
pipeline by --list-workloads and --list-scenarios, so a workload that
opened a catalog unconditionally would fail listing for every user
without one configured; with no dataset named it now renders usage text
and touches nothing.
2026-09-01 23:23:47 +00:00
Jonathan Shook acc1034d14 docs(vectordata): runnable demo workload with a live download meter
vectordata_demo.yaml needs no database — the stdout driver exercises
dataset access alone. It prints what it derived from the dataset,
fetches a record range with the meter running, and reads records back,
so a download can be watched from one command line. prefetch=false
with mode=background moves the fetch off the load path and overlaps it
with the cycles instead.

Binding meter labels now carry the profile, matching the expr form, so
both name the same thing in a run that uses both.
2026-09-01 21:36:06 +00:00
Jonathan Shook 9085bf06ad feat(virtdata): prefetch progress, profile warm-up, and cycle ranges from exprs
A prefetch driven from a workload was silent and awkward to aim:

- every expr prefetch now reports through the same meter the bindings
  use, so a download started from a workload announces its cost, emits
  progress while the bytes move, and confirms completion
- prefetchProfile(spec) warms every facet the profile declares, each to
  the window it declares, in one call — the form that cannot
  accidentally pull a whole shared base file, since an empty window
  means the entire facet by design
- prefetchCycles(spec, facet, start, end) takes the ordinal range
  directly, which is how an activity already describes its work

The docs record the three things that bite: expressions evaluate at
load time rather than when a tagged block runs, an empty window is a
request for everything, and assignment sigils render their value where
they are written.
2026-09-01 18:51:09 +00:00
Jonathan Shook 20eb4f3c89 feat(cqld4): dataset-derived vector search workload
cql_vector_dataset.yaml takes one dataset input —
dataset='<dataset>:<profile>' — and derives everything dataset-shaped
through the expr system at load time: the schema's vector dimensions
and similarity function, rampup cycles from the base count, search
cycles from the query count, and the ANN LIMIT and recall k from the
ground-truth width. Bindings read through the vectordata mappers, so
the profile's base window warms eagerly with download progress before
the first cycle; the plan's cost is echoed into the rendered
description. Operational knobs (keyspace, table, rf, cl) stay
conventional TEMPLATE parameters.

Verified through the real load-path transforms (TemplateRewriter +
ExprPreprocessor) against a published remote dataset: dimensions 384,
train 100k, test 10k, k 100, dot_product, all spliced correctly.
2026-08-27 18:14:50 +00:00
Jonathan Shook 85f936acac update test script 2026-08-26 21:02:03 +00:00
Jonathan Shook 683c2d5849 docs(vectordata): remote access guide with a standalone smoke-test script
devdocs/vectordata/ holds the guide and remote_smoke_test.sh, which
checks base, query, and neighbor-index facets of one profile by
eagerly warming exactly the records each check reads — with the plan
announced and download progress on stderr — aborting on the first
failure. VECTORDATA_CATALOG and DATASET are required, DATASET as
'<dataset>' or '<dataset>:<profile>' with the profile defaulting to
'default', and NB selects how nosqlbench is invoked. The guide keeps
the Facet, windowed-background, and whole-profile warm-up forms as
separate examples.
2026-08-26 20:47:21 +00:00
Jonathan Shook cdf750344f docs(vectordata): add a quick remote smoke-test stub
Environment-variable catalog selection with an isolated VECTORDATA_HOME
and three stdout-driver one-liners: profile-window warm-up, a
caller-named ordinal range in the background, and demand-paged access.
2026-08-26 19:28:36 +00:00
Jonathan Shook 7b3f802135 docs(vectordata): how to test remote dataset access
Java API, expr, and inline-op examples for remote reads and for
precache/prefetch in both profile-window and caller-named ordinal-range
forms, plus the verification patterns the integration tests use.
2026-08-26 19:07:38 +00:00
Jonathan Shook 22124a22ef fix jmh invocation 2026-01-21 17:34:38 +00:00
Jonathan Shook d308cddf21 New JMH benchmarking framework:
Added 9 new benchmark classes in nb-engine-core/.../sysperf/engineflow/ for measuring engine flow performance
  (stride context, op flow, space mapping, motor operations, etc.)
JMH documentation: Added devdocs/devguide/jmh_engineflow.md
Testing tags:
 POM updates: Added test profiles
 CONVENTIONS.md updates around test tags
 Test annotations: Added 2-3 lines to ~280 test files
 Split tests classes to allow one tag set per class (no mixed methods)
2026-01-20 17:23:18 +00:00
Jonathan Shook 1603afd499 Add notes on metrics updates. 2025-11-12 19:46:05 +00:00
Jonathan Shook d0560f2801 templates as exprs (#2228)
* improve exprs dryrun output and error messages

* modularize user-extensible workload exprs

* make TEMPLATE just exprs

* square up template variable syntax

* banish double angle brackets and make Dryrun enum pervasive

* template replacement cleanup

* clean up logger levels, support copy target
2025-10-17 12:10:50 -05:00
Jonathan Shook a83d83bbe8 branch reconciliation: Flatten Activity API (#2217)
update and plan true-up: Flatten Activity API
2025-09-29 13:25:37 -05:00
Jonathan Shook 827c1bce43 add docs 2024-11-20 17:51:35 -06:00
Jonathan Shook f6cbd5e42b update copyright with no date 2024-10-30 16:12:21 -05:00
Jonathan Shook c46e097e50 remove deprecated CommandTemplate 2023-12-08 19:37:06 -06:00
Jonathan Shook ae19037bce remainder of changes for scenario rework that need to be itemized 2023-12-06 14:26:53 -06:00
Jonathan Shook 957f178c4c add sibling labels restriction and some docs 2023-10-23 16:45:10 -05:00
Jonathan Shook 945f48983c scenario tests stubbed, error handling in session fixed, mvn verify works now 2023-10-23 08:42:19 -05:00
Jonathan Shook 3ec511f61f partial progress to moving instrumentation 2023-10-23 08:41:17 -05:00
yabinmeng 9a61a1f2af Remove "--docker-metrics" functionality. Update documents and scripts accordingly. 2023-09-28 14:30:18 -05:00
02ff160b3c Metrics Publishing (#1234)
Included the following with core changes to allow labeled metrics for Prometheus exposition format publishing.
* javadoc updates
* remove extra types
* use NBLabeledElement instead of NBNamedElement
* contextualize NBLabeledElement for graphite/metrics
* externalize labeled ScriptContext to API
* add labels to NicerTimer
* remove partial packaging
* more progress on formatting for prom exposition format
* added metrics diagram
* resolve build issues with label params
* resolve build issues with label params
* prometheus export services
* added PromExpoFormat Tests for NBMetricMeter(Counting+Sampling) and NBMetricTimer(Counting)
* added test for Gauge Formatting
* added Gauge Formatting as well as Sampling values (count, stdev ...)
* added sketch for metrics labeling contexts
* add NBLabeledElement in all the places, retool calling paths to use it
* synchronize antlr versions after partial snyk change
* unbreak static initializer block after IntelliJ "fixed" it.
* engine-api - adapt to NBLabeledElement
* adapters-api - adapt to NBLabeledElement
* nb-api - adapt to NBLabeledElement
* engine-core - adapt to NBLabeledElement
* misc-adapters - adapt to NBLabeledElement
* streaming-adapters - adapt to NBLabeledElement
* add missing test
* initial implementation of a prom push reporter
* Resolve build issue with parseGlobalOptions
* replaced with PromPushReporter
* cleanup unused deps
* dependency removal for micrometer
* allow empty labels for tests
* change space.getName to space.getSpaceName
* cleanup poms
* graphite linearization now includes space element
* http adapter should only depend on adapters API
* http space does not create its own metric names
* import cleanups
* improved javadocs
* introduce component concepts

---------

Co-authored-by: Jonathan Shook <jshook@gmail.com>
Co-authored-by: Mike Yaacoub <mike.yaacoub@datastax.com>
2023-05-09 09:52:42 -05:00
Jonathan Shook 1b82ad9478 Merge pull request #1000 from nosqlbench/add-tags-script
Add tags script
2023-02-06 15:23:38 -06:00
jeffbanks cc989c8a72 nb5 revamp for scenarios 2023-02-06 14:58:04 -06:00
Jonathan Shook ef7f35bcf4 auto substitute PROG in docs with nb5 2023-02-05 20:30:22 -06:00
Jonathan Shook fa88a3b13b simplify fenced code blocks for compatibility 2023-01-17 19:29:51 -06:00
Jonathan Shook a1cd44cb1c remove previous "nb" module, which will be replaced by the nb5 module soon 2023-01-10 16:48:33 -06:00
Jonathan Shook c316bed26a support alternate inline format to work around docs shortcodes 2022-12-22 18:23:16 -06:00
Jonathan Shook d80632773b merge fixes for: improve concurrency patterns for activity execution 2022-12-20 20:05:17 -06:00
Jonathan Shook d1d21c8e5d nosqlbench-861 Allow dry-run of op generation. 2022-12-19 15:47:03 -06:00
Jonathan Shook 2b39f3c350 Merge branch 'main' into nosqlbench-797-callable 2022-12-12 15:04:39 -06:00
Jonathan Shook 6fbbfb5d0f diagram updates 2022-12-07 15:01:11 -06:00
Jonathan Shook 97cf9a32cb add ad-hoc doc to show publishing flow 2022-12-06 20:34:31 -06:00
Jonathan Shook 86c4dfd966 partial fixes for nosqlbench-797 Race condition between exceptional activity shutdown and normal scenario shutdown. 2022-11-30 11:17:10 -06:00
Jonathan Shook 9c66d616f0 start tracking feature news in a file 2022-08-25 15:13:59 -05:00
Jonathan Shook 28a1c66657 start tracking feature news in a file 2022-08-18 14:49:54 -05:00
Jonathan Shook 5dbeff9911 docs updates 2022-06-16 15:13:17 -05:00
Jonathan Shook 11dd8f62da add LERP visualization 2021-11-18 16:48:39 -06:00
Jonathan Shook ff142fd0b2 refactor/improve stat samplers for efficiency and correctness 2021-11-18 16:35:20 -06:00
Jonathan Shook 123c41a9bc cleanups 2021-11-10 15:41:21 -06:00
Jonathan Shook 3f607e0e8d build fixes 2021-11-10 15:27:56 -06:00
Jonathan Shook e6f1707d36 post-merge fixups 2021-11-10 14:37:55 -06:00
Jonathan Shook 6a5e9616b9 minor formatting improvements 2021-11-04 16:37:30 -05:00
Jonathan Shook 36901bdaa0 doc: old docs to be sorted 2021-09-13 09:56:47 -05:00
Jonathan Shook 828ec0252d naming: use ParsedOp instead of ParsedCommand 2021-09-13 09:43:19 -05:00
Jonathan Shook a39f4e1a27 docs: update doc system framing 2021-09-13 09:43:02 -05:00
Jonathan Shook 5b41f978c7 adapter API improvements 2021-08-10 10:34:26 -05:00