Simple browser, scripted browser, and API monitors execute in the runtime environment used when the monitors were created. Your monitors won't automatically convert to newer runtimes when those runtimes release.
Monitors running on older runtimes lose out on new runtime features, so it's important that you understand which runtimes are used by your monitors.
Read on to learn how to:
- Upgrade a synthetic monitor
- View a synthetic monitor upgrade history
- Use environment variables in runtimes
- Review runtime dependencies
Ping monitors are not affected by changes in runtime versions.
Existing monitors default to the runtime used at their time of creation. To prevent your critical monitors from breaking during future end-of-life processes, we recommend you convert your public monitors sooner rather than later. To convert:
- Go to one.newrelic.com > Synthetic monitoring, then select the monitor you want to upgrade.
- Click General.
- Use the dropdown menu to switch the current runtime version.
- Click Validate to check that your monitors function in the new runtime. Make any script modifications if needed.
To see a history of monitor version upgrades, query the
Make your scripted monitors more contextually aware by using the
$env variable properties. When the script executes, these properties represent important information about the runtime environment.
You do not need to import
$env because it is readily available, similar to the
$http variables. For example:
console.log('running in ' + $env.LOCATION);$browser.get('https://example.com');
Scripted API test
Unique ID (
Unique ID (
Unique ID (
Type of monitor this job is running
API version this monitor is using
Location where this job is running. Examples:
Host of the proxy that collects HTTP traffic metrics
Port of the proxy that collects HTTP traffic metrics
A configurable set of variables specified by users.
See the documentation about containerized private minion (CPM) configuration.
Starting with the Node.js 16.10.0 runtime release, the API runtime will be managed separately from the browser runtime. This is the first scripted API runtime based on the
got module instead of the deprecated
request module. The
got module is exposed in a
request compatible format via the
$http object. The
request-like experience provided by the
$http object will also be returned for any customers attempting to use
request directly in the Node.js 16 and newer scripted API runtimes.
The API runtime is used for these monitor types:
- Broken links monitor
- Certificate check monitors
- Scripted API monitors
If you're unsure about your monitor's runtime version, edit your monitor and check the "Runtime" drop down in the "Configure monitor" tab. You can also query the
runtimeTypeVersion attribute on
SyntheticCheck events where the
runtimeType = 'NODE_API'.
With the Chrome 100+ runtime release, the browser runtime is managed separately from the API runtime. This is also known as our next-generation runtime.
The browser runtime is used for these monitor types:
- Scripted brower monitors
- Simple browser monitors
- Step monitors
If you're unsure about your monitor's runtime version, edit your monitor and check the "Runtime" drop down on the "Configure monitor" tab. You can also query the runtimeTypeVersion attribute on SyntheticCheck events where the runtimeType = 'CHROME_BROWSER'.
The monitor version always matches its runtime version, and determines what features the monitor can execute. The section below lists runtimes with its available features.
If you're unsure about your monitor version, go to one.newrelic.com > Synthetic monitoring > Upgrade monitors. You won't see the Upgrade monitors option if you're on the latest runtime version.
Here are monitor version details for all monitor types except ping: