From 368843191e17c12430ebb66caf632beb3b4a4ccb Mon Sep 17 00:00:00 2001 From: Jonathan Shook Date: Tue, 21 Jul 2020 01:51:52 -0500 Subject: [PATCH] minor doc updates --- .../resources/docs-for-nb/scripting/index.md | 2 +- .../scripting/script_parameters.md | 11 ++--- .../scripting/scripting_extensions.md | 43 +++++++++++++++++++ 3 files changed, 50 insertions(+), 6 deletions(-) create mode 100644 engine-docs/src/main/resources/docs-for-nb/scripting/scripting_extensions.md diff --git a/engine-docs/src/main/resources/docs-for-nb/scripting/index.md b/engine-docs/src/main/resources/docs-for-nb/scripting/index.md index 5949baaa9..4bc07a463 100644 --- a/engine-docs/src/main/resources/docs-for-nb/scripting/index.md +++ b/engine-docs/src/main/resources/docs-for-nb/scripting/index.md @@ -1,6 +1,6 @@ --- title: Scripting -weight: 10 +weight: 95 --- # Scripting with NoSQLBench diff --git a/engine-docs/src/main/resources/docs-for-nb/scripting/script_parameters.md b/engine-docs/src/main/resources/docs-for-nb/scripting/script_parameters.md index 52a04a55f..52a86513b 100644 --- a/engine-docs/src/main/resources/docs-for-nb/scripting/script_parameters.md +++ b/engine-docs/src/main/resources/docs-for-nb/scripting/script_parameters.md @@ -1,6 +1,6 @@ --- -title: Scripting -weight: 10 +title: Script Parameters +weight: 20 --- # Script Parameters @@ -15,20 +15,21 @@ that you would for an activity. For example, you might have a scenario script li cycles: '1000' }); -This is what the script form of starting an activity in a scenario might look like. It is +This is what the script form of starting an activity might look like. It is simply passing a parameter map with the activity parameters to the scenario controller. + You might invoke it like this: nb script myscript Suppose that you want to allow the user to run such an activity by calling the script directly, -but you also want them to to allow them to add their own parameters specifically to the +but you also want them to allow them to add their own parameters specifically to the activity. NoSQLBench supports this type of flexibility by providing any command-line arguments to the script as a script object. It is possible to then combine the parameters that a user provides with any templated parameters in your script. You can make either one the primary, while allowing -the otehr to backfill values. In either case, it's a matter of using helper methods that are +the other to backfill values. In either case, it's a matter of using helper methods that are baked into the command line parameters object. To force parameters to specific values while allowing user command line parameters to backfill, diff --git a/engine-docs/src/main/resources/docs-for-nb/scripting/scripting_extensions.md b/engine-docs/src/main/resources/docs-for-nb/scripting/scripting_extensions.md new file mode 100644 index 000000000..54fea5a31 --- /dev/null +++ b/engine-docs/src/main/resources/docs-for-nb/scripting/scripting_extensions.md @@ -0,0 +1,43 @@ +--- +title: Scripting Extensions +weight: 30 +--- + +# Scripting Extensions + +Extensions are injected into the scripting environment as plugins. They appear as service +objects in the script environment under a name determined by the plugin. + +This section describes some of the scripting extensions available. + +## csvmetrics + +Allows a script to log some or all metrics to CSV files. + +## files + +Allows for convenient read access to local files. + +## globalvars + +Allows access to the shared variable state that can be populated from operations. + +## histologger + +Allows script control of HDR histogram interval logging. + +## histostatslogger + +Allows script control of histogram stats logging in CSV files. + +## http + +Easily use http get and post in scripts. + +## optimos + +Allows use of the BOBYQA optimizer in scripts. + +## scriptingmetrics + +Allows you to create and append metrics within your scenario scripts \ No newline at end of file