; } } Copy nr1.json The Nerdlet configuration file. { \"schemaType\": \"NERDLET\", \"id\": \"my-awesome-nerdpack-nerdlet\", \"description\": \"Describe me\", \"displayName\": \"MyAwesomeNerdpack\" } Copy Besides using the launcher as the access point for your application, you can also associate the application with a monitored entity to get it to appear in the entity explorer. To do this, add two additional fields to the config file of the first-launched Nerdlet: entities and actionCategory. In the following example, the Nerdlet has been associated with all Browser-monitored applications and will appear under the Monitor UI category : { \"schemaType\": \"NERDLET\", \"id\": \"my-nerdlet\", \"description\": \"Describe me\", \"displayName\": \"Custom Data\", \"entities\": [{ \"domain\": \"BROWSER\", \"type\": \"APPLICATION\" }], \"actionCategory\": \"monitor\" } Copy To see this application in the UI, you would go to the entity explorer, select Browser applications, and select a monitored application. styles.scss An empty SCSS file for styling your application. icon.png The launcher icon that appears on the Apps page in New Relic One when an application is deployed. Launcher file structure Launchers have their own file structure. Note that: A launcher is not required; as an alternative to using a launcher, you can associate your application with a monitored entity. An application can have more than one launcher, which might be desired for an application with multiple Nerdlets. After generating a launcher using the nr1 create command, its folder contains two files: nr1.json The configuration file. { \"schemaType\": \"LAUNCHER\", \"id\": \"my-awesome-nerdpack-launcher\", \"description\": \"Describe me\", \"displayName\": \"MyAwesomeNerdpack\", \"rootNerdletId\": \"my-awesome-nerdpack-nerdlet\" } Copy To connect a launcher to a Nerdlet, the rootNerdletId must match the id in the launched Nerdlet's nr1.json config file. For Nerdpacks with multiple Nerdlets, this needs to be done only for the first-launched Nerdlet. icon.png The icon displayed on the launcher for the app on the Apps page.",
+ "_index": "520d1d5d14cc8a32e600034b",
+ "_type": "520d1d5d14cc8a32e600034c",
+ "_score": 63.180374,
+ "_version": null,
+ "_explanation": null,
+ "sort": null,
+ "highlight": {
+ "title": "Nerdpack file structure",
+ "sections": "Nerdpack file structure",
+ "info": "An overview of the Nerdpack File Structure",
+ "tags": "NewRelicOne CLI",
+ "body": " components, see our app building guides and the NewRelicOne CLI command reference. Nerdpack file structure When you generate a Nerdpack template using the nr1 create command, it has the following file structure: my-nerdlet ├── README.md ├── launchers │ └── my-nerdlet-launcher │ ├── icon.png"
+ },
+ "id": "5efa989e196a671300766404"
+ }
+ ],
+ "/explore-docs/nr1-subscription": [
+ {
+ "sections": [
+ "New Relic One CLI reference",
+ "Installing the New Relic One CLI",
+ "Tip",
+ "New Relic One CLI Commands",
+ "Get started",
+ "Configure your CLI preferences",
+ "Set up your Nerdpacks",
+ "Manage your Nerdpack subscriptions",
+ "Install and manage plugins",
+ "Manage catalog information"
+ ],
+ "title": "New Relic One CLI reference",
"type": "developer",
"tags": [
"New Relic One app",
@@ -641,7 +831,7 @@
"external_id": "858339a44ead21c83257778ce60b4c352cd30d3b",
"image": "https://developer.newrelic.com/static/2c6d337608b38a3312b4fc740afe6167/7272b/developercenter.png",
"url": "https://developer.newrelic.com/explore-docs/nr1-cli/",
- "published_at": "2020-08-28T01:50:39Z",
+ "published_at": "2020-08-29T01:58:45Z",
"updated_at": "2020-08-18T01:50:36Z",
"document_type": "page",
"popularity": 1,
@@ -649,7 +839,7 @@
"body": "New Relic One CLI reference To build a New Relic One app, you must install the New Relic One CLI. The CLI helps you build, publish, and manage your New Relic app. We provide a variety of tools for building apps, including the New Relic One CLI (command line interface). This page explains how to use CLI commands to: Generate Nerdpack/Nerdlet templates Locally serve Nerdpacks (when developing) Publish and deploy Subscribe to Nerdpacks Add screenshots and metadata to the catalog Installing the New Relic One CLI In New Relic, click Apps and then in the New Relic One catalog area, click the Build your own application launcher and follow the quick start instructions. The quick start automatically generates an API key for the account you select, and gives you the pre-populated commands to create a profile, generate your first \"Hello World\" app, and serve it locally. Tip Use the NR1 VS Code extension to build your apps. New Relic One CLI Commands This table provides descriptions for the New Relic One commands. For more context, including usage and option details, click any individual command or the command category. For details on user permissions, see Authentication and permissions. For more on how to serve and publish your application, see our guide on Deploying your New Relic One app. Get started nr1 help Shows all nr1 commands or details about each command. nr1 update Updates to the latest version of the CLI. nr1 create Creates a new component from a template (Nerdpack, Nerdlet, launcher, or catalog). nr1 profiles Manages the profiles you use to run CLI commands. nr1 autocomplete Displays autocomplete installation instructions. nr1 nrql Fetches data using NRQL (New Relic query language). Configure your CLI preferences nr1 config:set Sets a specific configuration value. nr1 config:get Shows a specific configuration. nr1 config:list Lists your configuration choices. nr1 config:delete Removes the value of a specific configuration. Set up your Nerdpacks nr1 nerdpack:clone Clones an open source Nerdpack from our GitHub repository. nr1 nerdpack:serve Serves your Nerdpack for testing and development purposes. nr1 nerdpack:uuid Shows or regenerates the UUID of a Nerdpack. nr1 nerdpack:publish Publishes your Nerdpack to New Relic. nr1 nerdpack:deploy Deploys a Nerdpack version to a specific channel. nr1 nerdpack:undeploy Undeploys a Nerdpack version from a specific channel. Manage your Nerdpack subscriptions nr1 subscription:set Subscribes your account to a Nerdpack and channel. nr1 subscription:list Lists all the Nerdpacks your account is subscribed to. nr1 subscription:unset Unsubscribes your account from a Nerdpack. Install and manage plugins nr1 plugins:install Installs a plugin into the CLI. nr1 plugins:link Links a plugin into the CLI for development. nr1 plugins:update Updates your installed plugins. nr1 plugins:uninstall Removes a plugin from the CLI. Manage catalog information nr1 catalog:info Shows the Nerdpack info stored in the catalog. nr1 catalog:submit Gathers and submits the catalog info on the current folder.",
"_index": "520d1d5d14cc8a32e600034b",
"_type": "520d1d5d14cc8a32e600034c",
- "_score": 287.0752,
+ "_score": 279.93665,
"_version": null,
"_explanation": null,
"sort": null,
@@ -682,7 +872,7 @@
"external_id": "c45638a9cd548d1ffffc9f1c7708f115a92ae04a",
"image": "",
"url": "https://developer.newrelic.com/build-apps/set-up-dev-env/",
- "published_at": "2020-08-28T01:45:16Z",
+ "published_at": "2020-08-29T01:50:40Z",
"updated_at": "2020-08-26T01:47:20Z",
"document_type": "page",
"popularity": 1,
@@ -690,7 +880,7 @@
"body": "Set up your development environment 20 min If you've decided to build a custom app or modify one of our open source apps, you need a few essential tools: The New Relic One command line interface (CLI) An API key, which you get when you download the CLI Depending on what you want to do with your app, you might have some additional setup and configuration. This guide covers: Downloading the New Relic One CLI to build or modify apps Contribute content to this website Before you begin You must have: A github account account - While not strictly necessary for building apps, a GitHub account enables you to download and customize our open source apps, and contribute an open source project. A New Relic developer account - if you don't already have one, you can get a free trial account for developing New Relic applications. npm - If you've installed Node.js, then you already have npm, which is used to share, reuse, and update JavaScript code, and is necessary for working with React components that are the framework for New Relic apps and this website. A note on support Building a New Relic One application is the same as building any JavaScript/React application. We offer support to help with our building tools (our CLI and SDK library). However, we don't offer support for basic JavaScript or React coding questions or issues. For common questions and answers about building, see the Explorers Hub page on building on New Relic One. Tip Use the New Relic One VSCode extension to build your apps. Prepare to build or modify apps Step 1 of 1 Download the CLI and API key. On the Build New Relic One applications page, complete the Quick start steps. These six Quick start steps get you an API key for use with developing apps, and the New Relic One CLI, for building and deploying apps. At the end of the Quick start, you have a project consisting of the following: A Nerdpack - The package containing all the files required by your application. It contains two types of files that you customize to build your app: Nerdlets, and the launcher. One or more Nerdlet files - A specific UI view or window. A Nerdlet is a React JavaScript package that includes an index.js file, a stylesheet, and a JSON-format config file. It can contain any JS functionality (charts, interactive fields, tooltips, etc.). A launcher file: This is the basis for the launcher, which is used to open your application from New Relic One after you publish your app. Start building Step 1 of 1 If you're ready to code, cd to your Nerdpack and get started. If you want to learn more about building applications, try these step-by-step guides: Build a \"Hello, World!\" application shows how to create a little application, publish it to New Relic One, and share it with others by subscribing accounts to it. Map pageviews by region takes you through the steps to create one of our popular open source apps. You learn to add a custom query to an app and view it in a table, then add that data to a map. Contribute to developer.newrelic.com This site is open source, and we want your input. Create a pull request if you see a mistake you know how to fix. Drop us a GitHub issue if you see some content gaps you want us to work on. Or write up a whole new guide if you have one you'd like to share. Read on to learn how. Step 1 of 3 Fork the developer-website GithHub repo. Forking the repo enables you to work on your own copy of the developer.newrelic.com files, and build the site locally. It also enables us to more easily manage incomimg pull requests. On the developer-website page in GitHub, select the Fork button on the top right of the page, choose the account you want to fork to, and wait a few seconds while the fork is created. Sync regularly to keep your fork up to date with changes and additions to the main branch upstream. Step 2 of 3 Make a feature or documentation request. On any page, select the GitHub button at the top of the page, and then select the kind of change you want, and fill out the GitHub form. Step 3 of 3 Contribute a new guide. Check out our contributors guidelines, which will walk you through the process.",
"_index": "520d1d5d14cc8a32e600034b",
"_type": "520d1d5d14cc8a32e600034c",
- "_score": 204.67853,
+ "_score": 193.12405,
"_version": null,
"_explanation": null,
"sort": null,
@@ -713,7 +903,7 @@
"external_id": "471ed214caaf80c70e14903ec71411e2a1c03888",
"image": "",
"url": "https://developer.newrelic.com/explore-docs/newrelic-cli/",
- "published_at": "2020-08-28T01:50:39Z",
+ "published_at": "2020-08-29T01:57:43Z",
"updated_at": "2020-08-14T01:47:12Z",
"document_type": "page",
"popularity": 1,
@@ -721,7 +911,7 @@
"body": "New Relic CLI Reference The New Relic CLI enables the integration of New Relic into your existing workflows. Be it fetching data from your laptop while troubleshooting an issue, or adding New Relic into your CI/CD pipeline. New Relic CLI commands Find details for the New Relic CLI command docs in GitHub. Options --format string output text format [YAML, JSON, Text] (default \"JSON\") -h, --help help for newrelic --plain output compact text Copy Commands newrelic apm - Interact with New Relic APM newrelic completion - Generates shell completion functions newrelic config - Manage the configuration of the New Relic CLI newrelic documentation - Generate CLI documentation newrelic entity - Interact with New Relic entities newrelic nerdgraph - Execute GraphQL requests to the NerdGraph API newrelic nerdstorage - Read, write, and delete NerdStorage documents and collections. newrelic nrql - Commands for interacting with the New Relic Database newrelic profile - Manage the authentication profiles for this tool newrelic version - Show the version of the New Relic CLI newrelic workload - Interact with New Relic One workloads",
"_index": "520d1d5d14cc8a32e600034b",
"_type": "520d1d5d14cc8a32e600034c",
- "_score": 181.25343,
+ "_score": 177.47417,
"_version": null,
"_explanation": null,
"sort": null,
@@ -758,7 +948,7 @@
"nr1 nrql",
"Query using NRQL"
],
- "published_at": "2020-08-28T01:50:39Z",
+ "published_at": "2020-08-29T01:58:05Z",
"title": "New Relic One CLI common commands",
"updated_at": "2020-08-14T01:48:10Z",
"type": "developer",
@@ -769,7 +959,7 @@
"body": "New Relic One CLI common commands Here's a list of common commands to get you started with the New Relic One CLI. You can click any command to see its usage options and additional details about the command. Command Description nr1 help Shows all nr1 commands or details about each command. nr1 update Updates to the latest version of the CLI. nr1 create Creates a new component from a template (Nerdpack, Nerdlet, launcher, or catalog). nr1 profiles Manages the profiles you use to run CLI commands. nr1 autocomplete Displays autocomplete installation instructions. nr1 nrql Fetches data using NRQL (New Relic query language). See our other New Relic One CLI docs for commands specific to Nerdpack set-up, Nerdpack subscriptions, CLI configuration, plugins, or catalogs. Command details nr1 help See commands and get details Shows all nr1 commands by default. To get details about a specific command, run nr1 help COMMAND_NAME. Usage $ nr1 help Arguments COMMAND_NAME The name of a particular command. Examples $ nr1 help $ nr1 help nerdpack $ nr1 help nerdpack:deploy nr1 update Update your CLI Updates to latest version of the CLI. You can specify which channel to update if you'd like. Usage $ nr1 update Arguments CHANNEL The name of a particular channel. Examples $ nr1 update $ nr1 update somechannel nr1 create Create a new component Creates a new component from our template (either a Nerdpack, Nerdlet, launcher, or catalog). The CLI will walk you through this process. To learn more about Nerdpacks and their file structure, see Nerdpack file structure. For more on how to set up your Nerdpacks, see our Nerdpack CLI commands. Usage $ nr1 create Options -f, --force If present, overrides existing files without asking. -n, --name=NAME Names the component. -t, --type=TYPE Specifies the component type. --path=PATH The route to the component. --profile=PROFILE The authentication profile you want to use. --verbose Adds extra information to the output. nr1 profiles Manage your profiles keychain Displays a list of commands you can use to manage your profiles. Run nr1 help profiles:COMMAND for more on their specific usages. You can have more than one profile, which is helpful for executing commands on multiple New Relic accounts. To learn more about setting up profiles, see our Github workshop. Usage $ nr1 profiles:COMMAND Commands profiles:add Adds a new profile to your profiles keychain. profiles:default Chooses which profile should be default. profiles:list Lists the profiles on your keychain. profiles:remove Removes a profile from your keychain. nr1 autocomplete See autocomplete installation instructions Displays the autocomplete installation instructions. By default, the command displays the autocomplete instructions for zsh. If you want instructions for bash, run nr1 autocomplete bash. Usage $ nr1 autocomplete Arguments SHELL The shell type you want instructions for. Options -r, --refresh-cache Refreshes cache (ignores displaying instructions). Examples $ nr1 autocomplete $ nr1 autocomplete zsh $ nr1 autocomplete bash $ nr1 autocomplete --refresh-cache nr1 nrql Query using NRQL Fetches data from databases using a NRQL query. To learn more about NRQL and how to use it, see our NRQL docs. Usage $ nr1 nrql OPTION ... Options -a, --account=ACCOUNT The user account ID. required -q, --query=QUERY The NRQL query to run. required -u, --ugly Displays the content without tabs or spaces. --profile=PROFILE The authentication profile you want to use. --verbose Adds extra information to the output.",
"_index": "520d1d5d14cc8a32e600034b",
"_type": "520d1d5d14cc8a32e600034c",
- "_score": 166.26447,
+ "_score": 163.77849,
"_version": null,
"_explanation": null,
"sort": null,
@@ -801,7 +991,7 @@
"nr1 plugins:uninstall",
"Uninstall your plugin"
],
- "published_at": "2020-08-28T01:50:39Z",
+ "published_at": "2020-08-29T01:58:45Z",
"title": "New Relic One CLI plugin commands",
"updated_at": "2020-08-14T01:50:34Z",
"type": "developer",
@@ -812,7 +1002,7 @@
"body": "New Relic One CLI plugin commands To install and manage your plugins, use the commands below. You can click any command to see its usage options and additional details about the command. Command Description nr1 plugins:install Installs a plugin into the CLI. nr1 plugins:link Links a plugin into the CLI for development. nr1 plugins:update Updates your installed plugins. nr1 plugins:uninstall Removes a plugin from the CLI. Command details nr1 plugins:install Install a plugin Installs a plugin into the CLI. You can install plugins from npm or a Git URL. Please note that installing a plugin will override the core plugin. For example, if you have a core plugin that has a 'hello' command, then installing a plugin with a 'hello' command will override the core plugin implementation. This is useful if you want to update the core plugin functionality without patching and updating the whole CLI. Usage $ nr1 plugins:install PLUGIN Arguments PLUGIN: the name, path, or URL of the plugin you want to install. required Options -f, --force Runs yarn install --force. This forces a re-download of all the plugin's packages. -h, --help Shows CLI help. --verbose Adds extra information to the output. Examples $ nr1 plugins:install myplugin $ nr1 plugins:install https://github.com/someuser/someplugin $ nr1 plugins:install someuser/someplugin Aliases $ nr1 plugins:add nr1 plugins:link Link your plugin Links a local plugin into the CLI for development. Please note that linking a plugin will override your user-installed plugin or core plugin. For example, if you have a user-installed or core plugin that has a 'hello' command, linking a plugin with a 'hello' command will override the user-installed or core plugin implementation. This is useful for development work. Usage $ nr1 plugins:link PLUGIN Arguments PLUGIN: the name, path, or URL of the plugin you want to link. required Options -h, --help Shows CLI help. --verbose Adds extra information to the output. Examples $ nr1 plugins:link myplugin $ nr1 plugins:link someuser/someplugin nr1 plugins:update Update your plugins Updates all of your installed plugins. Usage $ nr1 plugins:update Options -h, --help Shows CLI help. --verbose Adds extra information to the output. nr1 plugins:uninstall Uninstall your plugin Removes a plugin from the CLI. Usage $ nr1 plugins:uninstall PLUGIN Arguments PLUGIN: the name of the plugin you want to uninstall. required Options -h, --help Shows CLI help. --verbose Adds extra information to the output. Aliases $ nr1 plugins:unlink $ nr1 plugins:remove",
"_index": "520d1d5d14cc8a32e600034b",
"_type": "520d1d5d14cc8a32e600034c",
- "_score": 150.3096,
+ "_score": 147.91876,
"_version": null,
"_explanation": null,
"sort": null,
@@ -825,157 +1015,106 @@
"id": "5f28bd6a196a670ddd19d000"
}
],
- "/explore-docs/nr1-nerdpack": [
+ "/explore-docs/intro-to-sdk": [
{
"image": "",
- "url": "https://developer.newrelic.com/explore-docs/nr1-subscription/",
+ "url": "https://developer.newrelic.com/build-apps/",
"sections": [
- "New Relic One CLI subscription commands",
- "Command details",
- "nr1 subscription:set",
- "Subscribe to a Nerdpack",
- "Usage",
- "Options",
- "Aliases",
- "nr1 subscription:list",
- "See your subscription",
- "nr1 subscription:unset",
- "Unsubscribe from a Nerdpack"
+ "Build apps",
+ "Guides to build apps",
+ "Create a \"Hello, World!\" application",
+ "Permissions for managing applications",
+ "Set up your development environment",
+ "Add, query, and mutate data using NerdStorage",
+ "Add the NerdGraphQuery component to an application",
+ "Add a time picker to your app",
+ "Add a table to your app",
+ "Publish and deploy apps",
+ "Create a custom map view"
],
- "published_at": "2020-08-28T01:51:50Z",
- "title": "New Relic One CLI subscription commands",
- "updated_at": "2020-08-06T01:44:54Z",
+ "published_at": "2020-08-29T01:50:40Z",
+ "title": "Build apps",
+ "updated_at": "2020-08-29T01:50:40Z",
"type": "developer",
- "external_id": "12d2e1b06dede5b1272527f95a14518010aecc58",
+ "external_id": "abafbb8457d02084a1ca06f3bc68f7ca823edf1d",
"document_type": "page",
"popularity": 1,
- "info": "An overview of the CLI commands you can use to manage your Nerdpack subscriptions.",
- "body": "New Relic One CLI subscription commands To manage your Nerdpack subscriptions, use the commands below. You can click any command to see its usage options and additional details about the command. Command Description nr1 subscription:set Subscribes your account to a Nerdpack and channel. nr1 subscription:list Lists all the Nerdpacks your account is subscribed to. nr1 subscription:unset Unsubscribes your account from a Nerdpack. Command details nr1 subscription:set Subscribe to a Nerdpack Subscribes your account to a specific Nerdpack and channel. This command can be run with a Nerdpack UUID or within a specific Nerdpack folder. By default, the command uses the Nerdpack ID in package.json and subscribes to the STABLE channel. An account can only be subscribed to one Nerdpack and channel at a time. Usage $ nr1 subscription:set Options -i, --nerdpack-id=NERDPACK_ID Specifies the Nerdpack to subscribe to. By default, the command will use the one in package.json. -c, --channel=DEV/BETA/STABLE Specifies the channel to subscribe to. [default: STABLE] --profile=PROFILE The authentication profile you want to use. --verbose Adds extra information to the output. Aliases $ nr1 nerdpack:subscribe nr1 subscription:list See your subscription Lists all the Nerdpacks your account is subscribed to. Your account is linked to your API key. Usage $ nr1 subscription:list Options --profile=PROFILE The authentication profile you want to use. --verbose Adds extra information to the output. nr1 subscription:unset Unsubscribe from a Nerdpack Unsubscribes your account from a specific Nerdpack. When this command is executed within a Nerdpack folder, the Nerdpack ID from package.json is used by default. Usage $ nr1 subscription:unset Options -i, --nerdpack-id=NERDPACK_ID Specifies the Nerdpack to subscribe to. By default, the command will use the one in package.json. --profile=PROFILE The authentication profile you want to use. --verbose Adds extra information to the output. Aliases $ nr1 nerdpack:unsubscribe $ nr1 subscription:delete $ nr1 subscription:remove $ nr1 subscription:rm",
+ "body": "Build apps You know better than anyone what information is crucial to your business, and how best to visualize it. Sometimes, this means going beyond dashboards to creating your own app. With React and GraphQL, you can create custom views tailored to your business. These guides are designed to help you start building apps, and dive into our library of components. We also have a growing number of open source apps that you can use to get started. The rest is up to you. Guides to build apps 15 min Create a \"Hello, World!\" application Build a \"Hello, World!\" app and publish it to New Relic One Permissions for managing applications Learn about permissions for subscribing to apps 20 min Set up your development environment Prepare to build apps and contribute to this site 45 min Add, query, and mutate data using NerdStorage NerdStorage is a document database accessible within New Relic One. It allows you to modify, save, and retrieve documents from one session to the next. 20 minutes Add the NerdGraphQuery component to an application The NerdGraphQuery component allows you to query data from your account and add it to a dropdown menu in an application 20 min Add a time picker to your app Add a time picker to a sample application 30 min Add a table to your app Add a table to your New Relic One app 30 min Publish and deploy apps Start sharing the apps you build 30 min Create a custom map view Build an app to show page view data on a map",
+ "info": "",
"_index": "520d1d5d14cc8a32e600034b",
"_type": "520d1d5d14cc8a32e600034c",
- "_score": 976.4684,
+ "_score": 868.25354,
"_version": null,
"_explanation": null,
"sort": null,
"highlight": {
- "title": "NewRelicOneCLI subscription commands",
- "sections": "NewRelicOneCLI subscription commands",
- "info": "An overview of the CLIcommands you can use to manage your Nerdpack subscriptions.",
- "body": "NewRelicOneCLI subscription commands To manage your Nerdpack subscriptions, use the commands below. You can click any command to see its usage options and additional details about the command. Command Description nr1 subscription:set Subscribes your account to a Nerdpack and channel. nr1"
+ "title": "Build apps",
+ "sections": "Publish and deploy apps",
+ "body": " you start building apps, and dive into our library of components. We also have a growing number of open source apps that you can use to get started. The rest is up to you. Guides to build apps 15 min Create a "Hello, World!" application Build a "Hello, World!" app and publish it to NewRelicOne"
},
- "id": "5f2b6096e7b9d225ebc9de6f"
+ "id": "5efa999d64441fc0f75f7e21"
},
{
- "image": "",
- "url": "https://developer.newrelic.com/explore-docs/nr1-common/",
"sections": [
- "New Relic One CLI common commands",
- "Command details",
- "nr1 help",
- "See commands and get details",
- "Usage",
- "Arguments",
- "Examples",
- "nr1 update",
- "Update your CLI",
- "nr1 create",
- "Create a new component",
- "Options",
- "nr1 profiles",
- "Manage your profiles keychain",
- "Commands",
- "nr1 autocomplete",
- "See autocomplete installation instructions",
- "nr1 nrql",
- "Query using NRQL"
+ "Intro to NerdStorage",
+ "Use NerdStorage in your apps",
+ "Data model",
+ "Limits",
+ "Data access",
+ "Permissions for working with NerdStorage"
],
- "published_at": "2020-08-28T01:50:39Z",
- "title": "New Relic One CLI common commands",
- "updated_at": "2020-08-14T01:48:10Z",
+ "title": "Intro to NerdStorage",
"type": "developer",
- "external_id": "503e515e1095418f8d19329517344ab209d143a4",
+ "tags": [
+ "nerdstorage",
+ "nerdstorage components",
+ "new relic one apps",
+ "data access"
+ ],
+ "external_id": "709e06c25376d98b2191ca369b4d139e5084bd62",
+ "image": "",
+ "url": "https://developer.newrelic.com/explore-docs/nerdstorage/",
+ "published_at": "2020-08-29T01:59:18Z",
+ "updated_at": "2020-08-14T01:50:34Z",
"document_type": "page",
"popularity": 1,
- "info": "An overview of common commands you can use with the New Relic One CLI.",
- "body": "New Relic One CLI common commands Here's a list of common commands to get you started with the New Relic One CLI. You can click any command to see its usage options and additional details about the command. Command Description nr1 help Shows all nr1 commands or details about each command. nr1 update Updates to the latest version of the CLI. nr1 create Creates a new component from a template (Nerdpack, Nerdlet, launcher, or catalog). nr1 profiles Manages the profiles you use to run CLI commands. nr1 autocomplete Displays autocomplete installation instructions. nr1 nrql Fetches data using NRQL (New Relic query language). See our other New Relic One CLI docs for commands specific to Nerdpack set-up, Nerdpack subscriptions, CLI configuration, plugins, or catalogs. Command details nr1 help See commands and get details Shows all nr1 commands by default. To get details about a specific command, run nr1 help COMMAND_NAME. Usage $ nr1 help Arguments COMMAND_NAME The name of a particular command. Examples $ nr1 help $ nr1 help nerdpack $ nr1 help nerdpack:deploy nr1 update Update your CLI Updates to latest version of the CLI. You can specify which channel to update if you'd like. Usage $ nr1 update Arguments CHANNEL The name of a particular channel. Examples $ nr1 update $ nr1 update somechannel nr1 create Create a new component Creates a new component from our template (either a Nerdpack, Nerdlet, launcher, or catalog). The CLI will walk you through this process. To learn more about Nerdpacks and their file structure, see Nerdpack file structure. For more on how to set up your Nerdpacks, see our Nerdpack CLI commands. Usage $ nr1 create Options -f, --force If present, overrides existing files without asking. -n, --name=NAME Names the component. -t, --type=TYPE Specifies the component type. --path=PATH The route to the component. --profile=PROFILE The authentication profile you want to use. --verbose Adds extra information to the output. nr1 profiles Manage your profiles keychain Displays a list of commands you can use to manage your profiles. Run nr1 help profiles:COMMAND for more on their specific usages. You can have more than one profile, which is helpful for executing commands on multiple New Relic accounts. To learn more about setting up profiles, see our Github workshop. Usage $ nr1 profiles:COMMAND Commands profiles:add Adds a new profile to your profiles keychain. profiles:default Chooses which profile should be default. profiles:list Lists the profiles on your keychain. profiles:remove Removes a profile from your keychain. nr1 autocomplete See autocomplete installation instructions Displays the autocomplete installation instructions. By default, the command displays the autocomplete instructions for zsh. If you want instructions for bash, run nr1 autocomplete bash. Usage $ nr1 autocomplete Arguments SHELL The shell type you want instructions for. Options -r, --refresh-cache Refreshes cache (ignores displaying instructions). Examples $ nr1 autocomplete $ nr1 autocomplete zsh $ nr1 autocomplete bash $ nr1 autocomplete --refresh-cache nr1 nrql Query using NRQL Fetches data from databases using a NRQL query. To learn more about NRQL and how to use it, see our NRQL docs. Usage $ nr1 nrql OPTION ... Options -a, --account=ACCOUNT The user account ID. required -q, --query=QUERY The NRQL query to run. required -u, --ugly Displays the content without tabs or spaces. --profile=PROFILE The authentication profile you want to use. --verbose Adds extra information to the output.",
+ "info": "Intro to NerdStorage on New Relic One",
+ "body": "Intro to NerdStorage 30 min To help you build a New Relic One application, we provide you with the New Relic One SDK. On this page, you’ll learn how to use NerdStorage SDK components. Use NerdStorage in your apps NerdStorage is used to store and retrieve simple sets of data, including users's configuration settings and preferences (like favorites), or any other small data sets. This storage is unique per Nerdpack, and can't be shared with any other Nerdpack. NerdStorage can be classified into three categories: User storage: Data that is attached to a particular user. If you’re authenticated as the user the data is attached to, you can read it and write it. Account storage: Data that is attached to a particular account. If you’re authenticated and can access the account, you can read and write to account scoped NerdStorage. Visibility of account data is also determined by master/subaccount rules: If a user has access to the master account, then they also have access to data in all subaccounts. Entity storage: Data that is attached to a particular entity. If you can see the corresponding entity, you can read and write data on that entity. Data model You can imagine NerdStorage as a nested key-value map. Data is inside documents, which are nested inside collections: { 'YourNerdpackUuid': { 'collection-1': { 'document-1-of-collection-1': '{\"lastNumber\": 42, \"another\": [1]}', 'document-2-of-collection-1': '\"userToken\"', // ... }, 'another-collection': { 'fruits': '[\"pear\", \"apple\"]', // ... }, // ... }, } Copy Each NerdStorage level has different properties and purpose: Collections: From a Nerdpack, you can create multiple collections by naming each of them. Inside a collection you can put one or more documents. Think of a collection as key-value storage, where each document is a key-value pair. Documents: A document is formed by an identifier (documentId) and a set of data associated with it. Data associated with a document: NerdStorage accepts any sort of data associated to a documentId. Query and mutation components that are provided work by serializing and deserializing JSON. Limits A Nerdpack can hold up to 1,000 collections and 10,000 documents, plus storage type. A collection can hold up to 1,000 documents, plus storage type. Each document can have a maximum length of 64 KiB when serialized. Data access To access NerdStorage, you can run NerdGraph queries, or use the provided storage queries. Depending on which storage you want to access, you can use a different set of SDK components: User access: UserStorageQuery and UserStorageMutation Account access: AccountStorageQuery and AccountStorageMutation Entity access: EntityStorageQuery and EntityStorageMutation Each of these components can operate declaratively (for example, as part of your React rendering methods) or imperatively (by using the static methods for query and mutation). For more information on this, see Data querying and mutations. Permissions for working with NerdStorage In order to persist changes on NerdStorage, such as creating, updating, and deleting account and entity storage, you must have a user role with permission to persist changes.",
"_index": "520d1d5d14cc8a32e600034b",
"_type": "520d1d5d14cc8a32e600034c",
- "_score": 756.32654,
+ "_score": 762.49036,
"_version": null,
"_explanation": null,
"sort": null,
"highlight": {
- "title": "NewRelicOneCLI common commands",
- "sections": "NewRelicOneCLI common commands",
- "info": "An overview of common commands you can use with the NewRelicOneCLI.",
- "body": " (NewRelic query language). See our other NewRelicOneCLI docs for commands specific to Nerdpack set-up, Nerdpack subscriptions, CLI configuration, plugins, or catalogs. Command details nr1 help See commands and get details Shows all nr1 commands by default. To get details about a specific command"
+ "sections": "Use NerdStorage in your apps",
+ "info": "Intro to NerdStorage on NewRelicOne",
+ "tags": "newreliconeapps",
+ "body": "Intro to NerdStorage 30 min To help you build a NewRelicOne application, we provide you with the NewRelicOneSDK. On this page, you’ll learn how to use NerdStorageSDKcomponents. Use NerdStorage in your apps NerdStorage is used to store and retrieve simple sets of data, including users"
},
- "id": "5f28bd6ae7b9d267996ade94"
+ "id": "5efa989ee7b9d2048e7bab92"
},
{
"sections": [
- "New Relic One CLI reference",
- "Installing the New Relic One CLI",
+ "Set up your development environment",
+ "Before you begin",
+ "A note on support",
"Tip",
- "New Relic One CLI Commands",
- "Get started",
- "Configure your CLI preferences",
- "Set up your Nerdpacks",
- "Manage your Nerdpack subscriptions",
- "Install and manage plugins",
- "Manage catalog information"
+ "Prepare to build or modify apps",
+ "Start building",
+ "Contribute to developer.newrelic.com"
],
- "title": "New Relic One CLI reference",
+ "title": "Set up your development environment",
"type": "developer",
"tags": [
- "New Relic One app",
- "nerdpack commands"
- ],
- "external_id": "858339a44ead21c83257778ce60b4c352cd30d3b",
- "image": "https://developer.newrelic.com/static/2c6d337608b38a3312b4fc740afe6167/7272b/developercenter.png",
- "url": "https://developer.newrelic.com/explore-docs/nr1-cli/",
- "published_at": "2020-08-28T01:50:39Z",
- "updated_at": "2020-08-18T01:50:36Z",
- "document_type": "page",
- "popularity": 1,
- "info": "An overview of the CLI to help you build, deploy, and manage New Relic apps.",
- "body": "New Relic One CLI reference To build a New Relic One app, you must install the New Relic One CLI. The CLI helps you build, publish, and manage your New Relic app. We provide a variety of tools for building apps, including the New Relic One CLI (command line interface). This page explains how to use CLI commands to: Generate Nerdpack/Nerdlet templates Locally serve Nerdpacks (when developing) Publish and deploy Subscribe to Nerdpacks Add screenshots and metadata to the catalog Installing the New Relic One CLI In New Relic, click Apps and then in the New Relic One catalog area, click the Build your own application launcher and follow the quick start instructions. The quick start automatically generates an API key for the account you select, and gives you the pre-populated commands to create a profile, generate your first \"Hello World\" app, and serve it locally. Tip Use the NR1 VS Code extension to build your apps. New Relic One CLI Commands This table provides descriptions for the New Relic One commands. For more context, including usage and option details, click any individual command or the command category. For details on user permissions, see Authentication and permissions. For more on how to serve and publish your application, see our guide on Deploying your New Relic One app. Get started nr1 help Shows all nr1 commands or details about each command. nr1 update Updates to the latest version of the CLI. nr1 create Creates a new component from a template (Nerdpack, Nerdlet, launcher, or catalog). nr1 profiles Manages the profiles you use to run CLI commands. nr1 autocomplete Displays autocomplete installation instructions. nr1 nrql Fetches data using NRQL (New Relic query language). Configure your CLI preferences nr1 config:set Sets a specific configuration value. nr1 config:get Shows a specific configuration. nr1 config:list Lists your configuration choices. nr1 config:delete Removes the value of a specific configuration. Set up your Nerdpacks nr1 nerdpack:clone Clones an open source Nerdpack from our GitHub repository. nr1 nerdpack:serve Serves your Nerdpack for testing and development purposes. nr1 nerdpack:uuid Shows or regenerates the UUID of a Nerdpack. nr1 nerdpack:publish Publishes your Nerdpack to New Relic. nr1 nerdpack:deploy Deploys a Nerdpack version to a specific channel. nr1 nerdpack:undeploy Undeploys a Nerdpack version from a specific channel. Manage your Nerdpack subscriptions nr1 subscription:set Subscribes your account to a Nerdpack and channel. nr1 subscription:list Lists all the Nerdpacks your account is subscribed to. nr1 subscription:unset Unsubscribes your account from a Nerdpack. Install and manage plugins nr1 plugins:install Installs a plugin into the CLI. nr1 plugins:link Links a plugin into the CLI for development. nr1 plugins:update Updates your installed plugins. nr1 plugins:uninstall Removes a plugin from the CLI. Manage catalog information nr1 catalog:info Shows the Nerdpack info stored in the catalog. nr1 catalog:submit Gathers and submits the catalog info on the current folder.",
- "_index": "520d1d5d14cc8a32e600034b",
- "_type": "520d1d5d14cc8a32e600034c",
- "_score": 329.28058,
- "_version": null,
- "_explanation": null,
- "sort": null,
- "highlight": {
- "title": "NewRelicOneCLI reference",
- "sections": "NewRelicOneCLICommands",
- "info": "An overview of the CLI to help you build, deploy, and manage NewRelic apps.",
- "tags": "NewRelicOne app",
- "body": ". For more on how to serve and publish your application, see our guide on Deploying your NewRelicOne app. Get started nr1 help Shows all nr1 commands or details about each command. nr1 update Updates to the latest version of the CLI. nr1 create Creates a new component from a template (Nerdpack, Nerdlet"
- },
- "id": "5efa989e28ccbc535a307dd0"
- },
- {
- "sections": [
- "Set up your development environment",
- "Before you begin",
- "A note on support",
- "Tip",
- "Prepare to build or modify apps",
- "Start building",
- "Contribute to developer.newrelic.com"
- ],
- "title": "Set up your development environment",
- "type": "developer",
- "tags": [
- "developer account",
- "API key",
- "New Relic One CLI"
+ "developer account",
+ "API key",
+ "New Relic One CLI"
],
"external_id": "c45638a9cd548d1ffffc9f1c7708f115a92ae04a",
"image": "",
"url": "https://developer.newrelic.com/build-apps/set-up-dev-env/",
- "published_at": "2020-08-28T01:45:16Z",
+ "published_at": "2020-08-29T01:50:40Z",
"updated_at": "2020-08-26T01:47:20Z",
"document_type": "page",
"popularity": 1,
@@ -983,523 +1122,539 @@
"body": "Set up your development environment 20 min If you've decided to build a custom app or modify one of our open source apps, you need a few essential tools: The New Relic One command line interface (CLI) An API key, which you get when you download the CLI Depending on what you want to do with your app, you might have some additional setup and configuration. This guide covers: Downloading the New Relic One CLI to build or modify apps Contribute content to this website Before you begin You must have: A github account account - While not strictly necessary for building apps, a GitHub account enables you to download and customize our open source apps, and contribute an open source project. A New Relic developer account - if you don't already have one, you can get a free trial account for developing New Relic applications. npm - If you've installed Node.js, then you already have npm, which is used to share, reuse, and update JavaScript code, and is necessary for working with React components that are the framework for New Relic apps and this website. A note on support Building a New Relic One application is the same as building any JavaScript/React application. We offer support to help with our building tools (our CLI and SDK library). However, we don't offer support for basic JavaScript or React coding questions or issues. For common questions and answers about building, see the Explorers Hub page on building on New Relic One. Tip Use the New Relic One VSCode extension to build your apps. Prepare to build or modify apps Step 1 of 1 Download the CLI and API key. On the Build New Relic One applications page, complete the Quick start steps. These six Quick start steps get you an API key for use with developing apps, and the New Relic One CLI, for building and deploying apps. At the end of the Quick start, you have a project consisting of the following: A Nerdpack - The package containing all the files required by your application. It contains two types of files that you customize to build your app: Nerdlets, and the launcher. One or more Nerdlet files - A specific UI view or window. A Nerdlet is a React JavaScript package that includes an index.js file, a stylesheet, and a JSON-format config file. It can contain any JS functionality (charts, interactive fields, tooltips, etc.). A launcher file: This is the basis for the launcher, which is used to open your application from New Relic One after you publish your app. Start building Step 1 of 1 If you're ready to code, cd to your Nerdpack and get started. If you want to learn more about building applications, try these step-by-step guides: Build a \"Hello, World!\" application shows how to create a little application, publish it to New Relic One, and share it with others by subscribing accounts to it. Map pageviews by region takes you through the steps to create one of our popular open source apps. You learn to add a custom query to an app and view it in a table, then add that data to a map. Contribute to developer.newrelic.com This site is open source, and we want your input. Create a pull request if you see a mistake you know how to fix. Drop us a GitHub issue if you see some content gaps you want us to work on. Or write up a whole new guide if you have one you'd like to share. Read on to learn how. Step 1 of 3 Fork the developer-website GithHub repo. Forking the repo enables you to work on your own copy of the developer.newrelic.com files, and build the site locally. It also enables us to more easily manage incomimg pull requests. On the developer-website page in GitHub, select the Fork button on the top right of the page, choose the account you want to fork to, and wait a few seconds while the fork is created. Sync regularly to keep your fork up to date with changes and additions to the main branch upstream. Step 2 of 3 Make a feature or documentation request. On any page, select the GitHub button at the top of the page, and then select the kind of change you want, and fill out the GitHub form. Step 3 of 3 Contribute a new guide. Check out our contributors guidelines, which will walk you through the process.",
"_index": "520d1d5d14cc8a32e600034b",
"_type": "520d1d5d14cc8a32e600034c",
- "_score": 274.24878,
+ "_score": 668.3186,
"_version": null,
"_explanation": null,
"sort": null,
"highlight": {
- "tags": "NewRelicOneCLI",
- "body": "Set up your development environment 20 min If you've decided to build a custom app or modify one of our open source apps, you need a few essential tools: The NewRelicOnecommand line interface (CLI) An API key, which you get when you download the CLI Depending on what you want to do with your app"
+ "sections": "Prepare to build or modify apps",
+ "info": "Prepare to build appsand contribute to this site",
+ "tags": "NewRelicOne CLI",
+ "body": ", publish it to NewRelicOne, and share it with others by subscribing accounts to it. Map pageviews by region takes you through the steps to create one of our popular open source apps. You learn to add a custom query to an app and view it in a table, then add that data to a map. Contribute"
},
"id": "5efa9973e7b9d242237bab39"
},
{
"sections": [
- "Serve, publish, and deploy your New Relic One app",
- "Before you begin",
- "Serve your app locally",
- "Add images and metadata to your apps",
- "screenshots folder",
- "documentation.md",
- "additionalInfo.md",
- "config.json",
- "Publish your app",
- "Deploy your app",
- "Subscribe or unsubsribe apps",
- "Handle duplicate applications"
+ "Query and store data",
+ "Components overview",
+ "Query components",
+ "Mutation components",
+ "Static methods",
+ "NrqlQuery"
],
- "title": "Serve, publish, and deploy your New Relic One app",
+ "title": "Query and store data",
"type": "developer",
"tags": [
- "publish apps",
- "deploy apps",
- "subscribe apps",
- "add metadata apps"
+ "nerdgraph query components",
+ "mutation components",
+ "static methods"
],
- "external_id": "63283ee8efdfa419b6a69cb8bd135d4bc2188d2c",
- "image": "https://developer.newrelic.com/static/f6d5070509ac08ec96c6c522d5109471/b01d9/apps_catalog.png",
- "url": "https://developer.newrelic.com/build-apps/publish-deploy/",
- "published_at": "2020-08-28T01:51:50Z",
- "updated_at": "2020-08-26T01:50:42Z",
+ "external_id": "cbbf363393edeefbc4c08f9754b43d38fd911026",
+ "image": "",
+ "url": "https://developer.newrelic.com/explore-docs/query-and-store-data/",
+ "published_at": "2020-08-29T01:58:45Z",
+ "updated_at": "2020-08-01T01:42:02Z",
"document_type": "page",
"popularity": 1,
- "info": "Start sharing and using the custom New Relic One apps you build",
- "body": "Serve, publish, and deploy your New Relic One app 30 min When you build a New Relic One app, chances are you'll want to share it with others in your organization. You might even want to share it broadly through our open source channel. But first, you probably want to try it out locally to make sure it's working properly. From the New Relic One Apps page, you can review available apps and subscribe to the ones you want for accounts you manage. The Other apps section shows launchers for New Relic apps, as well as any third-party apps that you subscribe to. The New Relic One catalog provides apps that you haven't subscribed to, some developed by New Relic engineers to provide visualizations we think you'll want, like Cloud Optimizer, which analyzes your cloud environment, or PageView Map, which uses Browser events to chart performance across geographies. Other apps in the catalog are created by third-party contributors and are submitted via opensource.newrelic.com. All are intended to help you visualize the data you need, the way you want it. Here, you learn to: Serve your app locally Add images and metadata to your app Publish it Subscribe and unsubscribe accounts you manage to the app Handle duplicate applications Before you begin This guide requires the following: A New Relic One app or Nerdpack New Relic One CLI A Nerdpack manager role for publishing, deploying, and subscribing apps. Serve your app locally You can locally serve the app you create to New Relic One to test it out. Step 1 of 1 In the parent root folder of your Nerdpack, run nr1 nerdpack:serve. Go to one.newrelic.com/?nerdpacks=local. The ?nerdpacks=local URL suffix will load any locally served Nerdpacks that are available. When you make a change to a locally served Nerdpack, New Relic One will automatically reload it. Add images and metadata to your apps Application creators can include a description of what their apps do and how they're best used when they build an app. They can also include screenshots, icons, and metadata that help to make them easy to spot amongst other applications. Some metadata is added automatically when an app is published: Related entities, listed if there are any. Origin label to indicate where the app comes from: local, custom, or public. The New Relic One CLI enables you to provide the information and images you want to include with your application. Then it's a matter of kicking off a catalog command that validates the information and saves it to the catalog. Step 1 of 3 Update the New Relic One CLI to ensure you're working with the latest version. nr1 update Copy Step 2 of 3 Add catalog metadata and screenshots. Run nr1 create and then select catalog to add a catalog folder to your New Relic One project. The folder contains the following empty files and folder. Add the information as described in the following table for the process to succeed. screenshots folder A directory that must contain no more than 6 images and meet these criteria: 3:2 aspect ratio PNG format landscape orientation 1600 to 2400 pixels wide documentation.md A markdown file that presents usage information pulled into the Documentation tab for the application in the catalog. additionalInfo.md An optional markdown file for any additional information about using your application. config.json A JSON file that contains the following fields: tagline: A brief headline for the application. Must not exceed 30 characters. repository: The URL to the GitHub repo for the application. Must not exceed 1000 characters. details: Describes the purpose of the application and how to use it. Information must not exceed 1000. Use carriage returns for formatting. Do not include any markdown or HTML. support: An object that contains: issues: A valid URL to the GitHub repository's issues list, generally the GitHub Issues tab for the repo. email: A valid email address for the team supporting the application. community: URL to a support thread, forum, or website for troubleshooting and usage support. whatsNew: A bulleted list of changes in this version. Must not exceed 500 characters. Use carriage returns for formatting. Do not include markdown or HTML. Example: { \"tagline\": \"Map your workloads & entities\", \"repository\": \"https://github.com/newrelic/nr1-workload-geoops.git\", \"details\": \"Describe, consume, and manage Workloads and Entities in a geographic model that supports location-specific KPI's, custom metadata, drill-down navigation into Entities and Workloads, real-time configuration, and configuration via automation using the newrelic-cli.\", \"support\": { \"issues\": { \"url\": \"https://github.com/newrelic/nr1-workload-geoops/issues\" }, \"email\": { \"address\": \"opensource+nr1-workload-geoops@newrelic.com\" }, \"community\": { \"url\": \"https://discuss.newrelic.com/t/workload-geoops-nerdpack/99478\" } }, \"whatsNew\": \"\\n-Feat: Geographic mapping of Workloads and Entities\\n-Feat: Programmatic alerting rollup of underlying Entities\\n-Feat: Custom KPI measurement per location\\n-Feat: Empty-state edit workflow\\n-Feat: JSON file upload format\\n-Feat: Published (in open source docs) guide to automating configuration using the newrelic-cli\" } Copy Step 3 of 3 Save the metadata and screenshots to the catalog. This validates the information you added to the catalog directory against the criteria described in the previous step, and saves it to the catalog. nr1 catalog:submit Copy Publish your app Publishing places your Nerdpack in New Relic One. To publish or deploy, you must be a Nerdpack manager. Step 1 of 1 To publish your Nerdpack, run nr1 nerdpack:publish. Deploy your app Deploying is applying a Nerdpack version to a specific channel (for example, BETA, or STABLE). A channel can only have one Nerdpack version deployed to it at one time. If a channel has an existing Nerdpack associated with it, deploying a new Nerdpack version to that channel will undeploy the previous one. Channels are meant to be an easier way to control application version access than having to be concerned with specific version numbers. Step 1 of 1 To deploy an application, run nr1 nerdpack:deploy. Subscribe or unsubsribe apps Whether you want to subscribe accounts to an app you've created or to apps already available in the catalog, the process is the same. Note that if you subscribe to an app in the catalog, you'll automatically get any updates that are added to the app. To learn about the appropriate permissions for subscribing, see Permissions for managing applications. Step 1 of 2 Subscribe accounts to an application. Select an application you want to add to your New Relic account. Click Add this app. Note that this button says Manage access if the app has already been subscribed to an account you manage. On the Account access page listing the accounts you can subscribe to an application: Select the accounts you want to subscribe the app to. Choose the channel you want to subscribe the app to, Stable or Dev. This can only be Stable for the public apps created by New Relic. Click the update button. Now you and members of the accounts you have subscribed to the app can launch it from New Relic One. Step 2 of 2 Unsubsribe from an application. On the Apps page, open the app you want to unsubscribe. Click Manage access. Clear the check box for any accounts you want to unsubscribe, and then click the update button. The application is no longer listed in the Other apps section of the Apps page, and you have unsubscribed. Handle duplicate applications You might end up with duplicate applications on your New Relic One Apps page. This can happen when you subscribe to the same app using both the CLI and the catalog. Or if you clone an app, modify, and deploy it, but keep the original name. You can manage duplicates with the catalog. Good to know before you start: You need a user role with the ability to manage Nerdpacks for accounts that you want to unsubscribe and undeploy from applications. You can't remove the public apps. When a duplicate application has no accounts subscribed to it, you undeploy it. For applications that have accounts subscribed to them, you unscubscribe and undeploy. The unsubscribe and undeploy process happens in a batch. To remove an account from an application, but ensure that other accounts continue to be subscribed, select the checkbox, Resubscribe these accounts to the new application. Step 1 of 1 Remove duplicates. In the New Relic One catalog, click a public application that has one or more duplicates. (You can only manage duplicates from the public version of the application.) On the application information page, select Clean up applications. Review the information about the application that's open, as well as any duplicates. Click Manage app for duplicates you want to remove. If needed, select Resubscribe these accounts to the new application. Click Unsubscribe and undeploy, and agree to the terms and conditions.",
+ "info": "Reference guide for SDK query components using NerdGraph",
+ "body": "Query and store data 10 min To help you build a New Relic One application, we provide you with the New Relic One SDK. Here you can learn how to use the SDK query components, which allow you to make queries and mutations via NerdGraph, our GraphQL endpoint. Query-related React components can be identified by the Query suffix. Mutation-related components can be identified by the Mutation prefix. Components overview Our data components are based on React Apollo. The most basic component is NerdGraphQuery, which accepts any GraphQL (or GraphQL AST generated by the graphql-tag library as the query parameter, and a set of query variables passed as variables. Over this query, we have created an additional set of queries, which can be divided into four groups: User queries: These allow you to query the current user and its associated accounts. Components in this category: UserStorageQuery and AccountsQuery. Entities queries: Because New Relic One is entity-centric, we use queries to make access to your entities easier. You can count, search, list, query, and favorite them. Components in this category: EntityCountQuery, EntitySearchQuery, EntitiesByDomainTypeQuery, EntitiesByGuidsQuery, EntityByGuidQuery, EntityByNameQuery. Storage queries: New Relic One provides a simple storage mechanism that we call NerdStorage. This can be used by Nerdpack creators to store application configuration setting data, user-specific data, and other small pieces of data. Components in this category: UserStorageQuery, AccountStorageQuery, EntityStorageQuery, UserStorageMutation, AccountStorageMutation, and EntityStorageMutation. For details, see NerdStorage. NRQL queries: To be able to query your New Relic data via NRQL (New Relic Query Language), we provide a NrqlQuery component. This component can return data in different formats, so that you can use it for charting and not only for querying. Query components All query components accept a function as a children prop where the different statuses can be passed. This callback receives an object with the following properties: loading: Boolean that is set to true when data fetching is happening. Our components use the cache-and-network strategy, meaning that after the data has loaded, subsequent data reloads might be triggered first with stale data, then refreshed when the most recent data has arrived. data: Root property where the data requested is retrieved. The structure matches a root structure based on the NerdGraph schema. This is true even for highly nested data structures, which means you’ll have to traverse down to find the desired data. error: Contains an Error instance when the query fails. Set to undefined when data is loading or the fetch was successful. fetchMore: Callback function that can be called when the query is being loaded in chunks. The function will only be present when it’s feasible to do so, more data is available, and no fetchMore has already been triggered. Data is loaded in batches of 200 by default. Other components provided by the platform (like the Dropdown or the List) are capable of accepting fetchMore, meaning you can combine them easily. Mutation components Mutation components also accept a children as a function, like the query ones. The mutation can be preconfigured at the component level, and a function is passed back that you can use in your component. This is the standard React Apollo approach for performing mutations, but you might find it easier to use our static mutation method added to the component. More on this topic below. Static methods All of the described components also expose a static method so that they can be used imperatively rather than declaratively. All Query components have a static Query method, and all Mutation components have a mutation method. These static methods accept the same props as their query component, but passed as an object. For example: // Declarative way (using components). function renderAccountList() { return (
({data, error}) => { if (error) { return
Failed to retrieve list: {error.message}
; } return data.map((account) => {
{account.name}
}); }}
); } // Imperative way (using promises). async function getAccountList() { let data = {}; try { data = await AccountsQuery.query(); } catch (error) { console.log('Failed to retrieve list: ' + error.message); return; } return data.actor.accounts.map((account) => { return account.name; }); } Copy Similarly, a mutation can happen either way; either declaratively or imperatively. NrqlQuery NrqlQuery deserves additional explanation, because there are multiple formats in which you can return data from it. To provide maximum functionality, all three are exposed through a formatType property. You can find its different values under NrqlQuery.formatType: NERD_GRAPH: Returns the format in which it arrives from NerdGraph. RAW: The format exposed by default in Insights and dashboards when being plotted as JSON. This format is useful if you have a pre-existing script in this format that you're willing to migrate to or incorporate with. CHART: The format used by the charting engine that we also expose. You can find a more detailed explanation of how to manipulate this format in the guide to chart components, and some examples. If you are willing to push data, we currently do not expose NrqlMutation. To do that, see the Event API for how to add custom events.",
"_index": "520d1d5d14cc8a32e600034b",
"_type": "520d1d5d14cc8a32e600034c",
- "_score": 236.27853,
+ "_score": 605.0042,
"_version": null,
"_explanation": null,
"sort": null,
"highlight": {
- "title": "Serve, publish, and deploy your NewRelicOne app",
- "sections": "Serve, publish, and deploy your NewRelicOne app",
- "info": "Start sharing and using the custom NewRelicOne apps you build",
- "body": " to the app Handle duplicate applications Before you begin This guide requires the following: A NewRelicOne app or NerdpackNewRelicOneCLI A Nerdpack manager role for publishing, deploying, and subscribing apps. Serve your app locally You can locally serve the app you create to NewRelicOne to test"
+ "title": "Queryand store data",
+ "sections": "Querycomponents",
+ "info": "Reference guide for SDKquerycomponents using NerdGraph",
+ "tags": "nerdgraph querycomponents",
+ "body": "Query and store data 10 min To help you build a NewRelicOne application, we provide you with the NewRelicOneSDK. Here you can learn how to use the SDKquerycomponents, which allow you to make queries and mutations via NerdGraph, our GraphQL endpoint. Query-related React components can"
},
- "id": "5efa999de7b9d283e67bab8f"
- }
- ],
- "/explore-docs/nr1-cli": [
+ "id": "5efa989e28ccbc2f15307deb"
+ },
{
- "image": "",
- "url": "https://developer.newrelic.com/explore-docs/nr1-nerdpack/",
+ "category_2": "Install plugins",
+ "nodeid": 3276,
"sections": [
- "New Relic One CLI Nerdpack commands",
- "Command details",
- "nr1 nerdpack:clone",
- "Clone an existing Nerdpack",
- "Usage",
- "Options",
- "nr1 nerdpack:serve",
- "Serve your Nerdpack locally",
- "nr1 nerdpack:uuid",
- "Get your Nerdpack's UUID",
- "nr1 nerdpack:publish",
- "Publish your Nerdpack",
- "nr1 nerdpack:deploy",
- "Deploy your Nerdpack to a channel",
- "nr1 nerdpack:undeploy",
- "Undeploy your Nerdpack"
+ "Plugins for New Relic",
+ "Get started",
+ "Install plugins",
+ "Custom dashboards and custom views",
+ "Use a Plugin Central plugin",
+ "View plugin dashboard details",
+ "Delete a plugin",
+ "For more help"
],
- "published_at": "2020-08-28T01:50:39Z",
- "title": "New Relic One CLI Nerdpack commands",
- "updated_at": "2020-08-04T01:44:10Z",
- "type": "developer",
- "external_id": "7c1050a6a8624664b90c15111f7c72e96b2fbe17",
+ "title": "Use a Plugin Central plugin",
+ "category_0": "Plugins",
+ "type": "docs",
+ "category_1": "Plugins for New Relic",
+ "external_id": "87cd571d7a3530a85d10babe6f32ab7ad68ca788",
+ "image": "",
+ "url": "https://docs.newrelic.com/docs/plugins/plugins-new-relic/install-plugins/use-plugin-central-plugin",
+ "published_at": "2020-08-26T21:57:16Z",
+ "updated_at": "2020-08-20T06:46:42Z",
+ "breadcrumb": "Contents / Plugins / Plugins for New Relic / Install plugins",
"document_type": "page",
"popularity": 1,
- "info": "An overview of the CLI commands you can use to set up your New Relic One Nerdpacks.",
- "body": "New Relic One CLI Nerdpack commands To set up your Nerdpacks, use the commands below. You can click any command to see its usage options and additional details about the command. Command Description nr1 nerdpack:clone Clones a Nerdpack from a git repository. nr1 nerdpack:serve Serves your Nerdpack for testing and development purposes. nr1 nerdpack:uuid Shows or regenerates the UUID of a Nerdpack. nr1 nerdpack:publish Publishes your Nerdpack to New Relic. nr1 nerdpack:deploy Deploys a Nerdpack version to a specific channel. nr1 nerdpack:undeploy Undeploys a Nerdpack version from a specific channel. Command details nr1 nerdpack:clone Clone an existing Nerdpack Duplicates an existing Nerdpack onto your local computer. You can clone an open source Nerdpack from our Open Source GitHub repositories. After choosing a git repository, this command performs the following actions so that you can start using the Nerdpack: Clones the repository. Sets the repository as remote upstream. Installs all of its dependencies (using npm). Generates a new UUID using your profile, and commits it. Usage $ nr1 nerdpack:clone OPTION Options -r, --repo=REPO Repository location (either an HTTPS or SSH path). (Required) -p, --path=PATH Determines the directory to clone to (defaults to the repository name). -f, --force Replaces destination folder if it exists. --profile=PROFILE The authentication profile you want to use. --verbose Adds extra information to the output. nr1 nerdpack:serve Serve your Nerdpack locally Launches a server with your Nerdpack locally on the New Relic One platform, where it can be tested live. To learn more about working with apps locally, see our guide on how to serve, publish, and deploy documentation. Usage $ nr1 nerdpack:serve Options --profile=PROFILE The authentication profile you want to use. --verbose Adds extra information to the output. nr1 nerdpack:uuid Get your Nerdpack's UUID Prints the UUID (Universal Unique ID) of your Nerdpack, by default. The UUID determines what data the Nerdpack can access and who can subscribe to the Nerdpack. To deploy a Nerdpack you didn't make, you'll have to assign it a new UUID by using the -g or --generate option. For more details, see our GitHub workshop on GitHub. Usage $ nr1 nerdpack:uuid Options --profile=PROFILE The authentication profile you want to use. -f, --force If present, it will override the existing UUID without asking. -g, --generate Generates a new UUID if not available. --verbose Adds extra information to the output. nr1 nerdpack:publish Publish your Nerdpack Publishes your Nerdpack to New Relic. Please note: If no additional parameters are passed in, this command will automatically deploy the Nerdpack onto the DEV channel. If you want to specify your own list of deploy channels, add the --channel option. For example, $ nr1 nerdpack:publish --channel BETA --channel STABLE. If you want to disable this behavior, add -D or --skip-deploy to the command. Then, you can use nr1 nerdpack:deploy to perform a deploy manually. For more on publishing and deploying, see Deploy to New Relic One. Usage $ nr1 nerdpack:publish Options -B, --skip-build Skips the previous build process. -D, --skip-deploy Skips the following deploy process. -c, --channel=DEV/BETA/STABLE Specifies the channel to deploys to. [default: STABLE] -f, --force Forces the publish, overriding any existing version in the registry. --dry-run Undergoes publishing process without actually publishing anything. --extra-metadata-path=extra-metadata-path Specifies a json file .path with extra metadata. [default: extra-metadata.json] --prerelease=STRING The value you enter will be appended to the current version of generated files. --profile=PROFILE The authentication profile you want to use. --verbose Adds extra information to the output. nr1 nerdpack:deploy Deploy your Nerdpack to a channel Deploys a Nerdpack version to a specific channel (DEV, BETA, or STABLE). A channel can only have one Nerdpack version deployed to it at one time. If a channel has an existing Nerdpack associated with it, deploying a new Nerdpack version to that channel will undeploy the previous one. For more on publishing and deploying, see Deploy to New Relic One. Usage $ nr1 nerdpack:deploy OPTION Options -c, --channel=DEV/BETA/STABLE Specifies the channel to deploy to. (required) -i, --nerdpack-id=NERDPACK_ID Specifies the Nerdpack to deploy. By default, the command will use the one in package.json. --from-version=VERSION Specifies which version to deploy. By default, the command will use the one in package.json. --profile=PROFILE The authentication profile you want to use. --verbose Adds extra information to the output. nr1 nerdpack:undeploy Undeploy your Nerdpack Undeploys a Nerdpack version from a specific channel (for example, DEV, BETA, or STABLE). Usage $ nr1 nerdpack:undeploy OPTION Options -c, --channel=DEV/BETA/STABLE Specifies the channel to undeploy from. (required) -i, --nerdpack-id=NERDPACK_ID Specifies the Nerdpack to deploy. By default, the command will use the one in package.json. --profile=PROFILE The authentication profile you want to use. --verbose Adds extra information to the output.",
+ "info": "How to navigate the user interface for plugins you install from Plugin Central in New Relic One.",
+ "body": "For an even better experience than plugins, go to: newrelic.com/integrations: Integrate the on-host and cloud systems you already use with New Relic, so you can filter and analyze data, create dashboards, and set alerts within a single platform. developer.newrelic.com: Use developer tools to collect data from any source, automate workflows, build apps, and use our APIs. Each plugin in Plugin Central includes procedures for how to install, use, troubleshoot, and uninstall it. After you install a plugin, it starts to receive data, usually within five minutes. The plugin automatically appears with a short name and icon on your Plugins menu in New Relic One. You do not need to select it from Plugin Central. Plugins in Plugin Central are not supported with accounts that host data in the EU region data center. View plugin dashboard details The amount and types of information on the plugin's summary page and dashboards depend on the specific plugin. For example, a plugin may have one or more components (instances) and one or more dashboards. To view summary and dashboard details about the plugin: Go to one.newrelic.com > More > Plugins, and select your plugin. From the plugin's summary page, review the list of components or instances, summary metrics, and list of Recent Events. To view dashboard details about any component or instance, select its name. Plugin summary Depending on the plugin, the summary includes: One or more components or instances (what the plugin agent is monitoring, typically a host/port pair) Zero to five summary metrics for the past three minutes (values such as average, total, minimum, maximum, standard deviation, rate, or count) with optional alerts Recent events list, including deployments, notifications, and alerts Other information about alert violations, events, and activity If your plugin has 100 or more components or instances, you can search for a specific component instance. Here is a summary of additional standard features. If you want to... Do this... View version information for a component's or instance's agent Mouse over the component's name. Change the sort order On the title row of the plugin's summary page, select the up or down arrow for a component (instance) or a summary metric's label. Show or hide items on the events and activity list Select an event icon, or select All. View details about an event On the events and activity list, select the link. View page details for a component or instance Select the name or a summary metric for the component (instance). Plugin dashboards Depending on the plugin, it may have one or more dashboards, and each dashboard may present data as a chart or a table. You can use any of New Relic's standard dashboard features to drill down into detailed information. The customized dashboards that show plugin data are part of the plugin. Users cannot add or remove these dashboards. This must be done by the author or publisher as part of a plugin update. Plugin alerts If the plugin publisher set Critical (red) or Caution (yellow) alert conditions for your plugin's components or instances, you can view details direct in the user interface. For example, you can: Select and view alert details. Change the existing thresholds. Set your alert notification options; for example, to receive email notifications for Critical events. Delete a plugin Each plugin in Plugin Central includes procedures for how to uninstall it. When you select the plugin's Download or Continue button, the plugin should include a README file or refer to other documentation resources. Remove plugin components (instances) At a minimum, your plugin must stop reporting data before you start uninstalling it. Make sure the health status for your plugin's components (instances) are gray. Depending on the plugin, there may be other dependencies before disabling or uninstalling it. For example, plugins from SaaS providers may have different requirements. Be sure to review the instructions that the plugin's publisher provides. Then, to remove individual components from your plugin, click the settings settings icon for each component (instance). Delete the plugin After you remove each component (instance) for the plugin, the plugin icon will automatically disappear from your Plugins menu in the New Relic UI. You do not need to do anything else to delete the plugin. If you are the plugin's publisher and need to delete the plugin from Plugin Central, go to support.newrelic.com. For more help If you need more help, check out these support and learning resources: Review the documentation provided by the plugin publisher, or contact the publisher's support resources (identified in the plugin's Get support link). Browse the Explorers Hub to get help from the community and join in discussions. Find answers on our sites and learn how to use our support portal. Run New Relic Diagnostics, our troubleshooting tool for Linux, Windows, and macOS. Review New Relic's data security and licenses documentation.",
"_index": "520d1d5d14cc8a32e600034b",
"_type": "520d1d5d14cc8a32e600034c",
- "_score": 124.959015,
+ "_score": 602.76025,
"_version": null,
"_explanation": null,
"sort": null,
"highlight": {
- "title": "NewRelicOne CLI Nerdpackcommands",
- "sections": "NewRelicOne CLI Nerdpackcommands",
- "info": "An overview of the CLI commands you can use to set up your NewRelicOneNerdpacks.",
- "body": "NewRelicOne CLI Nerdpackcommands To set up your Nerdpacks, use the commands below. You can click any command to see its usage options and additional details about the command. Command Description nr1 nerdpack:clone Clones a Nerdpack from a git repository. nr1 nerdpack:serve Serves your Nerdpack"
+ "sections": "Plugins for NewRelic",
+ "info": "How to navigate the user interface for plugins you install from Plugin Central in NewRelicOne.",
+ "category_1": "Plugins for NewRelic",
+ "body": "For an even better experience than plugins, go to: newrelic.com/integrations: Integrate the on-host and cloud systems you already use with NewRelic, so you can filter and analyze data, create dashboards, and set alerts within a single platform. developer.newrelic.com: Use developer tools",
+ "breadcrumb": "Contents / Plugins / Plugins for NewRelic / Install plugins"
},
- "id": "5f28bd6a64441f9817b11a38"
- },
+ "id": "5f2ef9b3196a67c2a0fbd721"
+ }
+ ],
+ "/automate-workflows/automated-tagging": [
{
+ "image": "",
+ "url": "https://developer.newrelic.com/automate-workflows/",
"sections": [
- "Intro to NerdStorage",
- "Use NerdStorage in your apps",
- "Data model",
- "Limits",
- "Data access",
- "Permissions for working with NerdStorage"
+ "Automate workflows",
+ "Guides to automate workflows",
+ "Quickly tag resources",
+ "Set up New Relic using Helm chats",
+ "Automatically tag a simple \"Hello World\" Demo across the entire stack",
+ "Automate common tasks",
+ "Set up New Relic using the Kubernetes operator",
+ "Set up New Relic using Terraform"
],
- "title": "Intro to NerdStorage",
+ "published_at": "2020-08-29T01:50:40Z",
+ "title": "Automate workflows",
+ "updated_at": "2020-08-29T01:50:40Z",
"type": "developer",
- "tags": [
- "nerdstorage",
- "nerdstorage components",
- "new relic one apps",
- "data access"
- ],
- "external_id": "709e06c25376d98b2191ca369b4d139e5084bd62",
- "image": "",
- "url": "https://developer.newrelic.com/explore-docs/nerdstorage/",
- "published_at": "2020-08-28T01:50:39Z",
- "updated_at": "2020-08-14T01:50:34Z",
+ "external_id": "d4f408f077ed950dc359ad44829e9cfbd2ca4871",
"document_type": "page",
"popularity": 1,
- "info": "Intro to NerdStorage on New Relic One",
- "body": "Intro to NerdStorage 30 min To help you build a New Relic One application, we provide you with the New Relic One SDK. On this page, you’ll learn how to use NerdStorage SDK components. Use NerdStorage in your apps NerdStorage is used to store and retrieve simple sets of data, including users's configuration settings and preferences (like favorites), or any other small data sets. This storage is unique per Nerdpack, and can't be shared with any other Nerdpack. NerdStorage can be classified into three categories: User storage: Data that is attached to a particular user. If you’re authenticated as the user the data is attached to, you can read it and write it. Account storage: Data that is attached to a particular account. If you’re authenticated and can access the account, you can read and write to account scoped NerdStorage. Visibility of account data is also determined by master/subaccount rules: If a user has access to the master account, then they also have access to data in all subaccounts. Entity storage: Data that is attached to a particular entity. If you can see the corresponding entity, you can read and write data on that entity. Data model You can imagine NerdStorage as a nested key-value map. Data is inside documents, which are nested inside collections: { 'YourNerdpackUuid': { 'collection-1': { 'document-1-of-collection-1': '{\"lastNumber\": 42, \"another\": [1]}', 'document-2-of-collection-1': '\"userToken\"', // ... }, 'another-collection': { 'fruits': '[\"pear\", \"apple\"]', // ... }, // ... }, } Copy Each NerdStorage level has different properties and purpose: Collections: From a Nerdpack, you can create multiple collections by naming each of them. Inside a collection you can put one or more documents. Think of a collection as key-value storage, where each document is a key-value pair. Documents: A document is formed by an identifier (documentId) and a set of data associated with it. Data associated with a document: NerdStorage accepts any sort of data associated to a documentId. Query and mutation components that are provided work by serializing and deserializing JSON. Limits A Nerdpack can hold up to 1,000 collections and 10,000 documents, plus storage type. A collection can hold up to 1,000 documents, plus storage type. Each document can have a maximum length of 64 KiB when serialized. Data access To access NerdStorage, you can run NerdGraph queries, or use the provided storage queries. Depending on which storage you want to access, you can use a different set of SDK components: User access: UserStorageQuery and UserStorageMutation Account access: AccountStorageQuery and AccountStorageMutation Entity access: EntityStorageQuery and EntityStorageMutation Each of these components can operate declaratively (for example, as part of your React rendering methods) or imperatively (by using the static methods for query and mutation). For more information on this, see Data querying and mutations. Permissions for working with NerdStorage In order to persist changes on NerdStorage, such as creating, updating, and deleting account and entity storage, you must have a user role with permission to persist changes.",
+ "body": "Automate workflows When building today's complex systems, you want an easy, predictable way to verify that your configuration is defined as expected. This concept, Observability as Code, is brought to life through a collection of New Relic-supported orchestration tools, including Terraform, AWS CloudFormation, and a command-line interface. These tools enable you to integrate New Relic into your existing workflows, easing adoption, accelerating deployment, and returning focus to your main job — getting stuff done. In addition to our Terraform and CLI guides below, find more automation solutions in our Developer Toolkit. Guides to automate workflows 5 min Quickly tag resources Add tags to apps for easy filtering 20 min Set up New Relic using Helm chats Learn how to set up New Relic using Helm charts 30 min Automatically tag a simple \"Hello World\" Demo across the entire stack See how easy it is to leverage automation in your DevOps environment! 20 min Automate common tasks Use the New Relic CLI to tag apps and create deployment markers 20 min Set up New Relic using the Kubernetes operator Learn how to provision New Relic resources using the Kubernetes operator 20 min Set up New Relic using Terraform Learn how to provision New Relic resources using Terraform",
+ "info": "",
"_index": "520d1d5d14cc8a32e600034b",
"_type": "520d1d5d14cc8a32e600034c",
- "_score": 119.28394,
+ "_score": 208.41797,
"_version": null,
"_explanation": null,
"sort": null,
"highlight": {
- "sections": "Use NerdStorage in your apps",
- "info": "Intro to NerdStorage on NewRelicOne",
- "tags": "newreliconeapps",
- "body": "Intro to NerdStorage 30 min To help you build a NewRelicOne application, we provide you with the NewRelicOne SDK. On this page, you’ll learn how to use NerdStorage SDK components. Use NerdStorage in your apps NerdStorage is used to store and retrieve simple sets of data, including users"
+ "title": "Automate workflows",
+ "sections": "Automaticallytag a simple "Hello World" Demo across the entirestack",
+ "body": " solutions in our Developer Toolkit. Guides to automate workflows 5 min Quickly tag resources Add tags to apps for easy filtering 20 min Set up New Relic using Helm chats Learn how to set up New Relic using Helm charts 30 min Automatically tag a simple "Hello World" Demo across the entirestack See how easy"
},
- "id": "5efa989ee7b9d2048e7bab92"
+ "id": "5efa999c196a67dfb4766445"
},
{
+ "category_2": "Examples",
+ "nodeid": 34236,
"sections": [
- "Set up your development environment",
- "Before you begin",
- "A note on support",
- "Tip",
- "Prepare to build or modify apps",
- "Start building",
- "Contribute to developer.newrelic.com"
- ],
- "title": "Set up your development environment",
- "type": "developer",
- "tags": [
- "developer account",
- "API key",
- "New Relic One CLI"
+ "NerdGraph",
+ "Get started",
+ "Examples",
+ "NerdGraph tagging API tutorial",
+ "Read tags for an entity",
+ "Add tags for an entity",
+ "Remove a tag from an entity",
+ "Delete specific tag values for an entity",
+ "Replace all tag values for an entity",
+ "For more help"
],
- "external_id": "c45638a9cd548d1ffffc9f1c7708f115a92ae04a",
+ "title": "NerdGraph tagging API tutorial",
+ "category_0": "APIs",
+ "type": "docs",
+ "category_1": "NerdGraph",
+ "external_id": "c4b8fbf4f75b862f2b6e3caad723935febb89815",
"image": "",
- "url": "https://developer.newrelic.com/build-apps/set-up-dev-env/",
- "published_at": "2020-08-28T01:45:16Z",
- "updated_at": "2020-08-26T01:47:20Z",
+ "url": "https://docs.newrelic.com/docs/apis/nerdgraph/examples/nerdgraph-tagging-api-tutorial",
+ "published_at": "2020-08-26T00:31:30Z",
+ "updated_at": "2020-07-26T05:41:24Z",
+ "breadcrumb": "Contents / APIs / NerdGraph / Examples",
"document_type": "page",
"popularity": 1,
- "info": "Prepare to build apps and contribute to this site",
- "body": "Set up your development environment 20 min If you've decided to build a custom app or modify one of our open source apps, you need a few essential tools: The New Relic One command line interface (CLI) An API key, which you get when you download the CLI Depending on what you want to do with your app, you might have some additional setup and configuration. This guide covers: Downloading the New Relic One CLI to build or modify apps Contribute content to this website Before you begin You must have: A github account account - While not strictly necessary for building apps, a GitHub account enables you to download and customize our open source apps, and contribute an open source project. A New Relic developer account - if you don't already have one, you can get a free trial account for developing New Relic applications. npm - If you've installed Node.js, then you already have npm, which is used to share, reuse, and update JavaScript code, and is necessary for working with React components that are the framework for New Relic apps and this website. A note on support Building a New Relic One application is the same as building any JavaScript/React application. We offer support to help with our building tools (our CLI and SDK library). However, we don't offer support for basic JavaScript or React coding questions or issues. For common questions and answers about building, see the Explorers Hub page on building on New Relic One. Tip Use the New Relic One VSCode extension to build your apps. Prepare to build or modify apps Step 1 of 1 Download the CLI and API key. On the Build New Relic One applications page, complete the Quick start steps. These six Quick start steps get you an API key for use with developing apps, and the New Relic One CLI, for building and deploying apps. At the end of the Quick start, you have a project consisting of the following: A Nerdpack - The package containing all the files required by your application. It contains two types of files that you customize to build your app: Nerdlets, and the launcher. One or more Nerdlet files - A specific UI view or window. A Nerdlet is a React JavaScript package that includes an index.js file, a stylesheet, and a JSON-format config file. It can contain any JS functionality (charts, interactive fields, tooltips, etc.). A launcher file: This is the basis for the launcher, which is used to open your application from New Relic One after you publish your app. Start building Step 1 of 1 If you're ready to code, cd to your Nerdpack and get started. If you want to learn more about building applications, try these step-by-step guides: Build a \"Hello, World!\" application shows how to create a little application, publish it to New Relic One, and share it with others by subscribing accounts to it. Map pageviews by region takes you through the steps to create one of our popular open source apps. You learn to add a custom query to an app and view it in a table, then add that data to a map. Contribute to developer.newrelic.com This site is open source, and we want your input. Create a pull request if you see a mistake you know how to fix. Drop us a GitHub issue if you see some content gaps you want us to work on. Or write up a whole new guide if you have one you'd like to share. Read on to learn how. Step 1 of 3 Fork the developer-website GithHub repo. Forking the repo enables you to work on your own copy of the developer.newrelic.com files, and build the site locally. It also enables us to more easily manage incomimg pull requests. On the developer-website page in GitHub, select the Fork button on the top right of the page, choose the account you want to fork to, and wait a few seconds while the fork is created. Sync regularly to keep your fork up to date with changes and additions to the main branch upstream. Step 2 of 3 Make a feature or documentation request. On any page, select the GitHub button at the top of the page, and then select the kind of change you want, and fill out the GitHub form. Step 3 of 3 Contribute a new guide. Check out our contributors guidelines, which will walk you through the process.",
+ "info": "Use New Relic's NerdGraph (our GraphQL API) to manage tags attached to your entities. ",
+ "body": "New Relic One provides unified access to all the entities you monitor with New Relic. Tags are used to organize and group all your entities in a way that's useful for troubleshooting and understanding your environment. To add, delete, or modify your tags, use the NerdGraph GraphiQL explorer. NerdGraph allows you to tag your entities with a key and an associated list of values. You can also use NerdGraph to query entities. Read tags for an entity To construct these queries and see responses: Go to the NerdGraph GraphiQL explorer at https://api.newrelic.com/graphiql. Use entitySearch() to find the entity and then fetch its tags. Use NerdGraph's tag API to read the existing tags and their values. In this example, our entity is a browser app called Cookie Checkout: { actor { entitySearch (query: \"name like 'Cookie Checkout'\") { results { entities { tags { key values } } } } } } The actual values vary depending on your data. Use the New Relic GraphiQL explorer to experiment with queries. Add tags for an entity To add new tags for an entity: Go to the NerdGraph GraphiQL explorer at https://api.newrelic.com/graphiql. Use entitySearch() to locate the GUID for the entity you want to tag. Use the taggingAddTagsToEntity mutation to add a tag with a value to the entity. In this example, we have a browser application called Cookie Checkout owned by a UI team. We want to add a team tag with a ui value to this instance. Once the tag is added, we can filter by the tag team:ui and find the Cookie Checkout app in the New Relic One UI. mutation { taggingAddTagsToEntity ( guid: \"ENTITY_GUID\", tags: { key: \"team\", values: [\"ui\"]}) { errors { message } } } Remove a tag from an entity To delete a tag and all of its associated values from an entity: Go to the NerdGraph GraphiQL explorer at https://api.newrelic.com/graphiql. Use entitySearch() to locate the GUID for the entity with the tag you want to remove. Use the taggingDeleteTagFromEntity mutation. The following example mutation removes the team tag from an entity: mutation { taggingDeleteTagFromEntity ( guid: \"ENTITY_GUID\", tagKeys: [\"team\"]) { errors { message } } } Delete specific tag values for an entity Instead of deleting an entire tag and all of its values, you can delete a single tag value. Go to the NerdGraph GraphiQL explorer at https://api.newrelic.com/graphiql. Use entitySearch() to locate the GUID for the entity with the tag you want to remove. Use the taggingDeleteTagValuesFromEntity mutation. The following example mutation deletes the ui value from the tag key: mutation { taggingDeleteTagValuesFromEntity ( guid: \"ENTITY_GUID\", tagValues : [{key: \"team\" value: \"ui\"}]) { errors { message } } } Because tagValues is an array, you can delete multiple specific values from a single entity in one mutation. Replace all tag values for an entity To replace all the existing values for a tag with new ones: Go to the NerdGraph GraphiQL explorer at https://api.newrelic.com/graphiql. Use entitySearch() to locate the GUID for the entity with the tag you want to remove. Use the taggingReplaceTagsOnEntity mutation. In this example, the Cookie Checkout browser application was transferred from the ui team to the cookie-dev team. You can replace the tag values for team with the following mutation: mutation { taggingReplaceTagsOnEntity ( guid: \"ENTITY_GUID\", tags: {key: \"team\" values: [\"cookie-dev\"]}) { errors { message } } } For more help If you need more help, check out these support and learning resources: Browse the Explorers Hub to get help from the community and join in discussions. Find answers on our sites and learn how to use our support portal. Run New Relic Diagnostics, our troubleshooting tool for Linux, Windows, and macOS. Review New Relic's data security and licenses documentation.",
"_index": "520d1d5d14cc8a32e600034b",
"_type": "520d1d5d14cc8a32e600034c",
- "_score": 100.56512,
+ "_score": 99.78872,
"_version": null,
"_explanation": null,
"sort": null,
"highlight": {
- "sections": "Prepare to build or modify apps",
- "info": "Prepare to build apps and contribute to this site",
- "tags": "NewRelicOne CLI",
- "body": "Set up your development environment 20 min If you've decided to build a custom app or modify one of our open source apps, you need a few essential tools: The NewRelicOnecommand line interface (CLI) An API key, which you get when you download the CLI Depending on what you want to do with your app"
+ "title": "NerdGraph tagging API tutorial",
+ "sections": "NerdGraph tagging API tutorial",
+ "info": "Use New Relic's NerdGraph (our GraphQL API) to manage tags attached to your entities. ",
+ "body": ". NerdGraph allows you to tagyour entities with a key and an associated list of values. You can also use NerdGraph to query entities. Read tags for an entity To construct these queries and see responses: Go to the NerdGraph GraphiQL explorer at https://api.newrelic.com/graphiql. Use entitySearch() to find"
},
- "id": "5efa9973e7b9d242237bab39"
+ "id": "5d8024fc28ccbcc5e9499cf1"
},
{
+ "category_2": "Guides",
+ "nodeid": 14056,
"sections": [
- "Intro to New Relic One API components",
- "Components of the SDK",
- "UI components",
- "Chart components",
- "Query and storage components",
- "Platform APIs"
- ],
- "title": "Intro to New Relic One API components",
- "type": "developer",
- "tags": [
- "SDK components",
- "New Relic One apps",
- "UI components",
- "chart components",
- "query and storage components",
- "Platform APIs"
+ "New Relic APM",
+ "Getting started",
+ "Guides",
+ "Apdex",
+ "Maintenance",
+ "Troubleshooting",
+ "APM best practices guide",
+ "1. Standardize application names",
+ "How to do it",
+ "2. Add tags to your applications",
+ "3. Create and evaluate alert policies",
+ "4. Identify and set up key transactions",
+ "5. Track deployment history",
+ "6. Review APM reports",
+ "7. Review your environment with service maps",
+ "8. Keep current",
+ "9. Manage user access",
+ "For more help"
],
- "external_id": "3620920c26bcd66c59c810dccb1200931b23b8c2",
+ "title": "APM best practices guide",
+ "category_0": "APM",
+ "type": "docs",
+ "category_1": "New Relic APM",
+ "translation_ja_url": "https://docs.newrelic.co.jp/docs/apm/new-relic-apm/guides/new-relic-apm-best-practices-guide",
+ "external_id": "1c94d35b6f8837275133b20124d2c871f25e99f7",
"image": "",
- "url": "https://developer.newrelic.com/explore-docs/intro-to-sdk/",
- "published_at": "2020-08-28T01:49:25Z",
- "updated_at": "2020-08-14T01:47:12Z",
+ "url": "https://docs.newrelic.com/docs/apm/new-relic-apm/guides/new-relic-apm-best-practices-guide",
+ "published_at": "2020-08-26T06:36:56Z",
+ "updated_at": "2020-08-18T16:26:59Z",
+ "breadcrumb": "Contents / APM / New Relic APM / Guides",
"document_type": "page",
"popularity": 1,
- "info": "Intro to New Relic One API components",
- "body": "Intro to New Relic One API components To help you build New Relic One applications, we provide you with the New Relic One SDK. Here we give you an introduction to the types of API calls and components in the SDK. The SDK provides everything you need to build your Nerdlets, create visualizations, and fetch New Relic or third-party data. Components of the SDK SDK components are located in the Node module package named nr1, which you get when you install the NR1 CLI. The nr1 components can be divided into several categories: UI components Chart components Query and storage components Platform APIs UI components The UI components category of the SDK contains React UI components, including: Text components: These components provide basic font and heading elements. These include HeadingText and BlockText. Layout components: These components give you control over the layout, and help you build complex layout designs without having to deal with the CSS. Layout components include: Grid and GridItem: for organizing more complex, larger scale page content in rows and columns Stack and StackItem: for organizing simpler, smaller scale page content (in column or row) Tabs and TabsItem: group various related pieces of content into separate hideable sections List and ListItem: for providing a basic skeleton of virtualized lists Card, CardHeader and CardBody : used to group similar concepts and tasks together Form components: These components provide the basic building blocks to interact with the UI. These include Button, TextField, Dropdown and DropdownItem, Checkbox, RadioGroup, Radio, and Checkbox. Feedback components: These components are used to provide feedback to users about actions they have taken. These include: Spinnerand Toast. Overlaid components: These components are used to display contextual information and options in the form of an additional child view that appears above other content on screen when an action or event is triggered. They can either require user interaction (like modals), or be augmenting (like a tooltip). These include: Modal and Tooltip. Components suffixed with Item can only operate as direct children of that name without the suffix. For example: GridItem should only be found as a child of Grid. Chart components The Charts category of the SDK contains components representing different types of charts. The ChartGroup component helps a group of related charts share data and be aligned. Some chart components can perform NRQL queries on their own; some accept a customized set of data. Query and storage components The Query components category contains components for fetching and storing New Relic data. The main way to fetch data is with NerdGraph, our GraphQL endpoint. This can be queried using NerdGraphQuery. To simplify use of NerdGraph queries, we provide some components with pre-defined queries. For more on using NerdGraph, see Queries and mutations. We also provide storage for storing small data sets, such as configuration settings data, or user-specific data. For more on this, see NerdStorage. Platform APIs The Platform API components of the SDK enable your application to interact with different parts of the New Relic One platform, by reading and writing state from and to the URL, setting the configuration, etc. They can be divided into these categories: PlatformStateContext: provides read access to the platform URL state variables. Example: timeRange in the time picker. navigation: an object that allows programmatic manipulation of the navigation in New Relic One. Example: opening a new Nerdlet. NerdletStateContext: provides read access to the Nerdlet URL state variables. Example: an entityGuid in the entity explorer. nerdlet: an object that provides write access to the Nerdlet URL state.",
+ "info": "Here are some best practices designed to help you become a New Relic APM master and a key asset to your team.",
+ "body": "Application Monitoring Tips You Need To Know It's one thing to know how to use APM, but it's another thing to know how to use New Relic's application performance monitoring software well. Here are some best practices designed to help you become an APM master—and a key asset to your team! To get a high-level overview of all your applications and services, use the entity explorer in New Relic One. 1. Standardize application names Most New Relic agents provide a default application name, such as \"My Application\" or \"PHP Application,\" if you don't specify one in your New Relic configuration file. You don't want to end up with 20 identically named applications, be sure to select a descriptive identifier for your apps as soon you deploy them. To keep things consistent and easy to navigate, New Relic recommends standardizing your application naming (for example, all apps in Staging append [Staging] or the like at the end of their names). Ideally, you want your new Java applications to be named automatically to reduce the chances of typographical errors and misnaming. How to do it For Java applications, automatic application naming can come from the following sources: Request attribute Servlet init parameter Filter init parameter Web app context parameter Web app context name (display name) Web app context path Choose the method that fits best your needs and follow these steps. For non-Java applications, there are no automatic naming methods, so refer to the documentation for your APM agent. 2. Add tags to your applications When several different applications use the same account, and each application spans multiple environments (for example, development, test, pre-production, production), it can be hard to find a specific application in your overview dashboard. That's why we recommend adding tags to your apps so that you can segment them into logical groups. The two most common tags that mature APM customers use are application name and environment. So, for example, if you wanted to view the billing application in Test, you could simply filter by \"billing app\" (name label) and \"test\" (environment label). APM is designed so that apps can roll up into an unlimited number of meaningful categories. How to do it Read the overview: Use tags to organize and group what you monitor. Follow these instructions for creating tags: NerdGraph tagging API tutorial. 3. Create and evaluate alert policies When key performance indicators spike or drop, individuals and teams in your organization need to be notified. Alerting in New Relic provides a set of tools including dynamic baselines that allow you to detect problems before they impact your end users. Alert policies can be set up in two primary ways: Static threshold alerts are great when you already know the nature of an application and its normal behaviors aren't likely to change anytime soon. Apdex score, response time, error rate, throughput are some of the static thresholds you can create alert policies on. Dynamic baseline alerts make it easy to determine and set dynamic alert thresholds for applications with varying seasonal patterns and growth trends (which make it difficult to set thresholds that define normal behavior). These alerts use baselines modeled from your application’s historical metric data. Each alert policy can contain as many conditions as you need, and each alert condition includes three components: Type of condition (metric, external service, and so on) Entities that the policy targets (for example, apps monitored by New Relic APM or New Relic Browser, hosts monitored by New Relic Infrastructure, and so on) Thresholds that escalate into alerting situations with increasing severity Once you have your alerting set up, you then want to make sure you're taking advantage of all viable notification channels. After all, what good are alerts if no one knows about them? You can manage alerts by creating specific user groups and by leveraging New Relic's integrated alert channels, including Slack, PagerDuty, webhooks, and email. Be sure to evaluate alert policies on a regular basis to ensure that they are always valid. How to do it See the detailed documentation: To set up dynamic baseline alerts and choose an application, follow standard procedures. You will see a preview of the metric with the predicted baseline You can select a metric for that application and see the corresponding baseline. Then, using the threshold sliders, you can set how closely you want your threshold to follow the baseline prediction. To set up static threshold alerts for your Apdex settings, follow standard procedures. To set up your alert notification channels, follow standard procedures. 4. Identify and set up key transactions Depending on the nature of your application, some transactions may be more important to you than others. New Relic's key transactions feature is designed to help you closely monitor what you consider to be your app's most business-critical transactions, whether that's end-user or app response time, call counts, error rates, or something else. You can also set alert threshold levels for notifications when your key transactions are performing poorly. How to do it In the menu bar, select More > Key transactions, and then select Add more. Then select the app and web transaction or, from the selected transaction, select Track as key transaction. Type a name for the key transaction, and select Track key transaction. Optional: If the agent for the selected app supports custom alerting, use the default values that New Relic automatically fills, or select Edit key alert transaction policy to set the Apdex and alert threshold values. To view the key transactions dashboard details, select View new key transaction. 5. Track deployment history When development teams are pushing new code out as frequently as possible, it can be hard to measure the impact that each deployment is having on performance. One way to stay in tune with how these changes are affecting your application is with deployment reports. These reports list recent deployments and their impact on end-users and app servers' Apdex scores, along with response times, throughput, and errors. You can also view and drill down into the details to catch errors related to recent deployments, or file a ticket and share details with your team. How to do it From the New Relic menu bar, select APM > (selected app) > Events > Deployments. To view performance after a deployment, go to the selected app's Overview dashboard in the Recent events section. A blue vertical bar on a chart indicates a deployment. To view summary information about the deployment, point to the blue bar. 6. Review APM reports From SLA, deployment, and capacity to scalability, host usage reports, and more, New Relic APM offers a variety of downloadable reporting tools surfacing historical trends—all great ways to report to senior executive teams or customers. Take a look at the full list of reports and use them to your advantage. How to do it From the New Relic APM menu bar, select Applications > (selected app) > Reports. Select the report you'd like to see. If you want to save or export a report to share, select Download this report as .csv, which will create a report with comma-separated values. 7. Review your environment with service maps Use New Relic service maps, a feature included in APM, to understand how apps and services in your architecture connect and talk to each other. Service maps are visual, customizable representations of your application architecture. Maps automatically show you your app's connections and dependencies, including databases and external services. Health indicators and performance metrics show you the current operational status for every part of your architecture. How to do it Go to one.newrelic.com > More > service maps. To get started, read the instructions in Introduction to service maps. 8. Keep current With New Relic’s SaaS platform, getting new features is as easy as updating your agent. Most likely your organization already has a set of scripts for deploying application upgrades into your environment. In a similar fashion, you can also automate your New Relic agent deployment to ensure that your systems are up to date. Both Puppet and Chef scripts are great examples of deployment frameworks that make life easier by allowing you to automate your entire deployment and management process. How to do it Regularly review which version of the agent you're using so that you know when an update is needed. If the latest agent release contains a needed fix or added functionality, download it. To deploy the agent automatically (preferred as a method to avoid errors): Use existing deployment scripts, provided they can be adapted to handle the deployment. OR Create and maintain a script that specifically deploys and configures the New Relic agent. Ideally, the script would pull the agent files from a repository where the files are versioned (for rollback purposes). Once the script has been created, shut down the application (unless script handles this). Run the deployment script. Start the application (unless script handles this). If problems arise, run the script to roll back to the previous version. To deploy the agent manually: Back up the current agent directory. Deploy the updated agent into the existing agent directory. Modify configuration files by comparing new files with existing files. In particular, make sure things like license key and custom extensions are copied over to the new configuration. Restart the application. If problems arise, restore the old agent using the backup and restart. 9. Manage user access This is available only for accounts on our original product-based pricing plan. Enable role-based access control (RBAC) and single sign-on (SSO) New Relic allows authorized individuals to access the broadest possible amount of data, regardless of their assigned role. As an Owner or Administrator of your New Relic account, you can control the permissions of individual users or entire roles with RBAC. To find out what is possible and how to make changes, see Users and roles. Security is no doubt of utmost concern to your organization. To simplify password management for your employees and strengthen security, you may already be using SSO with your other systems. You should do the same with New Relic. Using New Relic's SSO integration feature, account administrators will be able to enforce strong passwords and restrict login via a corporate authentication mechanism. This way, New Relic users who have already authenticated using a corporate SSO system will be able to bypass the New Relic login prompt. How to do it Log in to New Relic as an admin and go to the SSO configuration page. From the New Relic title bar, select (your account name) > Account Settings > Integrations > Single Sign On. From the SAML Single Sign On page, review your New Relic SAML Service Provider details. To upload your SAML Identity Provider certificate, select Choose File, and then follow standard procedures to select and save the file. Copy and paste in (or type) the Remove login URL that your users will use for Single Sign-On. If your organization’s SAML integration provides a redirect URL for logout, copy and paste in (or type) the Logout landing URL; otherwise leave blank. Save, test, and enable. For more help If you need more help, check out these support and learning resources: Browse the Explorers Hub to get help from the community and join in discussions. Find answers on our sites and learn how to use our support portal. Run New Relic Diagnostics, our troubleshooting tool for Linux, Windows, and macOS. Review New Relic's data security and licenses documentation.",
"_index": "520d1d5d14cc8a32e600034b",
"_type": "520d1d5d14cc8a32e600034c",
- "_score": 93.55908,
+ "_score": 98.148315,
"_version": null,
"_explanation": null,
"sort": null,
"highlight": {
- "title": "Intro to NewRelicOne API components",
- "sections": "Intro to NewRelicOne API components",
- "info": "Intro to NewRelicOne API components",
- "tags": "NewRelicOneapps",
- "body": "Intro to NewRelicOne API components To help you build NewRelicOne applications, we provide you with the NewRelicOne SDK. Here we give you an introduction to the types of API calls and components in the SDK. The SDK provides everything you need to build your Nerdlets, create visualizations"
+ "sections": "2. Add tags to your applications",
+ "info": "Here are some best practices designed to help you become a New Relic APM master and a key asset to your team.",
+ "body": " application upgrades into your environment. In a similar fashion, you can also automateyour New Relic agent deployment to ensure that your systems are up to date. Both Puppet and Chef scripts are great examples of deployment frameworks that make life easier by allowing you to automateyourentire"
},
- "id": "5efa989e28ccbc4071307de5"
+ "id": "59a65bee4bb81c3f8a1bd770"
},
{
+ "image": "https://developer.newrelic.com/static/nerd-days-cd32e6ce7bce9feb13142801151df03c.png",
+ "url": "https://developer.newrelic.com/",
"sections": [
- "Nerdpack file structure",
- "Generate Nerdpack components",
- "Nerdlet file structure",
- "index.js",
- "nr1.json",
- "styles.scss",
- "icon.png",
- "Launcher file structure"
+ "Mark your calendar for Nerd Days 1.0",
+ "Get coding",
+ "Create custom events",
+ "Add tags to apps",
+ "Build a Hello, World! app",
+ "Get inspired",
+ "Add a table to your app",
+ "Collect data - any source",
+ "Automate common tasks",
+ "Create a custom map view",
+ "Add a time picker to your app",
+ "Add custom attributes",
+ "New Relic developer champions",
+ "New Relic Podcasts"
],
- "title": "Nerdpack file structure",
+ "published_at": "2020-08-29T01:49:31Z",
+ "title": "New Relic Developers",
+ "updated_at": "2020-08-29T01:39:08Z",
"type": "developer",
- "tags": [
- "New Relic One CLI",
- "nerdpack",
- "file structure",
- "nerdlets",
- "launchers"
- ],
- "external_id": "c97bcbb0a2b3d32ac93b5b379a1933e7b4e00161",
- "image": "",
- "url": "https://developer.newrelic.com/explore-docs/nerdpack-file-structure/",
- "published_at": "2020-08-28T01:50:39Z",
- "updated_at": "2020-08-14T01:49:25Z",
+ "external_id": "214583cf664ff2645436a1810be3da7a5ab76fab",
"document_type": "page",
"popularity": 1,
- "info": "An overview of the Nerdpack File Structure",
- "body": "Nerdpack file structure A New Relic One application is represented by a Nerdpack folder, which can include one or more Nerdlet files, and (optionally) one or more launcher files. Here we explain: The file structure for a Nerdpack, a Nerdlet, and a launcher How to link a launcher file to a Nerdlet How to link your application with a monitored entity For basic component definitions, see our component reference. Generate Nerdpack components There are two ways to generate a Nerdpack template: Generate a Nerdpack: Use the New Relic One CLI command nr1 create and select Nerdpack to create a Nerdpack template that includes a Nerdlet and a launcher. Generate Nerdlet or launcher individually: Use the New Relic One CLI command nr1 create and choose either Nerdlet or launcher. This can be useful when adding Nerdlets to an existing Nerdpack. For documentation on generating and connecting Nerdpack components, see our app building guides and the New Relic One CLI command reference. Nerdpack file structure When you generate a Nerdpack template using the nr1 create command, it has the following file structure: my-nerdlet ├── README.md ├── launchers │ └── my-nerdlet-launcher │ ├── icon.png │ └── nr1.json ├── nerdlets │ └── my-nerdlet-nerdlet │ ├── index.js │ ├── nr1.json │ └── styles.scss ├── node_modules │ ├── js-tokens │ ├── loose-envify │ ├── object-assign │ ├── prop-types │ ├── react │ ├── react-dom │ ├── react-is │ └── scheduler ├── nr1.json ├── package-lock.json └── package.json Copy Nerdlet file structure A Nerdpack can contain one or more Nerdlets. A Nerdlet folder starts out with three default files, index.js, nr1.json, and styles.scss. Here is what the default files look like after being generated using the nr1 create command: index.js The JavaScript code of the Nerdlet. import React from 'react'; export default class MyAwesomeNerdpack extends React.Component { render() { return
component. The items property collects the data by calling _getItems(), which contains sample values.
; Copy Step 3 of 10 Add the header and rows As the Table component renders a fixed number of header cells and rows, your next step is adding header components, as well as a function that returns the required table rows. Inside of the Table component, add the TableHeader and then a TableHeaderCell child for each heading. Since you don't know how many rows you'll need, your best bet is to call a function to build as many TableRows as items returned by _getItems(). ApplicationSizeCompanyTeamCommit; { ({ item }) => ( {item.name}{item.value}{item.company}{item.team}{item.commit} ); } Copy Step 4 of 10 Take a look at the application running in New Relic One: you should see something similar to the screenshot below. Step 5 of 10 Replace standard table cells with smart cells The New Relic One library includes cell components that can automatically format certain data types, like users, metrics, and entity names. The table you've just created contains columns that can benefit from those components: Application (an entity name) and Size (a metric). Before you can use EntityTitleTableRowCell and MetricTableRowCell, you have to add them to the import statement first. import { EntityTitleTableRowCell, MetricTableRowCell, ... /* All previous components */ } from 'nr1'; Copy Step 6 of 10 Update your table rows by replacing the first and second TableRowCells with entity and metric cells. Notice that EntityTitleTableRowCell and MetricTableRowCell are self-closing tags. { ({ item }) => ( {item.company}{item.team}{item.commit} ); } Copy Step 7 of 10 Time to give your table a second look: The cell components you've added take care of properly formatting the data. Step 8 of 10 Add some action to your table! Tables are great, but interactive tables can be better: As a last update, you are going to allow users to act on each data row. Add the _getActions() method to your index.js file, right before _getItems(). As you may have guessed from the code, _getActions() spawns an alert box when you click Team or Commit cells. _getActions() { return [ { label: 'Alert Team', iconType: TableRow.ACTIONS_ICON_TYPE.INTERFACE__OPERATIONS__ALERT, onClick: (evt, { item, index }) => { alert(`Alert Team: ${item.team}`); }, }, { label: 'Rollback Version', iconType: TableRow.ACTIONS_ICON_TYPE.INTERFACE__OPERATIONS__UNDO, onClick: (evt, { item, index }) => { alert(`Rollback from: ${item.commit}`); }, }, ]; } Copy Step 9 of 10 Find the TableRow component in your return statement and point the actions property to _getActions(). The TableRow actions property defines a set of actions that appear when the user hovers over a table row. Actions have a mandatory text and an onClick callback, but can also display an icon or be disabled if needed. Copy Step 10 of 10 Go back to your application and try hovering over any of the rows: Notice how the two available actions appear. When you click them, a function triggers with the selected row data as an argument, and an alert displays in your browser. Next steps You've built a table into a New Relic One application, using components to format data automatically and provide contextual actions. Well done! Keep exploring the Table components, their properties, and how to use them, in our SDK documentation.",
+ "body": "As a customer with a paid subscription to New Relic products, you are eligible to participate in preview access of the New Relic One platform (e.g. Telemetry Data Platform, Full Stack Observability, and Applied Intelligence products) for the period beginning July 31, 2020 and ending December 31, 2020 (“Preview Access”). BY DOWNLOADING, ACCESSING, INDICATING YOUR AGREEMENT TO, OR USING THE PREVIEW ACCESS PRODUCTS, YOU AGREE THAT YOUR PREVIEW ACCESS USAGE IS PURSUANT TO THESE SEPARATE TERMS AND CONDITIONS IN LIEU OF ANY OTHER TERMS. These terms do not have to be signed in order to be binding. If you do not agree to these terms and conditions, your sole remedy is to not participate in Preview Access. New Relic reserves the right to terminate or restrict Preview Access, in whole or in part, at any time. Notwithstanding the foregoing and any other materials provided by New Relic, select customers are ineligible for the Preview Access. For more help If you need more help, check out these support and learning resources: Browse the Explorers Hub to get help from the community and join in discussions. Find answers on our sites and learn how to use our support portal. Run New Relic Diagnostics, our troubleshooting tool for Linux, Windows, and macOS. Review New Relic's data security and licenses documentation.",
+ "info": "",
"_index": "520d1d5d14cc8a32e600034b",
"_type": "520d1d5d14cc8a32e600034c",
- "_score": 126.15987,
+ "_score": 393.32578,
"_version": null,
"_explanation": null,
"sort": null,
"highlight": {
- "title": "Add tables to your New Relic One application",
- "sections": "Add tables to your New Relic One application",
- "info": "Add a table to your New Relic One app.",
- "tags": "table in app",
- "body": " and set this.accountId to your Account ID as shown in the example. export default class Nr1HowtoAddTimePicker extends React.Component { constructor(props){ super(props) this.accountId = YOUR_ACCOUNT_ID; } ... } Copy Step 3 of 4 Run the demo application Change the directory back to nr1-how-to/create"
+ "body": ", 2020 (“Preview Access”). BY DOWNLOADING, ACCESSING, INDICATING YOUR AGREEMENT TO, OR USING THE PREVIEW ACCESS PRODUCTS, YOU AGREE THAT YOUR PREVIEW ACCESS USAGE IS PURSUANT TO THESE SEPARATE TERMS AND CONDITIONS IN LIEU OF ANY OTHER TERMS. These terms do not have to be signed in order to be binding"
},
- "id": "5efa989ee7b9d2ad567bab51"
+ "id": "5f23a0f7e7b9d29da9c82305"
},
{
- "image": "",
- "url": "https://developer.newrelic.com/components/platform-state-context/",
+ "category_2": "Product definitions",
+ "nodeid": 39646,
"sections": [
- "PlatformStateContext",
- "Usage",
- "Props"
+ "License information",
+ "General usage licenses",
+ "Special services licenses",
+ "Distributed licenses",
+ "Referenced policies",
+ "Product definitions",
+ "Usage plans",
+ "FAQ",
+ "New Relic One pricing: Definitions",
+ "For more help"
],
- "published_at": "2020-08-28T01:49:25Z",
- "title": "PlatformStateContext",
- "updated_at": "2020-08-01T01:47:08Z",
- "type": "developer",
- "external_id": "aa6b86b3dc0dcd7cd758b20655318b108875cce7",
+ "title": "New Relic One pricing: Definitions",
+ "category_0": "Licenses",
+ "type": "docs",
+ "category_1": "License information",
+ "external_id": "097fc095ef18942f3af1845237742340e36416b8",
+ "image": "",
+ "url": "https://docs.newrelic.com/docs/licenses/license-information/product-definitions/new-relic-one-pricing-definitions",
+ "published_at": "2020-08-25T18:54:19Z",
+ "updated_at": "2020-07-31T05:46:33Z",
+ "breadcrumb": "Contents / Licenses / License information / Product definitions",
"document_type": "page",
"popularity": 1,
- "info": "A PlatformStateContext component!",
- "body": "PlatformStateContext Usage Copy Props There are no props for this component.",
+ "info": "This document provides definitions of terminology you may see in New Relic contracts.",
+ "body": "This document provides definitions of terminology you may see in the Terms or this site for New Relic One pricing and billing: Account Account refers to the online account or subaccounts that New Relic provides for customers to manage their use of the Products. Commitment Term Commitment Term means the non-cancelable, committed Subscription Term for the Products. Customer Data Customer Data means the data, information, or content that Customer and its users send to an Account from the Software, the Customer Properties, or Third-Party Services. Customer Properties Customer Properties means Customer’s websites, infrastructure, networks, mobile applications, or other systems, as well as Customer accounts on Third-Party Services. Documentation Documentation means the New Relic technical guides and documentation made available from the dedicated ‘Documentation’ page of the New Relic website. GB Ingested A GB Ingested is a measurement of the volume of metrics, events, logs, traces, or other telemetry data sent to or generated by the Products for the benefit of the Customer, including from the Software, the Customer Properties, or Third-Party Services. Login Credentials Login Credentials means the username, email address, password, or other personal information that is provided by a Customer user in order to manage an Account. Monthly Provisioned User A Monthly Provisioned User is any user who can log into Customer’s Account(s) and access the New Relic One Product functionality as specified in an Order and the Documentation. Order Order means the purchasing order for access to the Service or related services that: (1) is either executed by the Parties or entered into by you via self-service, and references this Agreement, or (2) is entered into by you and a Channel Partner. Paid Terms of Service Paid Terms of Service means the legal terms and conditions located at: https://newrelic.com/termsandconditions/paid. Product(s) Product(s) mean the purchase of the New Relic subscription products described in the applicable Order and any updates, corrections, bug fixes, modifications, improvements, related services, new features, and functionality (made generally available to New Relic’s customer base) thereto. Software Software means the distributed software, APIs, scripts, or other code proprietary to New Relic provided with the Products. Terms Terms means the underlying Customer-New Relic agreement and the Order. Third-Party Services Third-Party Services means any third party platform, add-on, service, or product not provided by New Relic and that a user integrates or enables for use with the Products, including third-party applications and plug-ins. Unpaid Terms of Service Unpaid Terms of Service means the legal terms and conditions located at: https://newrelic.com/termsandconditions/unpaid. Usage Plan Usage Plan refers to the Service or Product pricing, invoicing related information, and product-specific terms (e.g. concurrent user account sessions) contained within the Documentation. For more help If you need more help, check out these support and learning resources: Browse the Explorers Hub to get help from the community and join in discussions. Find answers on our sites and learn how to use our support portal. Run New Relic Diagnostics, our troubleshooting tool for Linux, Windows, and macOS. Review New Relic's data security and licenses documentation.",
"_index": "520d1d5d14cc8a32e600034b",
"_type": "520d1d5d14cc8a32e600034c",
- "_score": 113.0163,
+ "_score": 334.1666,
"_version": null,
"_explanation": null,
"sort": null,
"highlight": {
- "title": "PlatformStateContext",
- "sections": "PlatformStateContext",
- "info": "A PlatformStateContext component!",
- "body": "PlatformStateContext Usage Copy Props There are no props for this component."
+ "info": "This document provides definitions of terminology you may see in New Relic contracts.",
+ "body": "This document provides definitions of terminology you may see in the Terms or this site for New Relic One pricing and billing: Account Account refers to the online account or subaccounts that New Relic provides for customers to manage their use of the Products. Commitment Term Commitment Term means"
},
- "id": "5efa997128ccbccc6f307dc0"
- }
- ],
- "/build-apps/howto-use-nrone-table-components": [
+ "id": "5f23b039196a67030b94f5c4"
+ },
{
- "image": "",
- "url": "https://developer.newrelic.com/components/table-header-cell/",
+ "category_2": "Special services licenses",
+ "nodeid": 13781,
"sections": [
- "TableHeaderCell",
- "Usage",
- "Props"
+ "License information",
+ "General usage licenses",
+ "Special services licenses",
+ "Distributed licenses",
+ "Referenced policies",
+ "Product definitions",
+ "Usage plans",
+ "FAQ",
+ "New Relic Diagnostics licenses",
+ "Proprietary license",
+ "New Relic Diagnostics license terms",
+ "Open-source licenses",
+ "For more help"
],
- "published_at": "2020-08-28T01:48:23Z",
- "title": "TableHeaderCell",
- "updated_at": "2020-08-03T04:46:36Z",
- "type": "developer",
- "external_id": "2a4be1419d1a6e501a8eed915b8acf7c9798259d",
+ "title": "New Relic Diagnostics licenses",
+ "category_0": "Licenses",
+ "type": "docs",
+ "category_1": "License information",
+ "external_id": "249a85e250c05a6c4d48d626b6a0a1cd03122922",
+ "image": "",
+ "url": "https://docs.newrelic.com/docs/licenses/license-information/special-services-licenses/new-relic-diagnostics-licenses",
+ "published_at": "2020-08-26T00:19:07Z",
+ "updated_at": "2020-08-08T04:05:33Z",
+ "breadcrumb": "Contents / Licenses / License information / Special services licenses",
"document_type": "page",
"popularity": 1,
- "info": "A TableHeaderCell component!",
- "body": "TableHeaderCell Usage Copy Props There are no props for this component.",
+ "info": "A list of third-party licenses we use in New Relic Diagnostics.",
+ "body": "Proprietary license New Relic Diagnostics license terms These New Relic Diagnostics License Terms (“Terms”) set forth the terms and conditions under which you (“Customer”) may use New Relic Diagnostics (the “Software”), as made available by New Relic, Inc. (“New Relic”). By clicking “accept” or downloading or using the Software, you agree to be bound by these Terms. If you are agreeing to these Terms on behalf of your company, then “Customer” means your company and you are binding your company to these Terms. 1. License Grant. Subject to all of the terms and conditions of these Terms, New Relic grants Customer a limited, non-exclusive, non-transferable, non-sublicensable license to use the Software in accordance with its documentation in support of Customer’s use of New Relic products to which Customer has a separate subscription (“New Relic Products”). Unless otherwise specified, there is no fee for use of the Software. 2. License Restrictions. Customer will not (a) sell, rent, sublicense, transfer, time-share or otherwise provide access to any copies of the Software, or portions thereof, to a third party; (b) modify, decompile, disassemble or reverse engineer the Software; (c) use the Software to develop services or products for sale or include any components of the Software in any product; (d) remove any product identification, proprietary, copyright or other notices in the Software; or (e) publicly disseminate performance information or analysis (including benchmarks) relating to the Software. 3. Ownership. Except for the limited license rights expressly provided herein, New Relic and its suppliers have and will retain all right, title and interest in and to the Software, and all copies, updates, modifications and derivative works thereof. Customer acknowledges that it is obtaining only a limited license right to the Software and no ownership rights are being conveyed to Customer under these Terms or otherwise. 4. Usage Data. Customer agrees that New Relic and its affiliates have the right to collect Usage Data from Customer through the Software and use Usage Data to support, operate and improve New Relic products and services and for other lawful business purposes. “Usage Data” means diagnostics data related to the use of the Software with New Relic Products, including, without limitation, configuration information, details on diagnostics tasks, New Relic account and application ID numbers and New Relic license keys. For clarity, Usage Data is not considered “Customer Data”, “your Data” or any other similar term as used in any applicable subscription or license agreement for New Relic Products. At Customer’s election, Customer may disable the collection of Usage Data as described in the Software documentation. 5. Disclaimers. New Relic is not obligated to provide any support or maintenance for the Software. ALL USE OF SOFTWARE IS AT CUSTOMER’S OWN RISK. SOFTWARE IS PROVIDED “AS IS,” WITH ALL FAULTS AND WITHOUT WARRANTY OF ANY KIND, EXPRESS, IMPLIED OR STATUTORY, INCLUDING, BUT NOT LIMITED TO, WARRANTIES OF TITLE OR NON-INFRINGEMENT. CUSTOMER MAY HAVE OTHER STATUTORY RIGHTS, HOWEVER, THE DURATION OF STATUTORILY REQUIRED WARRANTIES, IF ANY, WILL BE LIMITED TO THE FULLEST EXTENT PERMITTED BY LAW. 6. Limitation of Liability. TO THE FULLEST EXTENT PERMITTED BY LAW, IN NO EVENT WILL NEW RELIC BE LIABLE FOR ANY DIRECT, INDIRECT, SPECIAL, INCIDENTAL, OR CONSEQUENTIAL DAMAGES OF ANY KIND, REGARDLESS OF THE FORM OF ACTION, WHETHER IN CONTRACT, TORT (INCLUDING NEGLIGENCE), STRICT LIABILITY OR OTHERWISE, EVEN IF INFORMED OF THE POSSIBILITY OF SUCH DAMAGES IN ADVANCE. TO THE EXTENT ANY OF THE ABOVE LIMITATIONS ARE NOT ENFORCEABLE AT APPLICABLE LAW, NEW RELIC’S ENTIRE LIABILITY TO CUSTOMER UNDER THESE TERMS WILL NOT EXCEED $50. THESE LIMITATIONS ON LIABILITY ARE A FUNDAMENTAL BASIS OF THE BARGAIN AND NEW RELIC WOULD NOT BE ABLE TO PROVIDE THE SOFTWARE WITHOUT SUCH LIMITATIONS. THESE LIMITATIONS ON LIABILITY WILL APPLY NOTWITHSTANDING ANY FAILURE OF ESSENTIAL PURPOSE OF ANY LIMITED REMEDY. 7. Changes and Termination. At its discretion, without notice or liability to Customer, New Relic may (a) update, modify or discontinue the Software; (b) modify these Terms, effective upon posting; or (c) terminate or suspend these Terms or Customer’s access to the Software. If Customer does not agree with any modification, its sole remedy is to terminate its use of the Software. Upon any termination or suspension, Customer must stop using the Software. 8. Third Party Code. The Software may contain or be provided with third party code (including code which may be made available to Customer in source code form). A list of third party code and ownership, use, warranty and modification rights with respect to such code may be identified in the documentation or provided by New Relic upon Customer’s written request. New Relic is not responsible for applications and services not licensed by New Relic. 9. Export Compliance. Customer acknowledges that the Software is subject to export restrictions by the U.S. government and import restrictions by certain foreign governments. Customer shall not remove or export from the U.S. or allow the export or re-export of any part of the Software or any direct product thereof: (a) into (or to a national or resident of) any embargoed or terrorist-supporting country; (b) to anyone on the U.S. Commerce Department’s Table of Denial Orders or U.S. Treasury Department’s list of Specially Designated Nationals; (c) to any country to which such export or re-export is restricted or prohibited, or as to which the U.S. government or any agency thereof requires an export license or other governmental approval at the time of export or re-export without first obtaining such license or approval; or (d) otherwise in violation of any export or import restrictions, laws or regulations of any U.S. or foreign agency or authority. Customer agrees to the foregoing and warrants that Customer is not located in, under the control of, or a national or resident of any such prohibited country or on any such prohibited party list. 10. Government End-Users. The Software is commercial computer software. If Customer is an entity of the U.S. government, the use, duplication, reproduction, release, modification, disclosure or transfer of the Software, or any related documentation of any kind, is restricted by a license agreement or by these Terms in accordance with Federal Acquisition Regulation 12.212 for civilian purposes and Defense Federal Acquisition Regulation Supplement 227.7202 for military purposes. The Software was developed fully at private expense. All other use is prohibited. 11. General. These Terms will be governed by and construed under the laws of the State of California and the U.S. without regard to conflicts of law provisions thereof, and without regard to the United Nations Convention on the International Sale of Goods. The jurisdiction and venue for actions arising out of or relating to these Terms shall be in the state and federal courts in San Francisco, California. The parties are independent contractors. Customer may not assign these Terms without New Relic’s prior written consent and any attempt to do so will be void; New Relic may assign these Terms freely to any party without Customer’s consent. If any provision of these Terms is held by a court of competent jurisdiction to be unenforceable or invalid for any reason, that provision shall be limited to the minimum extent necessary so that these Terms shall otherwise remain in effect. These Terms are the entire agreement between the parties relating to the Software, and supersede all prior or contemporaneous agreements (oral or written) relating to the Software. Any separate agreement Customer has for New Relic Products does not apply to the Software. Open-source licenses We love open-source software, and use the following in New Relic Diagnostics. Thank you, open-source community, for making these fine tools! Some of these are listed under multiple software licenses, and in that case we have listed the license we've chosen to use. Library License clbanning/mxj [external link] MIT [external link] go-yaml/yaml [external link] Apache 2.0 [external link] StackExchange/wmi [external link] MIT [external link] go-ole/go-ole [external link] MIT [external link] shirou/gopsutil [external link] BSD-3-Clause [external link] shirou/w32 [external link] BSD-3-Clause [external link] cheggaaa/pb [external link] BSD-3-Clause [external link] google/uuid [external link] BSD-3-Clause [external link] For more help If you need more help, check out these support and learning resources: Browse the Explorers Hub to get help from the community and join in discussions. Find answers on our sites and learn how to use our support portal. Run New Relic Diagnostics, our troubleshooting tool for Linux, Windows, and macOS. Review New Relic's data security and licenses documentation.",
"_index": "520d1d5d14cc8a32e600034b",
"_type": "520d1d5d14cc8a32e600034c",
- "_score": 614.49255,
+ "_score": 289.66766,
"_version": null,
"_explanation": null,
"sort": null,
"highlight": {
- "title": "TableHeaderCell",
- "sections": "TableHeaderCell",
- "info": "A TableHeaderCellcomponent!",
- "body": "TableHeaderCell Usage Copy Props There are no props for this component."
+ "sections": "New Relic Diagnostics license terms",
+ "body": "Proprietary license New Relic Diagnostics license terms These New Relic Diagnostics License Terms (“Terms”) set forth the terms and conditions under which you (“Customer”) may use New Relic Diagnostics (the “Software”), as made available by New Relic, Inc. (“New Relic”). By clicking “accept"
},
- "id": "5efa9906196a67523e76646e"
- },
+ "id": "5f2e248d64441f8b1e56a984"
+ }
+ ],
+ "/automate-workflows/get-started-kubernetes": [
{
"image": "",
- "url": "https://developer.newrelic.com/components/table-row/",
+ "url": "https://developer.newrelic.com/automate-workflows/",
"sections": [
- "TableRow",
- "Usage",
- "Props"
+ "Automate workflows",
+ "Guides to automate workflows",
+ "Quickly tag resources",
+ "Set up New Relic using Helm chats",
+ "Automatically tag a simple \"Hello World\" Demo across the entire stack",
+ "Automate common tasks",
+ "Set up New Relic using the Kubernetes operator",
+ "Set up New Relic using Terraform"
],
- "published_at": "2020-08-28T01:49:25Z",
- "title": "TableRow",
- "updated_at": "2020-08-03T04:45:42Z",
+ "published_at": "2020-08-29T01:50:40Z",
+ "title": "Automate workflows",
+ "updated_at": "2020-08-29T01:50:40Z",
"type": "developer",
- "external_id": "b9ca0d4e07a506dd961eb2194c5344bfa9ab770d",
+ "external_id": "d4f408f077ed950dc359ad44829e9cfbd2ca4871",
"document_type": "page",
"popularity": 1,
- "info": "A TableRow component!",
- "body": "TableRow Usage Copy Props There are no props for this component.",
+ "body": "Automate workflows When building today's complex systems, you want an easy, predictable way to verify that your configuration is defined as expected. This concept, Observability as Code, is brought to life through a collection of New Relic-supported orchestration tools, including Terraform, AWS CloudFormation, and a command-line interface. These tools enable you to integrate New Relic into your existing workflows, easing adoption, accelerating deployment, and returning focus to your main job — getting stuff done. In addition to our Terraform and CLI guides below, find more automation solutions in our Developer Toolkit. Guides to automate workflows 5 min Quickly tag resources Add tags to apps for easy filtering 20 min Set up New Relic using Helm chats Learn how to set up New Relic using Helm charts 30 min Automatically tag a simple \"Hello World\" Demo across the entire stack See how easy it is to leverage automation in your DevOps environment! 20 min Automate common tasks Use the New Relic CLI to tag apps and create deployment markers 20 min Set up New Relic using the Kubernetes operator Learn how to provision New Relic resources using the Kubernetes operator 20 min Set up New Relic using Terraform Learn how to provision New Relic resources using Terraform",
+ "info": "",
"_index": "520d1d5d14cc8a32e600034b",
"_type": "520d1d5d14cc8a32e600034c",
- "_score": 506.2896,
+ "_score": 139.07822,
"_version": null,
"_explanation": null,
"sort": null,
"highlight": {
- "title": "TableRow",
- "sections": "TableRow",
- "info": "A TableRowcomponent!",
- "body": "TableRow Usage Copy Props There are no props for this component."
+ "sections": "Set up New Relic using the Kubernetesoperator",
+ "body": " it is to leverage automation in your DevOps environment! 20 min Automate common tasks Use the New Relic CLI to tag apps and create deployment markers 20 min Set up New Relic using the Kubernetesoperator Learn how to provision New Relic resources using the Kubernetesoperator 20 min Set up New Relic using Terraform Learn how to provision New Relic resources using Terraform"
},
- "id": "5efa98d564441f93435f7e24"
+ "id": "5efa999c196a67dfb4766445"
},
{
- "image": "",
- "url": "https://developer.newrelic.com/build-apps/",
+ "category_2": "Alert conditions",
+ "nodeid": 10951,
"sections": [
- "Build apps",
- "Guides to build apps",
- "Create a \"Hello, World!\" application",
- "Permissions for managing applications",
- "Set up your development environment",
- "Add, query, and mutate data using NerdStorage",
- "Add a time picker to your app",
- "Add the NerdGraphQuery component to an application",
- "Add a table to your app",
- "Publish and deploy apps",
- "Create a custom map view"
- ],
- "published_at": "2020-08-28T01:45:16Z",
- "title": "Build apps",
- "updated_at": "2020-08-28T01:45:16Z",
- "type": "developer",
- "external_id": "abafbb8457d02084a1ca06f3bc68f7ca823edf1d",
- "document_type": "page",
- "popularity": 1,
- "body": "Build apps You know better than anyone what information is crucial to your business, and how best to visualize it. Sometimes, this means going beyond dashboards to creating your own app. With React and GraphQL, you can create custom views tailored to your business. These guides are designed to help you start building apps, and dive into our library of components. We also have a growing number of open source apps that you can use to get started. The rest is up to you. Guides to build apps 15 min Create a \"Hello, World!\" application Build a \"Hello, World!\" app and publish it to New Relic One Permissions for managing applications Learn about permissions for subscribing to apps 20 min Set up your development environment Prepare to build apps and contribute to this site 45 min Add, query, and mutate data using NerdStorage NerdStorage is a document database accessible within New Relic One. It allows you to modify, save, and retrieve documents from one session to the next. 20 min Add a time picker to your app Add a time picker to a sample application 20 minutes Add the NerdGraphQuery component to an application The NerdGraphQuery component allows you to query data from your account and add it to a dropdown menu in an application 30 min Add a table to your app Add a table to your New Relic One app 30 min Publish and deploy apps Start sharing the apps you build 30 min Create a custom map view Build an app to show page view data on a map",
- "info": "",
- "_index": "520d1d5d14cc8a32e600034b",
- "_type": "520d1d5d14cc8a32e600034c",
- "_score": 418.40497,
- "_version": null,
- "_explanation": null,
- "sort": null,
- "highlight": {
- "title": "Build apps",
- "sections": "Add the NerdGraphQuery component to an application",
- "body": ". It allows you to modify, save, and retrieve documents from one session to the next. 20 min Add a time picker to your app Add a time picker to a sample application 20 minutes Add the NerdGraphQuery component to an application The NerdGraphQuery component allows you to query data from your account"
- },
- "id": "5efa999d64441fc0f75f7e21"
- },
- {
- "category_2": "Plan your cloud adoption",
- "nodeid": 16121,
- "sections": [
- "Welcome to New Relic",
+ "New Relic Alerts",
"Get started",
- "Measure DevOps success",
- "Plan your cloud adoption",
- "Optimize your cloud native environment",
- "New Relic University",
- "Create application baselines",
- "1. Identify components",
- "2. Determine compatibility",
- "3. Deploy monitoring",
- "4. Gather metrics",
- "5. Set up Dashboards",
- "Expert tips",
+ "Alert policies",
+ "Alert conditions",
+ "Alert violations",
+ "Alert Incidents",
+ "Alert notifications",
+ "Troubleshooting",
+ "Rules, limits, and glossary",
+ "Alerts and Nerdgraph",
+ "REST API alerts",
+ "Create baseline alert conditions",
+ "How it works",
+ "Set baseline thresholds",
+ "Baseline rules and settings",
"For more help"
],
- "title": "Create application baselines",
- "category_0": "Using New Relic",
+ "title": "Create baseline alert conditions",
+ "category_0": "Alerts and Applied intelligence",
"type": "docs",
- "category_1": "Welcome to New Relic",
- "external_id": "078ad6255d0cbad2526407d00a11095c5b6e23e2",
- "image": "",
- "url": "https://docs.newrelic.com/docs/using-new-relic/welcome-new-relic/plan-your-cloud-adoption-strategy/create-application-baselines",
- "published_at": "2020-08-25T18:29:56Z",
- "updated_at": "2020-08-21T14:45:36Z",
- "breadcrumb": "Contents / Using New Relic / Welcome to New Relic / Plan your cloud adoption",
- "document_type": "page",
- "popularity": 1,
- "info": "Use New Relic to establish a baseline to use for comparison during your cloud adoption process.",
- "body": "Cloud migrations can take many forms. Some companies choose to port their applications directly from their data center to the cloud (a “Lift and Shift” migration) while others focus on completely re-architecting their applications to take advantage of benefits available only in the cloud. No matter your approach, there are three primary questions you want to answer after your migration: Has my application gotten slower? Is my application less stable than before? Am I losing customers due to either of the previous questions? To answer these questions, start by performing some basic testing to establish a baseline for the performance and availability of your systems. A baseline is a measurement of the current performance and availability of your application, which you then use as a comparison after your migration to validate your business case. In some cases, you may change a baseline when you perform migration acceptance testing. You can also use a baseline as a comparison point during your migration to make sure that you are on track. 1. Identify components Before you begin a cloud migration, identify all the tiers of your entire application stack. List all of the components (applications, services, etc.) that you want to migrate. Segment the application stack as follows: Application (backend/microservices/cron jobs) Dependency services, such as the message queue Database Website Underlying server and infrastructure Make sure that you have access to applications and instances before you start creating application baselines. Engage your application owners, DevOps engineers, and product managers for access. Example: List of components Here is an example of the list of components in an application stack: Component Name Owner Language Stack Accessibility (Internet, Intranet) Operating System Service 1 John Doe Java Internet RHEL 6 Service 2 Maya Wiz .NET Intranet Win2003 R2 RabbitMQ John Doe Java Intranet AIX Website Maya Wiz Classic ASP Internet Win2000 MS SQL Dave Z NA Intranet Win2003 R2 2. Determine compatibility Once you identify the applications that you want to migrate, it is time to verify which application tiers to monitor with the New Relic platform. Work with stakeholders in your organization to determine the amount of instrumentation that is possible–or allowed–within your organization. This is an important step and one that will pay off, as the more you can instrument, the better your baselines. Here are the New Relic products to use for baselining, depending on the components that you identified: New Relic APM: Monitor your web apps with New Relic APM. See Compatibility and requirements for New Relic agents and products to learn precise compatibility details for each supported language. New Relic Infrastructure: Monitor your hosts with New Relic Infrastructure. See Compatibility and requirements for New Relic Infrastructure for supported operating systems and environments. You can also instrument other products and services with on-host integrations. New Relic Synthetics: Monitor web frontends and APIs with New Relic Synthetics. Sometimes, you may not be able to instrument your on-premise environment with APM or Infrastructure. For example, maybe your organization's policy forbids installing an agent behind a firewall. In these cases, if the application has a web frontend, use Synthetics, as it offers non-agent monitoring while still providing the ability to establish a baseline. Example: Components matched to New Relic products Match the components that you identified with their corresponding products: Component Name Tier Owner Language Stack Accessibility (Internet/ Intranet) Operating System New Relic Products Service 1 John Doe Java Internet RHEL 6 APM, Infrastructure, Synthetics Service 2 Maya Wiz .NET Intranet Win2003 R2 APM, Infrastructure ActiveMQ John Doe Java Intranet AIX APM, Plugin Website Maya Wiz Classic ASP Internet Win2000 Synthetics MS SQL Dave Z n/a Intranet Win2003 R2 Infrastructure, On-host Integration 3. Deploy monitoring Based on the component-product matches you made, deploy agents or monitors across your architecture: Deploy New Relic APM Install the APM agent on your application stack. The steps to install the APM agent are different based on language. Deploy New Relic Infrastructure After reviewing the requirements for New Relic Infrastructure, follow the instructions to install the Infrastructure agent on your hosts: Install for Linux Install for Windows Server Install on AWS Elastic Beanstalk Install with a configuration management tool Deploy Infrastructure on-host integrations To gain extended visibility into applications that your code depends on, deploy on-host integrations. Available integrations include Apache, MySQL, NGINX, and others. Create New Relic Synthetics monitors New Relic Synthetics is a suite of automated, scriptable tools to monitor your websites, critical business transactions, and API endpoints. To get started add a monitor. Make sure to verify that your website URL is accessible from the public network. You may also need to add New Relic IPs to your allow list. 4. Gather metrics After you deploy the agents and monitors, identify which metrics are the most important to your business and use these metrics to define your KPIs. Some recommendations include: Response time: Time taken to respond to a request. Throughput: Number of requests that came in through the application. Requesting queuing (Apache, IIS, NGINX): Duration of time taken for a request to reach your application. Database call duration: Duration of time taken to complete a database call. DB call counts: Number of calls made by application code to the database. Error rate: Percent of errors reported. Apdex score: An industry standard to measure user satisfaction with the response time of web applications and services. DNS setup timing: The time it takes to connect and receive data from DNS. SSL setup timing: The time it takes to establish an SSL connection. You can find some of these metrics in service maps, as well as on APM, and Browser overview pages. For more detailed information about navigating, interpreting, and using New Relic APM, check out these New Relic University’s tutorials: Overview dashboard tour Transactions dashboard Understanding Apdex 5. Set up Dashboards After you define your KPIs, it is easy to visualize them in New Relic Dashboards. Dashboards provide a single location to view all the data that New Relic products gather. Dashboards data consists of events, and each event has an event type, a timestamp, and key-value attributes. For more information about events, see Data collection and Default events for New Relic products. You can locate your KPIs and business metrics data in New Relic using the data explorer and the NRQL query language. You can also build Dashboards to track the performance of those KPIs: Example: Component performance compared against baselines Continuing the examples in this document, the following table illustrates the maturity of your application performance over a period of time based on deployment milestones. Each milestone will serve as a new baseline for your applications: Component Milestone 1 Milestone 2 Milestone N Environment Component Name Response Time SLA Apdex Response Time SLA Apdex Response On-Prem Service 1 1.5 secs 80% 70% 1.5 secs 68% 0.65 1.4 secs Cloud Service 1 0.9 secs 96.8% 95% 0.9 secs 98% 0.99 0.7 secs On-Prem Service 2 0.7 secs 73% 68% 0.7 secs 80% 0.78 0.85 secs Cloud Service 2 0.6 secs 90% 92% 0.6 secs 89% 0.90 0.5 secs After your migration, compare these baselines against your migration acceptance testing baselines. Expert tips If you find that you need data that is not captured by default instrumentation, New Relic makes it easy to capture custom data: APM custom instrumentation Browser custom data Infrastructure custom attributes Custom event data Mobile custom data Synthetics custom attributes You can also learn more about APM custom instrumentation with the New Relic University Custom data tutorial series. For more help",
- "_index": "520d1d5d14cc8a32e600034b",
- "_type": "520d1d5d14cc8a32e600034c",
- "_score": 317.55853,
- "_version": null,
- "_explanation": null,
- "sort": null,
- "highlight": {
- "title": "Create application baselines",
- "sections": "1. Identify components",
- "info": "Use New Relic to establish a baseline to use for comparison during your cloud adoption process.",
- "category_0": "Using New Relic",
- "category_1": "Welcome to New Relic",
- "body": " ASP Internet Win2000 Synthetics MS SQL Dave Z n/a Intranet Win2003 R2 Infrastructure, On-host Integration 3. Deploy monitoring Based on the component-product matches you made, deploy agents or monitors across your architecture: Deploy New Relic APM Install the APM agent on your application stack"
- },
- "id": "5ad48685c75d0766faa181bd"
- },
- {
- "sections": [
- "Map page views by region in a custom app",
- "Before you begin",
- "New Relic terminology",
- "Build a custom app with a table chart",
- "Query your browser data",
- "Create and serve a new Nerdpack",
- "Review your app files and view your app locally",
- "Hard code your account ID",
- "Import the TableChart component",
- "Add a table with a single row",
- "Customize the look of your table (optional)",
- "Get your data into that table",
- "Make your app interactive with a text field",
- "Import the TextField component",
- "Add a row for your text field",
- "Build the text field object",
- "Get your data on a map",
- "Install Leaflet",
- "Add a webpack config file for Leaflet",
- "Import modules from Leaflet",
- "Import additional modules from New Relic One",
- "Get data for the map",
- "Customize the map marker colors",
- "Set your map's default center point",
- "Add a row for your map",
- "Replace \"Hello\" with the Leaflet code"
- ],
- "title": "Map page views by region in a custom app",
- "type": "developer",
- "tags": [
- "custom app",
- "map",
- "page views",
- "region",
- "nerdpack"
- ],
- "external_id": "6ff5d696556512bb8d8b33fb31732f22bab455cb",
- "image": "https://developer.newrelic.com/static/d87a72e8ee14c52fdfcb91895567d268/0086b/pageview.png",
- "url": "https://developer.newrelic.com/build-apps/map-pageviews-by-region/",
- "published_at": "2020-08-28T01:51:51Z",
- "updated_at": "2020-08-14T01:45:09Z",
- "document_type": "page",
- "popularity": 1,
- "info": "Build a New Relic app showing page view data on a world map.",
- "body": "Map page views by region in a custom app 30 min New Relic has powerful and flexible tools for building custom apps and populating them with data. This guide shows you how to build a custom app and populate it with page view data using New Relic's Query Language (NRQL - pronounced 'nurkle'). Then you make your data interactive. And last, if you have a little more time and want to install a third-party React library, you can display the page view data you collect on a map of the world. In this guide, you build an app to display page view data in two ways: In a table On a map Please review the Before you begin section to make sure you have everything you need and don't get stuck halfway through. Before you begin In order to get the most out of this guide, you must have: A New Relic developer account, API key, and the command-line tool. If you don't have these yet, see the steps in Setting up your development environment New Relic Browser page view data to populate the app. Without this data, you won't be able to complete this guide. To add your data to a world map in the second half of the guide: npm, which you'll use during this section of the guide to install Leaflet, a third-party JavaScript React library used to build interactive maps. If you're new to React and npm, you can go here to install Node.js and npm. New Relic terminology The following are some terms used in this guide: New Relic application: The finished product where data is rendered in New Relic One. This might look like a series of interactive charts or a map of the world. Nerdpack: New Relic's standard collection of JavaScript, JSON, CSS, and other files that control the functionality and look of your application. For more information, see Nerdpack file structure. Launcher: The button on New Relic One that launches your application. Nerdlets: New Relic React components used to build your application. The three default files are index.js, nr1.json, and styles.scss, but you can customize and add your own. Build a custom app with a table chart Step 1 of 8 Query your browser data Use Query builder to write a NRQL query to see your page view data, as follows. On New Relic One, select Query your data (in the top right corner). That puts you in NRQL mode. You'll use NRQL to test your query before dropping the data into your table. Copy and paste this query into a clear query field, and then select Run. FROM PageView SELECT count(*), average(duration) WHERE appName = 'WebPortal' FACET countryCode, regionCode SINCE 1 week ago LIMIT 1000 Copy If you have PageView data, this query shows a week of average page views broken down by country and limited to a thousand items. The table will be full width and use the \"chart\" class defined in the CSS. If you don't have any results at this point, ensure your query doesn't have any errors. If your query is correct, you might not have the Browser agent installed. Step 2 of 8 Create and serve a new Nerdpack To get started, create a new Nerdpack, and serve it up to New Relic from your local development environment: Create a new Nerdpack for this app: nr1 create --type nerdpack --name pageviews-app Copy Serve the project up to New Relic: cd pageviews-app && nr1 nerdpack:serve Copy Step 3 of 8 Review your app files and view your app locally Navigate to your pageviews-app to see how it's structured. It contains a launcher folder, where you can customize the description and icon that will be displayed on the app's launcher in New Relic One. It also contains nerdlets, which each contain three default files: index.js, nr1.json, and styles.scss. You'll edit some of these files as part of this guide. For more information, see Nerdpack file structure. Now in your browser, open https://one.newrelic.com/?nerdpacks=local, and then click Apps to see the pageview-apps Nerdpack that you served up. When you select the launcher, you see a Hello message. Step 4 of 8 Hard code your account ID For the purposes of this exercise and for your convenience, hard code your account ID. In the pageview-app-nerdlet directory, in the index.js file, add this code between the import and export lines. (Read about finding your account ID here). const accountId = [Replace with your account ID]; Copy Step 5 of 8 Import the TableChart component To show your data in a table chart, import the TableChart component from New Relic One. To do so, in index.js, add this code under import React. import { TableChart } from `nr1`; Copy Step 6 of 8 Add a table with a single row To add a table with a single row, in the index.js file, replace this line: return
Hello, pageview-app-nerdlet Nerdlet!
; Copy with this export code: export default class PageViewApp extends React.Component { render() { return (
); } } Copy Step 7 of 8 Customize the look of your table (optional) You can use standard CSS to customize the look of your components. In the styles.scss file, add this CSS. Feel free to customize this CSS to your taste. .container { width: 100%; height: 99vh; display: flex; flex-direction: column; .row { margin: 10px; display: flex; flex-direction: row; } .chart { height: 250px; } } Copy Step 8 of 8 Get your data into that table Now that you've got a table, you can drop a TableChart populated with data from the NRQL query you wrote at the very beginning of this guide. Put this code into the row div. ; Copy Go to New Relic One and click your app to see your data in the table. (You might need to serve your app to New Relic again.) Congratulations! You made your app! Continue on to make it interactive and show your data on a map. Make your app interactive with a text field Once you confirm that data is getting to New Relic from your app, you can start customizing it and making it interactive. To do this, you add a text field to filter your data. Later, you use a third-party library called Leaflet to show that data on a world map. Step 1 of 3 Import the TextField component Like you did with the TableChart component, you need to import a TextField component from New Relic One. import { TextField } from 'nr1'; Copy Step 2 of 3 Add a row for your text field To add a text field filter above the table, put this code above the TableChart div. The text field will have a default value of \"US\".
; Copy Step 3 of 3 Build the text field object Above the render() function, add a constructor to build the text field object. constructor(props) { super(props); this.state = { countryCode: null } } Copy Then, add a constructor to your render() function. Above return, add: const { countryCode } = this.state; Copy Now add countryCode to your table chart query. ; Copy Reload your app to try out the text field. Get your data on a map To create the map, you use npm to install Leaflet. Step 1 of 9 Install Leaflet In your terminal, type: npm install --save leaflet react-leaflet Copy In your nerdlets styles.scss file, import the Leaflet CSS: @import `~leaflet/dist/leaflet.css`; Copy While you're in styles.scss, fix the width and height of your map: .containerMap { width: 100%; z-index: 0; height: 70vh; } Copy Step 2 of 9 Add a webpack config file for Leaflet Add a webpack configuration file .extended-webpackrc.js to the top-level folder in your nerdpack. This supports your use of map tiling information data from Leaflet. module.exports = { module: { rules: [ { test: /\\.(png|jpe?g|gif)$/, use: [ { loader: 'file-loader', options: {}, }, { loader: 'url-loader', options: { limit: 25000 }, }, ], }, ], }, }; Copy Step 3 of 9 Import modules from Leaflet In index.js, import modules from Leaflet. import { Map, CircleMarker, TileLayer } from 'react-leaflet'; Copy Step 4 of 9 Import additional modules from New Relic One You need several more modules from New Relic One to make the Leaflet map work well. Import them with this code: import { NerdGraphQuery, Spinner, Button, BlockText } from 'nr1'; Copy NerdGraphQuery lets you make multiple NRQL queries at once and is what will populate the map with data. Spinner adds a loading spinner. Button gives you button components. BlockText give you block text components. Step 5 of 9 Get data for the map Using latitude and longitude with country codes, you can put New Relic data on a map. mapData() { const { countryCode } = this.state; const query = `{ actor { account(id: 1606862) { mapData: nrql(query: \"SELECT count(*) as x, average(duration) as y, sum(asnLatitude)/count(*) as lat, sum(asnLongitude)/count(*) as lng FROM PageView FACET regionCode, countryCode WHERE appName = 'WebPortal' ${countryCode ? ` WHERE countryCode like '%${countryCode}%' ` : ''} LIMIT 1000 \") { results nrql } } } }`; return query; }; Copy Step 6 of 9 Customize the map marker colors Above the mapData function, add this code to customize the map marker colors. getMarkerColor(measure, apdexTarget = 1.7) { if (measure <= apdexTarget) { return '#11A600'; } else if (measure >= apdexTarget && measure <= apdexTarget * 4) { return '#FFD966'; } else { return '#BF0016'; } }; Copy Feel free to change the HTML color code values to your taste. In this example, #11A600 is green, #FFD966 is sort of yellow, and #BF0016 is red. Step 7 of 9 Set your map's default center point Set a default center point for your map using latitude and longitude. const defaultMapCenter = [10.5731, -7.5898]; Copy Step 8 of 9 Add a row for your map Between the text field row and the table chart row, insert a new row for the map content using NerdGraphQuery.
{({ loading, error, data }) => { if (loading) { return ; } if (error) { return 'Error'; } const { results } = data.actor.account.mapData; console.debug(results); return 'Hello'; }}
; Copy Reload your application in New Relic One to test that it works. Step 9 of 9 Replace \"Hello\" with the Leaflet code Replace return \"Hello\"; with: return ( ); Copy This code creates a world map centered on the latitude and longitude you chose using OpenStreetMap data and your marker colors. Reload your app to see the pageview data on the map!",
- "_index": "520d1d5d14cc8a32e600034b",
- "_type": "520d1d5d14cc8a32e600034c",
- "_score": 306.57373,
- "_version": null,
- "_explanation": null,
- "sort": null,
- "highlight": {
- "title": "Map page views by regionin a custom app",
- "sections": "Import the TableChartcomponent",
- "info": "Build a New Relicapp showing page view data on a world map.",
- "tags": "custom app",
- "body": " with a single row To add a table with a single row, in the index.js file, replace this line: return <h1>Hello, pageview-app-nerdlet Nerdlet!</h1>; Copy with this export code: export default class PageViewApp extends React.Component { render() { return ( <div className="container"> <div className="row"></div"
- },
- "id": "5efa993c196a67066b766469"
- }
- ],
- "/build-apps/build-hello-world-app": [
- {
- "sections": [
- "Intro to New Relic One API components",
- "Components of the SDK",
- "UI components",
- "Chart components",
- "Query and storage components",
- "Platform APIs"
- ],
- "title": "Intro to New Relic One API components",
- "type": "developer",
- "tags": [
- "SDK components",
- "New Relic One apps",
- "UI components",
- "chart components",
- "query and storage components",
- "Platform APIs"
- ],
- "external_id": "3620920c26bcd66c59c810dccb1200931b23b8c2",
- "image": "",
- "url": "https://developer.newrelic.com/explore-docs/intro-to-sdk/",
- "published_at": "2020-08-28T01:49:25Z",
- "updated_at": "2020-08-14T01:47:12Z",
+ "category_1": "New Relic Alerts",
+ "translation_ja_url": "https://docs.newrelic.co.jp/docs/alerts-applied-intelligence/new-relic-alerts/alert-conditions/create-baseline-alert-conditions",
+ "external_id": "0708312e6e3221aa381963e90472d3f7016d4dc6",
+ "image": "https://docs.newrelic.com/sites/default/files/thumbnails/image/new-relic-alerts-baseline-thresholds.png",
+ "url": "https://docs.newrelic.com/docs/alerts-applied-intelligence/new-relic-alerts/alert-conditions/create-baseline-alert-conditions",
+ "published_at": "2020-08-25T20:10:43Z",
+ "updated_at": "2020-08-15T08:34:17Z",
+ "breadcrumb": "Contents / Alerts and Applied intelligence / New Relic Alerts / Alert conditions",
"document_type": "page",
"popularity": 1,
- "info": "Intro to New Relic One API components",
- "body": "Intro to New Relic One API components To help you build New Relic One applications, we provide you with the New Relic One SDK. Here we give you an introduction to the types of API calls and components in the SDK. The SDK provides everything you need to build your Nerdlets, create visualizations, and fetch New Relic or third-party data. Components of the SDK SDK components are located in the Node module package named nr1, which you get when you install the NR1 CLI. The nr1 components can be divided into several categories: UI components Chart components Query and storage components Platform APIs UI components The UI components category of the SDK contains React UI components, including: Text components: These components provide basic font and heading elements. These include HeadingText and BlockText. Layout components: These components give you control over the layout, and help you build complex layout designs without having to deal with the CSS. Layout components include: Grid and GridItem: for organizing more complex, larger scale page content in rows and columns Stack and StackItem: for organizing simpler, smaller scale page content (in column or row) Tabs and TabsItem: group various related pieces of content into separate hideable sections List and ListItem: for providing a basic skeleton of virtualized lists Card, CardHeader and CardBody : used to group similar concepts and tasks together Form components: These components provide the basic building blocks to interact with the UI. These include Button, TextField, Dropdown and DropdownItem, Checkbox, RadioGroup, Radio, and Checkbox. Feedback components: These components are used to provide feedback to users about actions they have taken. These include: Spinnerand Toast. Overlaid components: These components are used to display contextual information and options in the form of an additional child view that appears above other content on screen when an action or event is triggered. They can either require user interaction (like modals), or be augmenting (like a tooltip). These include: Modal and Tooltip. Components suffixed with Item can only operate as direct children of that name without the suffix. For example: GridItem should only be found as a child of Grid. Chart components The Charts category of the SDK contains components representing different types of charts. The ChartGroup component helps a group of related charts share data and be aligned. Some chart components can perform NRQL queries on their own; some accept a customized set of data. Query and storage components The Query components category contains components for fetching and storing New Relic data. The main way to fetch data is with NerdGraph, our GraphQL endpoint. This can be queried using NerdGraphQuery. To simplify use of NerdGraph queries, we provide some components with pre-defined queries. For more on using NerdGraph, see Queries and mutations. We also provide storage for storing small data sets, such as configuration settings data, or user-specific data. For more on this, see NerdStorage. Platform APIs The Platform API components of the SDK enable your application to interact with different parts of the New Relic One platform, by reading and writing state from and to the URL, setting the configuration, etc. They can be divided into these categories: PlatformStateContext: provides read access to the platform URL state variables. Example: timeRange in the time picker. navigation: an object that allows programmatic manipulation of the navigation in New Relic One. Example: opening a new Nerdlet. NerdletStateContext: provides read access to the Nerdlet URL state variables. Example: an entityGuid in the entity explorer. nerdlet: an object that provides write access to the Nerdlet URL state.",
+ "info": "How to create a baseline alert conditions and set thresholds that adjust to data patterns and fluctuations. ",
+ "body": "You can use baseline conditions to define violation thresholds that adjust to the behavior of your data. Baseline alerting is useful for creating conditions that: Only notify you when data is behaving abnormally. Dynamically adjust to changing data and trend s, including daily or weekly trends. In addition, baseline alerting works well with new applications when you do not yet have known behaviors. How it works When you choose a data source (for example, an APM metric) for a baseline condition, we'll use the past values of that data to dynamically predict the data's near-future behavior. The line of that predicted future behavior for that value is called a baseline. It appears as a dotted black line on the preview chart in the baseline condition UI. You'll use the baseline alert condition UI to: Adjust how sensitive the condition is to fluctuations in the data source. Set the behavior that will trigger a violation (for example: \"deviating for more than five minutes\"). Set whether you want the condition to check for upper violations, lower violations, or both. When your data escapes the predicted \"normal\" behavior and meets the criteria you've chosen, you'll receive a notification. Set baseline thresholds one.newrelic.com > AI & Alerts > Policies > (create or select policy) > Create alert condition: Baseline alert conditions give you the ability to set intelligent, self-adjusting thresholds that only generate violations when abnormal behavior is detected. To create a baseline condition: When you start to create a condition, choose one of the following data sources: APM: Application metric baseline Browser: Metric baseline NRQL (and then choose a baseline type threshold) Here are some tips for setting baseline thresholds: Set the baseline direction to monitor violations that happen either above or below the baseline. Set the preview chart to either 2 days or 7 days of displayed data. (Not applicable for NRQL alert conditions.) Use the slider bar to adjust the Critical threshold sensitivity, represented in the preview chart by the light gray area around the baseline. The tighter the band around the baseline, the more sensitive it is and the more violations it will generate. Optional: You can create a Warning threshold (the darker gray area around the baseline). For NRQL alerts, see the allowed types of NRQL queries. If the alert condition applies to multiple apps, you can select a choice from the dropdown above the chart to use different metrics. (Not applicable for NRQL alert conditions.) Baseline rules and settings Here are some details about how the UI works: Rules governing creation of baseline The algorithm for baseline conditions is mathematically complex. Here are some of the major rules governing its predictive abilities: Data trait Baseline rules Age of data On initial creation, the baseline is calculated using between 1 to 4 weeks of data, depending on data availability and baseline type. After its creation, the algorithm will take into account ongoing data fluctuations over a long time period, although greater weight is given to more recent data. For data that has only existed for a short time, the baseline will likely fluctuate a good deal and not be very accurate. This is because there is not yet enough data to determine its usual values and behavior. The more history the data has, the more accurate the baseline and thresholds will become. Consistency of data For metric values that remain in a consistent range or that trend slowly and steadily, their more predictable behavior means that their thresholds will become tighter around the baseline. Data that is more varied and unpredictable will have looser (wider) thresholds. Regular fluctuations For shorter-than-one-week cyclical fluctuations (such as weekly Wednesday 1pm deployments or nightly reports), the baseline algorithm looks for these cyclical fluctuations and attempts to adjust to them. Baseline direction: select upper or lower ranges You can choose whether you want the condition to violate for behavior that goes above the baseline (\"upper\") or that goes below the baseline (\"lower\"), or that goes either above or below. You choose these with the Baseline direction selector. Example use cases for this: You might use the Upper setting for a data source like error rate, because you generally are only concerned if it goes up, and aren't concerned if it goes down. You might use the Lower setting for a data source like throughput, because sudden upward fluctuations are quite common, but a large sudden downswing would be a sign of a problem. Here are examples of how large fluctuations in your data would be treated under the different baseline direction settings. The red areas represent violations. Preview chart: select 2 or 7 days When setting thresholds, the preview chart has an option for displaying Since 2 days ago or Since 7 days ago. These selections are not the time period used to compute the baseline; they are only the time range used for a preview display. For more about the time range used to calculate the baseline, see the algorithm rules. For more help If you need more help, check out these support and learning resources: Browse the Explorers Hub to get help from the community and join in discussions. Find answers on our sites and learn how to use our support portal. Run New Relic Diagnostics, our troubleshooting tool for Linux, Windows, and macOS. Review New Relic's data security and licenses documentation.",
"_index": "520d1d5d14cc8a32e600034b",
"_type": "520d1d5d14cc8a32e600034c",
- "_score": 274.56677,
+ "_score": 78.47388,
"_version": null,
"_explanation": null,
"sort": null,
"highlight": {
- "title": "Intro to New Relic One API components",
- "sections": "Intro to New Relic One API components",
- "info": "Intro to New Relic One API components",
- "tags": "New Relic One apps",
- "body": ", and fetch New Relic or third-party data. Components of the SDK SDK components are located in the Node module package named nr1, which you get when you install the NR1CLI. The nr1 components can be divided into several categories: UI components Chart components Query and storage components Platform"
+ "title": "Create baseline alertconditions",
+ "sections": "Alertconditions",
+ "info": "How to create a baseline alertconditions and set thresholds that adjust to data patterns and fluctuations. ",
+ "category_0": "Alerts and Applied intelligence",
+ "category_1": "New Relic Alerts",
+ "category_2": "Alertconditions",
+ "translation_ja_url": "https://docs.newrelic.co.jp/docs/alerts-applied-intelligence/new-relic-alerts/alert-conditions/create-baseline-alert-conditions",
+ "body": " that happen either above or below the baseline. Set the preview chart to either 2 days or 7 days of displayed data. (Not applicable for NRQLalertconditions.) Use the slider bar to adjust the Critical threshold sensitivity, represented in the preview chart by the light gray area around the baseline",
+ "breadcrumb": "Contents / Alerts and Applied intelligence / New Relic Alerts / Alertconditions"
},
- "id": "5efa989e28ccbc4071307de5"
+ "id": "5f2d847b28ccbc876888e004"
},
{
+ "category_2": "Understand and use data",
+ "nodeid": 37981,
"sections": [
- "Nerdpack file structure",
- "Generate Nerdpack components",
- "Nerdlet file structure",
- "index.js",
- "nr1.json",
- "styles.scss",
- "icon.png",
- "Launcher file structure"
- ],
- "title": "Nerdpack file structure",
- "type": "developer",
- "tags": [
- "New Relic One CLI",
- "nerdpack",
- "file structure",
- "nerdlets",
- "launchers"
+ "Elastic Container Service integration",
+ "Get started",
+ "Install",
+ "Understand and use data",
+ "Troubleshooting",
+ "Recommended ECS alert conditions",
+ "Recommended alert conditions",
+ "For more help"
],
- "external_id": "c97bcbb0a2b3d32ac93b5b379a1933e7b4e00161",
- "image": "",
- "url": "https://developer.newrelic.com/explore-docs/nerdpack-file-structure/",
- "published_at": "2020-08-28T01:50:39Z",
- "updated_at": "2020-08-14T01:49:25Z",
- "document_type": "page",
- "popularity": 1,
- "info": "An overview of the Nerdpack File Structure",
- "body": "Nerdpack file structure A New Relic One application is represented by a Nerdpack folder, which can include one or more Nerdlet files, and (optionally) one or more launcher files. Here we explain: The file structure for a Nerdpack, a Nerdlet, and a launcher How to link a launcher file to a Nerdlet How to link your application with a monitored entity For basic component definitions, see our component reference. Generate Nerdpack components There are two ways to generate a Nerdpack template: Generate a Nerdpack: Use the New Relic One CLI command nr1 create and select Nerdpack to create a Nerdpack template that includes a Nerdlet and a launcher. Generate Nerdlet or launcher individually: Use the New Relic One CLI command nr1 create and choose either Nerdlet or launcher. This can be useful when adding Nerdlets to an existing Nerdpack. For documentation on generating and connecting Nerdpack components, see our app building guides and the New Relic One CLI command reference. Nerdpack file structure When you generate a Nerdpack template using the nr1 create command, it has the following file structure: my-nerdlet ├── README.md ├── launchers │ └── my-nerdlet-launcher │ ├── icon.png │ └── nr1.json ├── nerdlets │ └── my-nerdlet-nerdlet │ ├── index.js │ ├── nr1.json │ └── styles.scss ├── node_modules │ ├── js-tokens │ ├── loose-envify │ ├── object-assign │ ├── prop-types │ ├── react │ ├── react-dom │ ├── react-is │ └── scheduler ├── nr1.json ├── package-lock.json └── package.json Copy Nerdlet file structure A Nerdpack can contain one or more Nerdlets. A Nerdlet folder starts out with three default files, index.js, nr1.json, and styles.scss. Here is what the default files look like after being generated using the nr1 create command: index.js The JavaScript code of the Nerdlet. import React from 'react'; export default class MyAwesomeNerdpack extends React.Component { render() { return
Hello, my-awesome-nerdpack Nerdlet!
; } } Copy nr1.json The Nerdlet configuration file. { \"schemaType\": \"NERDLET\", \"id\": \"my-awesome-nerdpack-nerdlet\", \"description\": \"Describe me\", \"displayName\": \"MyAwesomeNerdpack\" } Copy Besides using the launcher as the access point for your application, you can also associate the application with a monitored entity to get it to appear in the entity explorer. To do this, add two additional fields to the config file of the first-launched Nerdlet: entities and actionCategory. In the following example, the Nerdlet has been associated with all Browser-monitored applications and will appear under the Monitor UI category : { \"schemaType\": \"NERDLET\", \"id\": \"my-nerdlet\", \"description\": \"Describe me\", \"displayName\": \"Custom Data\", \"entities\": [{ \"domain\": \"BROWSER\", \"type\": \"APPLICATION\" }], \"actionCategory\": \"monitor\" } Copy To see this application in the UI, you would go to the entity explorer, select Browser applications, and select a monitored application. styles.scss An empty SCSS file for styling your application. icon.png The launcher icon that appears on the Apps page in New Relic One when an application is deployed. Launcher file structure Launchers have their own file structure. Note that: A launcher is not required; as an alternative to using a launcher, you can associate your application with a monitored entity. An application can have more than one launcher, which might be desired for an application with multiple Nerdlets. After generating a launcher using the nr1 create command, its folder contains two files: nr1.json The configuration file. { \"schemaType\": \"LAUNCHER\", \"id\": \"my-awesome-nerdpack-launcher\", \"description\": \"Describe me\", \"displayName\": \"MyAwesomeNerdpack\", \"rootNerdletId\": \"my-awesome-nerdpack-nerdlet\" } Copy To connect a launcher to a Nerdlet, the rootNerdletId must match the id in the launched Nerdlet's nr1.json config file. For Nerdpacks with multiple Nerdlets, this needs to be done only for the first-launched Nerdlet. icon.png The icon displayed on the launcher for the app on the Apps page.",
- "_index": "520d1d5d14cc8a32e600034b",
- "_type": "520d1d5d14cc8a32e600034c",
- "_score": 248.94653,
- "_version": null,
- "_explanation": null,
- "sort": null,
- "highlight": {
- "title": "Nerdpackfilestructure",
- "sections": "Nerdpackfilestructure",
- "info": "An overview of the NerdpackFileStructure",
- "tags": "filestructure",
- "body": " components, see our app building guides and the New Relic OneCLI command reference. Nerdpackfilestructure When you generate a Nerdpack template using the nr1 create command, it has the following filestructure: my-nerdlet ├── README.md ├── launchers │ └── my-nerdlet-launcher │ ├── icon.png"
- },
- "id": "5efa989e196a671300766404"
- },
- {
+ "title": "Recommended ECS alert conditions",
+ "category_0": "Integrations",
+ "type": "docs",
+ "category_1": "Elastic Container Service integration",
+ "external_id": "304f01e7a5c68e9ef4dc76782eb9ff6847854065",
"image": "",
- "url": "https://developer.newrelic.com/explore-docs/nr1-common/",
- "sections": [
- "New Relic One CLI common commands",
- "Command details",
- "nr1 help",
- "See commands and get details",
- "Usage",
- "Arguments",
- "Examples",
- "nr1 update",
- "Update your CLI",
- "nr1 create",
- "Create a new component",
- "Options",
- "nr1 profiles",
- "Manage your profiles keychain",
- "Commands",
- "nr1 autocomplete",
- "See autocomplete installation instructions",
- "nr1 nrql",
- "Query using NRQL"
- ],
- "published_at": "2020-08-28T01:50:39Z",
- "title": "New Relic One CLI common commands",
- "updated_at": "2020-08-14T01:48:10Z",
- "type": "developer",
- "external_id": "503e515e1095418f8d19329517344ab209d143a4",
+ "url": "https://docs.newrelic.com/docs/integrations/elastic-container-service-integration/understand-use-data/ecs-integration-recommended-alert-conditions",
+ "published_at": "2020-08-25T18:46:46Z",
+ "updated_at": "2020-08-06T00:29:40Z",
+ "breadcrumb": "Contents / Integrations / Elastic Container Service integration / Understand and use data",
"document_type": "page",
"popularity": 1,
- "info": "An overview of common commands you can use with the New Relic One CLI.",
- "body": "New Relic One CLI common commands Here's a list of common commands to get you started with the New Relic One CLI. You can click any command to see its usage options and additional details about the command. Command Description nr1 help Shows all nr1 commands or details about each command. nr1 update Updates to the latest version of the CLI. nr1 create Creates a new component from a template (Nerdpack, Nerdlet, launcher, or catalog). nr1 profiles Manages the profiles you use to run CLI commands. nr1 autocomplete Displays autocomplete installation instructions. nr1 nrql Fetches data using NRQL (New Relic query language). See our other New Relic One CLI docs for commands specific to Nerdpack set-up, Nerdpack subscriptions, CLI configuration, plugins, or catalogs. Command details nr1 help See commands and get details Shows all nr1 commands by default. To get details about a specific command, run nr1 help COMMAND_NAME. Usage $ nr1 help Arguments COMMAND_NAME The name of a particular command. Examples $ nr1 help $ nr1 help nerdpack $ nr1 help nerdpack:deploy nr1 update Update your CLI Updates to latest version of the CLI. You can specify which channel to update if you'd like. Usage $ nr1 update Arguments CHANNEL The name of a particular channel. Examples $ nr1 update $ nr1 update somechannel nr1 create Create a new component Creates a new component from our template (either a Nerdpack, Nerdlet, launcher, or catalog). The CLI will walk you through this process. To learn more about Nerdpacks and their file structure, see Nerdpack file structure. For more on how to set up your Nerdpacks, see our Nerdpack CLI commands. Usage $ nr1 create Options -f, --force If present, overrides existing files without asking. -n, --name=NAME Names the component. -t, --type=TYPE Specifies the component type. --path=PATH The route to the component. --profile=PROFILE The authentication profile you want to use. --verbose Adds extra information to the output. nr1 profiles Manage your profiles keychain Displays a list of commands you can use to manage your profiles. Run nr1 help profiles:COMMAND for more on their specific usages. You can have more than one profile, which is helpful for executing commands on multiple New Relic accounts. To learn more about setting up profiles, see our Github workshop. Usage $ nr1 profiles:COMMAND Commands profiles:add Adds a new profile to your profiles keychain. profiles:default Chooses which profile should be default. profiles:list Lists the profiles on your keychain. profiles:remove Removes a profile from your keychain. nr1 autocomplete See autocomplete installation instructions Displays the autocomplete installation instructions. By default, the command displays the autocomplete instructions for zsh. If you want instructions for bash, run nr1 autocomplete bash. Usage $ nr1 autocomplete Arguments SHELL The shell type you want instructions for. Options -r, --refresh-cache Refreshes cache (ignores displaying instructions). Examples $ nr1 autocomplete $ nr1 autocomplete zsh $ nr1 autocomplete bash $ nr1 autocomplete --refresh-cache nr1 nrql Query using NRQL Fetches data from databases using a NRQL query. To learn more about NRQL and how to use it, see our NRQL docs. Usage $ nr1 nrql OPTION ... Options -a, --account=ACCOUNT The user account ID. required -q, --query=QUERY The NRQL query to run. required -u, --ugly Displays the content without tabs or spaces. --profile=PROFILE The authentication profile you want to use. --verbose Adds extra information to the output.",
+ "info": "Tips for useful alert conditions to set for New Relic's Amazon ECS integration. ",
+ "body": "New Relic's ECS integration reports and displays performance data from your Amazon ECS environment. This document provides some recommended alert conditions for monitoring ECS performance. Recommended alert conditions Here are some recommended ECS alert conditions. To add these alerts, go to the Alerts UI and add the following NRQL alert conditions to an existing or new alert policy: High CPU usage NRQL: FROM ContainerSample SELECT cpuUsed / cpuLimitCores Critical: > 90% for 5 minutes High memory usage NRQL: FROM ContainerSample SELECT memoryUsageBytes / memorySizeLimitBytes Critical: > 80% for 5 minutes Restart count NRQL: FROM ContainerSample SELECT max(restartCount) - min(restartCount) Critical: > 5 for 5 minutes For more help If you need more help, check out these support and learning resources: Browse the Explorers Hub to get help from the community and join in discussions. Find answers on our sites and learn how to use our support portal. Run New Relic Diagnostics, our troubleshooting tool for Linux, Windows, and macOS. Review New Relic's data security and licenses documentation.",
"_index": "520d1d5d14cc8a32e600034b",
"_type": "520d1d5d14cc8a32e600034c",
- "_score": 212.20648,
+ "_score": 73.25382,
"_version": null,
"_explanation": null,
"sort": null,
"highlight": {
- "title": "New Relic OneCLI common commands",
- "sections": "New Relic OneCLI common commands",
- "info": "An overview of common commands you can use with the New Relic OneCLI.",
- "body": " Nerdpacks and their filestructure, see Nerdpackfilestructure. For more on how to set up your Nerdpacks, see our NerdpackCLI commands. Usage $ nr1 create Options -f, --force If present, overrides existing files without asking. -n, --name=NAME Names the component. -t, --type=TYPE Specifies"
+ "title": "Recommended ECS alertconditions",
+ "sections": "Recommended ECS alertconditions",
+ "info": "Tips for useful alertconditions to set for New Relic's Amazon ECS integration. ",
+ "body": " to the Alerts UI and add the following NRQLalertconditions to an existing or new alert policy: High CPU usage NRQL: FROM ContainerSample SELECT cpuUsed / cpuLimitCores Critical: > 90% for 5 minutes High memory usage NRQL: FROM ContainerSample SELECT memoryUsageBytes / memorySizeLimitBytes Critical: > 80"
},
- "id": "5f28bd6ae7b9d267996ade94"
+ "id": "5ee05e9e28ccbcef4f4c8dda"
},
{
+ "category_2": "Alert conditions",
+ "nodeid": 9231,
"sections": [
- "Permissions for managing applications",
- "New Relic One pricing plan",
- "Original product-based pricing",
- "About versions"
- ],
- "title": "Permissions for managing applications",
- "type": "developer",
- "tags": [
- "nerdpack manager",
- "permissions",
- "managing apps"
+ "New Relic Alerts",
+ "Get started",
+ "Alert policies",
+ "Alert conditions",
+ "Alert violations",
+ "Alert Incidents",
+ "Alert notifications",
+ "Troubleshooting",
+ "Rules, limits, and glossary",
+ "Alerts and Nerdgraph",
+ "REST API alerts",
+ "Create NRQL alert conditions",
+ "Create NRQL alert condition",
+ "Alert threshold types",
+ "NRQL alert syntax",
+ "Sum of query results (limited or intermittent data)",
+ "Offset the query time window",
+ "NRQL alert threshold examples",
+ "Create a description",
+ "For more help"
],
- "external_id": "c7f4c7fbd9d093d303c7f8268f8560ff9f435230",
+ "title": "Create NRQL alert conditions",
+ "category_0": "Alerts and Applied intelligence",
+ "type": "docs",
+ "category_1": "New Relic Alerts",
+ "translation_ja_url": "https://docs.newrelic.co.jp/docs/alerts-applied-intelligence/new-relic-alerts/alert-conditions/create-nrql-alert-conditions",
+ "external_id": "956a7a0b84d2afac5e6236df3143085ebc4f7459",
"image": "",
- "url": "https://developer.newrelic.com/build-apps/permission-manage-apps/",
- "published_at": "2020-08-28T01:45:16Z",
- "updated_at": "2020-08-26T01:47:20Z",
+ "url": "https://docs.newrelic.com/docs/alerts-applied-intelligence/new-relic-alerts/alert-conditions/create-nrql-alert-conditions",
+ "published_at": "2020-08-26T10:06:47Z",
+ "updated_at": "2020-08-15T23:05:02Z",
+ "breadcrumb": "Contents / Alerts and Applied intelligence / New Relic Alerts / Alert conditions",
"document_type": "page",
"popularity": 1,
- "info": "Learn about permissions for subscribing to apps",
- "body": "Permissions for managing applications When you create an app, you'll likely want to share it. From New Relic One's Apps page, you can subscribe to apps you create, publish, and deploy, and to other publicly available apps. You must have the Nerdpack manager role to subcribe accounts to apps. Read on to learn about permissions and versions. Permissions for managing applications The Nerdpack manager role is a New Relic add-on role. When you create a Nerdpack, you have the Nerdpack manager role for handling that Nerdpack. New Relic account administrators have the Nerdpack manager role automatically, and can subscribe their accounts to available Nerdpacks. User permissions vary depending on which pricing plan you are on. New Relic One pricing plan For accounts with New Relic One pricing, there are permissions differences for basic users and full users: Full users have the Nerdpack manager role and have full capabilities for creating and managing New Relic One applications, as well as accessing all types of applications in the New Relic One catalog. A basic user can develop and view their own local New Relic One apps, but they cannot: Subscribe other users to apps they’ve created. Access or manage apps in the New Relic One catalog. Access apps in the entity explorer sidebar. Original product-based pricing For accounts on our original product-based pricing, here are access details: Subscribe to publicly available applications To subscribe to publicly available applications, you must have the Nerdpack manager role. Nerdpack manager permissions are automatically assigned to New Relic account owners and admins and can be assigned to individual users. If you aren’t an owner or admin, you can request Nerdpack manager permission, or ask your New Relic admin or owner to subscribe the apps to your account for you. You can add any of the publicly available applications to master accounts or separate sub-accounts on which you have the Nerdpack manager role, or to separate sub-accounts under a master account you own or administer. If you add the application to a master account, the access flows to all of its sub-accounts as well. Subscribe to applications that you create You also must have the Nerdpack manager role to subscribe the applications you create to accounts. Applications that you publish and deploy can only be subscribed to the master account that was used to publish them, or to its sub-accounts. This means you might want a New Relic admin to deploy your applications for you if they need to be available across the organization. About versions New Relic One requires that only one version (following semantic versioning) of a Nerdpack can be published. Thus, the nr1 nerdpack:publish command requires the following: The Nerdpack manager role A unique version as specified in the version attribute found in the app's package.json.",
- "_index": "520d1d5d14cc8a32e600034b",
- "_type": "520d1d5d14cc8a32e600034c",
- "_score": 179.25232,
- "_version": null,
- "_explanation": null,
- "sort": null,
- "highlight": {
- "title": "Permissions for managing applications",
- "sections": "Permissions for managing applications",
- "info": "Learn about permissions for subscribing to apps",
- "tags": "nerdpack manager",
- "body": "Permissions for managing applications When you create an app, you'll likely want to share it. From New Relic One's Apps page, you can subscribe to apps you create, publish, and deploy, and to other publicly available apps. You must have the Nerdpack manager role to subcribe accounts to apps. Read"
- },
- "id": "5f45bf2864441ffb4dfdcdbb"
- },
- {
- "sections": [
- "Map page views by region in a custom app",
- "Before you begin",
- "New Relic terminology",
- "Build a custom app with a table chart",
- "Query your browser data",
- "Create and serve a new Nerdpack",
- "Review your app files and view your app locally",
- "Hard code your account ID",
- "Import the TableChart component",
- "Add a table with a single row",
- "Customize the look of your table (optional)",
- "Get your data into that table",
- "Make your app interactive with a text field",
- "Import the TextField component",
- "Add a row for your text field",
- "Build the text field object",
- "Get your data on a map",
- "Install Leaflet",
- "Add a webpack config file for Leaflet",
- "Import modules from Leaflet",
- "Import additional modules from New Relic One",
- "Get data for the map",
- "Customize the map marker colors",
- "Set your map's default center point",
- "Add a row for your map",
- "Replace \"Hello\" with the Leaflet code"
- ],
- "title": "Map page views by region in a custom app",
- "type": "developer",
- "tags": [
- "custom app",
- "map",
- "page views",
- "region",
- "nerdpack"
+ "info": "How to define thresholds that trigger alert notifications based on your NRQL queries.",
+ "body": "You can create alert conditions using NRQL queries. Create NRQL alert condition To create a NRQL condition: When you start to create a condition, where it prompts you to Select a product, click NRQL. Tips on creating a NRQL condition: NRQL conditions Tips Condition types NRQL condition types include static, baseline, and outlier. Create a description For some condition types, you can create a Description. Query results Queries must return a number. The condition works by evaluating that returned number against the thresholds you set. Time period As with all alert conditions, NRQL conditions evaluate one single minute at a time. The implicit SINCE ... UNTIL clause specifying which minute to evaluate is controlled by your Evaluation offset setting. Since very recent data may be incomplete, you may want to query data from 3 minutes ago or longer, especially for: Applications that run on multiple hosts. SyntheticCheck data: Timeouts can take 3 minutes, so 5 minutes or more is recommended. Also, if a query will generate intermittent data, consider using the sum of query results option. Condition settings Use the Condition settings to: Configure whether and how open violations are force-closed. Adjust the evaluation offset. Create a concise and descriptive condition name. (NerdGraph API Only) Provide a text description for the condition that will be included in violations and notifications. Troubleshooting procedures Optional: To include your organization's procedures for handling the incident, add the runbook URL to the condition. Limits on conditions See the maximum values. Examples For more information, see: Expected NRQL syntax Examples of NRQL condition queries Alert threshold types When you create a NRQL alert, you can choose from different types of thresholds: NRQL alert threshold types Description Static This is the simplest type of NRQL threshold. It allows you to create a condition based on a NRQL query that returns a numeric value. Optional: Include a FACET clause. Baseline Uses a self-adjusting condition based on the past behavior of the monitored values. Uses the same NRQL query form as the static type, except you cannot use a FACET clause. Outlier Looks for group behavior and values that are outliers from those groups. Uses the same NRQL query form as the static type, but requires a FACET clause. NRQL alert syntax Here is the basic syntax for creating all NRQL alert conditions. Depending on the threshold type, also include a FACET clause as applicable. SELECT function(attribute) FROM Event WHERE attribute [comparison] [AND|OR ...] Clause Notes SELECT function(attribute) Required Supported functions that return numbers include: apdex average count latest max min percentage percentile sum uniqueCount If you use the percentile aggregator in a faceted alert condition with many facets, this may cause the following error to appear: An error occurred while fetching chart data. If you see this error, use average instead. FROM data type Required Only one data type can be targeted. Supported data types: Event Metric (RAW data points will be returned) WHERE attribute [comparison] [AND|OR ...] Optional Use the WHERE clause to specify a series of one or more conditions. All the operators are supported. FACET attribute Static: Optional Baseline: Not allowed Outlier: Required Including a FACET clause in your NRQL syntax depends on the threshold type: static, baseline, or outlier. Use the FACET clause to separate your results by attribute and alert on each attribute independently. Faceted queries can return a maximum of 5000 values for static conditions and a maximum of 500 values for outlier conditions. If the query returns more than this number of values, the alert condition cannot be created. If you create the condition and the query returns more than this number later, the alert will fail. Sum of query results (limited or intermittent data) Available only for static (basic) threshold types. If a query returns intermittent or limited data, it may be difficult to set a meaningful threshold. Missing or limited data will sometimes generate false positives or false negatives. To avoid this problem when using the static threshold type, you can set the selector to sum of query results. This lets you set the alert on an aggregated sum instead of a value from a single harvest cycle. Up to two hours of the one-minute data checks can be aggregated. The duration you select determines the width of the rolling sum, and the preview chart will update accordingly. Offset the query time window Every minute, we evaluate the NRQL query in one-minute time windows. The start time depends on the value you select in the NRQL condition's Advanced settings > Evaluation offset. Example: Using the default time window to evaluate violations With the Evaluation offset at the default setting of three minutes, the NRQL time window applied to your query will be: SINCE 3 minutes ago UNTIL 2 minutes ago If the event type is sourced from an APM language agent and aggregated from many app instances (for example, Transactions, TransactionErrors, etc.), we recommend evaluating data from three minutes ago or longer. An offset of less than 3 minutes will trigger violations sooner, but you might see more false positives and negatives due to data latency. For cloud data, such as AWS integrations, you may need an offset longer than 3 minutes. Check our AWS polling intervals documentation to determine your best setting. NRQL alert threshold examples Here are some common use cases for NRQL alert conditions. These queries will work for static and baseline threshold types. The outlier threshold type will require additional FACET clauses. Alert on specific segments of your data Create constrained alerts that target a specific segment of your data, such as a few key customers or a range of data. Use the WHERE clause to define those conditions. SELECT average(duration) FROM Transaction WHERE account_id in (91290, 102021, 20230) SELECT percentile(duration, 95) FROM Transaction WHERE name LIKE 'Controller/checkout/%' Alert on Nth percentile of your data Create alerts when an Nth percentile of your data hits a specified threshold; for example, maintaining SLA service levels. Since we evaluate the NRQL query in one-minute time windows, percentiles will be calculated for each minute separately. SELECT percentile(duration, 95) FROM Transaction SELECT percentile(databaseDuration, 75) FROM Transaction Alert on max, min, avg of your data Create alerts when your data hits a certain maximum, minimum, or average; for example, ensuring that a duration or response time does not pass a certain threshold. SELECT max(duration) FROM Transaction SELECT average(duration) FROM Transaction Alert on a percentage of your data Create alerts when a proportion of your data goes above or below a certain threshold. SELECT percentage(count(*), WHERE duration > 2) FROM Transaction SELECT percentage(count(*), WHERE httpResponseCode = '500') FROM Transaction Alert on Apdex with any T-value Create alerts on Apdex, applying your own T-value for certain transactions. For example, get an alert notification when your Apdex for a T-value of 500ms on transactions for production apps goes below 0.8. SELECT apdex(duration, t:0.5) FROM Transaction WHERE appName like '%prod%' Create a description You can define a description that passes useful information downstream for better violation responses or for use by downstream systems. For details, see Description. For more help If you need more help, check out these support and learning resources: Browse the Explorers Hub to get help from the community and join in discussions. Find answers on our sites and learn how to use our support portal. Run New Relic Diagnostics, our troubleshooting tool for Linux, Windows, and macOS. Review New Relic's data security and licenses documentation.",
+ "_index": "520d1d5d14cc8a32e600034b",
+ "_type": "520d1d5d14cc8a32e600034c",
+ "_score": 67.60222,
+ "_version": null,
+ "_explanation": null,
+ "sort": null,
+ "highlight": {
+ "title": "Create NRQLalertconditions",
+ "sections": "Create NRQLalertconditions",
+ "info": "How to define thresholds that trigger alert notifications based on your NRQL queries.",
+ "category_0": "Alerts and Applied intelligence",
+ "category_1": "New Relic Alerts",
+ "category_2": "Alertconditions",
+ "translation_ja_url": "https://docs.newrelic.co.jp/docs/alerts-applied-intelligence/new-relic-alerts/alert-conditions/create-nrql-alert-conditions",
+ "body": "You can create alertconditions using NRQL queries. Create NRQLalert condition To create a NRQL condition: When you start to create a condition, where it prompts you to Select a product, click NRQL. Tips on creating a NRQL condition: NRQLconditions Tips Condition types NRQL condition types",
+ "breadcrumb": "Contents / Alerts and Applied intelligence / New Relic Alerts / Alertconditions"
+ },
+ "id": "5f2d992528ccbc489d88dfc1"
+ },
+ {
+ "category_2": "Alert conditions",
+ "nodeid": 7261,
+ "sections": [
+ "New Relic Alerts",
+ "Get started",
+ "Alert policies",
+ "Alert conditions",
+ "Alert violations",
+ "Alert Incidents",
+ "Alert notifications",
+ "Troubleshooting",
+ "Rules, limits, and glossary",
+ "Alerts and Nerdgraph",
+ "REST API alerts",
+ "Set thresholds for an alert condition",
+ "What is a threshold?",
+ "View and set thresholds",
+ "For more help"
],
- "external_id": "6ff5d696556512bb8d8b33fb31732f22bab455cb",
- "image": "https://developer.newrelic.com/static/d87a72e8ee14c52fdfcb91895567d268/0086b/pageview.png",
- "url": "https://developer.newrelic.com/build-apps/map-pageviews-by-region/",
- "published_at": "2020-08-28T01:51:51Z",
- "updated_at": "2020-08-14T01:45:09Z",
+ "title": "Set thresholds for an alert condition",
+ "category_0": "Alerts and Applied intelligence",
+ "type": "docs",
+ "category_1": "New Relic Alerts",
+ "translation_ja_url": "https://docs.newrelic.co.jp/docs/alerts-applied-intelligence/new-relic-alerts/alert-conditions/set-thresholds-alert-condition",
+ "external_id": "3b8b9a21021955bde8536ec49e7348f9bc1b6307",
+ "image": "",
+ "url": "https://docs.newrelic.com/docs/alerts-applied-intelligence/new-relic-alerts/alert-conditions/set-thresholds-alert-condition",
+ "published_at": "2020-08-26T07:05:22Z",
+ "updated_at": "2020-08-09T18:39:13Z",
+ "breadcrumb": "Contents / Alerts and Applied intelligence / New Relic Alerts / Alert conditions",
"document_type": "page",
"popularity": 1,
- "info": "Build a New Relic app showing page view data on a world map.",
- "body": "Map page views by region in a custom app 30 min New Relic has powerful and flexible tools for building custom apps and populating them with data. This guide shows you how to build a custom app and populate it with page view data using New Relic's Query Language (NRQL - pronounced 'nurkle'). Then you make your data interactive. And last, if you have a little more time and want to install a third-party React library, you can display the page view data you collect on a map of the world. In this guide, you build an app to display page view data in two ways: In a table On a map Please review the Before you begin section to make sure you have everything you need and don't get stuck halfway through. Before you begin In order to get the most out of this guide, you must have: A New Relic developer account, API key, and the command-line tool. If you don't have these yet, see the steps in Setting up your development environment New Relic Browser page view data to populate the app. Without this data, you won't be able to complete this guide. To add your data to a world map in the second half of the guide: npm, which you'll use during this section of the guide to install Leaflet, a third-party JavaScript React library used to build interactive maps. If you're new to React and npm, you can go here to install Node.js and npm. New Relic terminology The following are some terms used in this guide: New Relic application: The finished product where data is rendered in New Relic One. This might look like a series of interactive charts or a map of the world. Nerdpack: New Relic's standard collection of JavaScript, JSON, CSS, and other files that control the functionality and look of your application. For more information, see Nerdpack file structure. Launcher: The button on New Relic One that launches your application. Nerdlets: New Relic React components used to build your application. The three default files are index.js, nr1.json, and styles.scss, but you can customize and add your own. Build a custom app with a table chart Step 1 of 8 Query your browser data Use Query builder to write a NRQL query to see your page view data, as follows. On New Relic One, select Query your data (in the top right corner). That puts you in NRQL mode. You'll use NRQL to test your query before dropping the data into your table. Copy and paste this query into a clear query field, and then select Run. FROM PageView SELECT count(*), average(duration) WHERE appName = 'WebPortal' FACET countryCode, regionCode SINCE 1 week ago LIMIT 1000 Copy If you have PageView data, this query shows a week of average page views broken down by country and limited to a thousand items. The table will be full width and use the \"chart\" class defined in the CSS. If you don't have any results at this point, ensure your query doesn't have any errors. If your query is correct, you might not have the Browser agent installed. Step 2 of 8 Create and serve a new Nerdpack To get started, create a new Nerdpack, and serve it up to New Relic from your local development environment: Create a new Nerdpack for this app: nr1 create --type nerdpack --name pageviews-app Copy Serve the project up to New Relic: cd pageviews-app && nr1 nerdpack:serve Copy Step 3 of 8 Review your app files and view your app locally Navigate to your pageviews-app to see how it's structured. It contains a launcher folder, where you can customize the description and icon that will be displayed on the app's launcher in New Relic One. It also contains nerdlets, which each contain three default files: index.js, nr1.json, and styles.scss. You'll edit some of these files as part of this guide. For more information, see Nerdpack file structure. Now in your browser, open https://one.newrelic.com/?nerdpacks=local, and then click Apps to see the pageview-apps Nerdpack that you served up. When you select the launcher, you see a Hello message. Step 4 of 8 Hard code your account ID For the purposes of this exercise and for your convenience, hard code your account ID. In the pageview-app-nerdlet directory, in the index.js file, add this code between the import and export lines. (Read about finding your account ID here). const accountId = [Replace with your account ID]; Copy Step 5 of 8 Import the TableChart component To show your data in a table chart, import the TableChart component from New Relic One. To do so, in index.js, add this code under import React. import { TableChart } from `nr1`; Copy Step 6 of 8 Add a table with a single row To add a table with a single row, in the index.js file, replace this line: return
Hello, pageview-app-nerdlet Nerdlet!
; Copy with this export code: export default class PageViewApp extends React.Component { render() { return (
); } } Copy Step 7 of 8 Customize the look of your table (optional) You can use standard CSS to customize the look of your components. In the styles.scss file, add this CSS. Feel free to customize this CSS to your taste. .container { width: 100%; height: 99vh; display: flex; flex-direction: column; .row { margin: 10px; display: flex; flex-direction: row; } .chart { height: 250px; } } Copy Step 8 of 8 Get your data into that table Now that you've got a table, you can drop a TableChart populated with data from the NRQL query you wrote at the very beginning of this guide. Put this code into the row div. ; Copy Go to New Relic One and click your app to see your data in the table. (You might need to serve your app to New Relic again.) Congratulations! You made your app! Continue on to make it interactive and show your data on a map. Make your app interactive with a text field Once you confirm that data is getting to New Relic from your app, you can start customizing it and making it interactive. To do this, you add a text field to filter your data. Later, you use a third-party library called Leaflet to show that data on a world map. Step 1 of 3 Import the TextField component Like you did with the TableChart component, you need to import a TextField component from New Relic One. import { TextField } from 'nr1'; Copy Step 2 of 3 Add a row for your text field To add a text field filter above the table, put this code above the TableChart div. The text field will have a default value of \"US\".
; Copy Step 3 of 3 Build the text field object Above the render() function, add a constructor to build the text field object. constructor(props) { super(props); this.state = { countryCode: null } } Copy Then, add a constructor to your render() function. Above return, add: const { countryCode } = this.state; Copy Now add countryCode to your table chart query. ; Copy Reload your app to try out the text field. Get your data on a map To create the map, you use npm to install Leaflet. Step 1 of 9 Install Leaflet In your terminal, type: npm install --save leaflet react-leaflet Copy In your nerdlets styles.scss file, import the Leaflet CSS: @import `~leaflet/dist/leaflet.css`; Copy While you're in styles.scss, fix the width and height of your map: .containerMap { width: 100%; z-index: 0; height: 70vh; } Copy Step 2 of 9 Add a webpack config file for Leaflet Add a webpack configuration file .extended-webpackrc.js to the top-level folder in your nerdpack. This supports your use of map tiling information data from Leaflet. module.exports = { module: { rules: [ { test: /\\.(png|jpe?g|gif)$/, use: [ { loader: 'file-loader', options: {}, }, { loader: 'url-loader', options: { limit: 25000 }, }, ], }, ], }, }; Copy Step 3 of 9 Import modules from Leaflet In index.js, import modules from Leaflet. import { Map, CircleMarker, TileLayer } from 'react-leaflet'; Copy Step 4 of 9 Import additional modules from New Relic One You need several more modules from New Relic One to make the Leaflet map work well. Import them with this code: import { NerdGraphQuery, Spinner, Button, BlockText } from 'nr1'; Copy NerdGraphQuery lets you make multiple NRQL queries at once and is what will populate the map with data. Spinner adds a loading spinner. Button gives you button components. BlockText give you block text components. Step 5 of 9 Get data for the map Using latitude and longitude with country codes, you can put New Relic data on a map. mapData() { const { countryCode } = this.state; const query = `{ actor { account(id: 1606862) { mapData: nrql(query: \"SELECT count(*) as x, average(duration) as y, sum(asnLatitude)/count(*) as lat, sum(asnLongitude)/count(*) as lng FROM PageView FACET regionCode, countryCode WHERE appName = 'WebPortal' ${countryCode ? ` WHERE countryCode like '%${countryCode}%' ` : ''} LIMIT 1000 \") { results nrql } } } }`; return query; }; Copy Step 6 of 9 Customize the map marker colors Above the mapData function, add this code to customize the map marker colors. getMarkerColor(measure, apdexTarget = 1.7) { if (measure <= apdexTarget) { return '#11A600'; } else if (measure >= apdexTarget && measure <= apdexTarget * 4) { return '#FFD966'; } else { return '#BF0016'; } }; Copy Feel free to change the HTML color code values to your taste. In this example, #11A600 is green, #FFD966 is sort of yellow, and #BF0016 is red. Step 7 of 9 Set your map's default center point Set a default center point for your map using latitude and longitude. const defaultMapCenter = [10.5731, -7.5898]; Copy Step 8 of 9 Add a row for your map Between the text field row and the table chart row, insert a new row for the map content using NerdGraphQuery.
{({ loading, error, data }) => { if (loading) { return ; } if (error) { return 'Error'; } const { results } = data.actor.account.mapData; console.debug(results); return 'Hello'; }}
); } // Imperative way (using promises). async function getAccountList() { let data = {}; try { data = await AccountsQuery.query(); } catch (error) { console.log('Failed to retrieve list: ' + error.message); return; } return data.actor.accounts.map((account) => { return account.name; }); } Copy Similarly, a mutation can happen either way; either declaratively or imperatively. NrqlQuery NrqlQuery deserves additional explanation, because there are multiple formats in which you can return data from it. To provide maximum functionality, all three are exposed through a formatType property. You can find its different values under NrqlQuery.formatType: NERD_GRAPH: Returns the format in which it arrives from NerdGraph. RAW: The format exposed by default in Insights and dashboards when being plotted as JSON. This format is useful if you have a pre-existing script in this format that you're willing to migrate to or incorporate with. CHART: The format used by the charting engine that we also expose. You can find a more detailed explanation of how to manipulate this format in the guide to chart components, and some examples. If you are willing to push data, we currently do not expose NrqlMutation. To do that, see the Event API for how to add custom events.",
"_index": "520d1d5d14cc8a32e600034b",
"_type": "520d1d5d14cc8a32e600034c",
- "_score": 95.55056,
- "_version": null,
- "_explanation": null,
- "sort": null,
- "highlight": {
- "title": "Query and store data",
- "sections": "Query and store data",
- "info": "Reference guide for SDK query components using NerdGraph",
- "tags": "nerdgraph query components",
- "body": ", EntityByGuidQuery, EntityByNameQuery. Storage queries: New Relic One provides a simple storage mechanism that we call NerdStorage. This can be used by Nerdpack creators to store application configuration setting data, user-specific data, and other small pieces of data. Components in this category"
- },
- "id": "5efa989e28ccbc2f15307deb"
- }
- ],
- "/collect-data/get-started-nerdgraph-api-explorer": [
- {
- "category_2": "Examples",
- "nodeid": 39021,
- "sections": [
- "NerdGraph",
- "Get started",
- "Examples",
- "Use NerdGraph to manage license keys and personal API keys",
- "Feature description",
- "Create keys",
- "Update keys",
- "Delete keys",
- "Query keys",
- "For more help"
- ],
- "title": "Use NerdGraph to manage license keys and personal API keys",
- "category_0": "APIs",
- "type": "docs",
- "category_1": "NerdGraph",
- "external_id": "f4b228fbc3fdc408adc6d7e10a93edd0464b7762",
- "image": "",
- "url": "https://docs.newrelic.com/docs/apis/nerdgraph/examples/use-nerdgraph-manage-license-keys-personal-api-keys",
- "published_at": "2020-08-25T17:52:06Z",
- "updated_at": "2020-08-24T01:18:58Z",
- "breadcrumb": "Contents / APIs / NerdGraph / Examples",
- "document_type": "page",
- "popularity": 1,
- "info": "Use New Relic NerdGraph (our GraphQL API) to create and manage your New Relic license keys, browser license keys, and personal API keys. ",
- "body": "This document contains tutorials on how to use NerdGraph to programmatically create and manage several types of New Relic keys. To build queries and see responses, use our GraphiQL explorer. For more information on our API keys, see API keys. Feature description NerdGraph's ApiAccess field can be used to programmatically create and manage the following types of keys: Personal API keys License keys, including: General license key used for APM Browser license key One common use case for this feature is the ability to create and manage license keys to let you rotate keys for security purposes. Note that you can't use this NerdGraph functionality to manage or delete your original license keys; you can only create additional license keys and manage the ones you've created. General notes about this functionality: All mutations can accept multiple keys as arguments, and will return details about successful changes and errors. See examples below for details. All mutations (create, update and delete) will result in an NrAuditEvent that can be queried for auditing purposes. For details, see Audit events. Some notes about license keys: In the context of using NerdGraph, the license keys are referred to as ingest keys. This feature allows you to create up to 1,000 keys of each license key type, which allows for key rotation. You can't use this NerdGraph functionality to manage or delete your original license keys; you can only create additional license keys and manage the ones you've created. License keys created through NerdGraph can't be found in the New Relic UI. They're only queryable via the API. Some notes about personal API keys: In the context of using NerdGraph, personal API keys are referred to as user keys. User keys are displayed in various UI locations (for example: the User settings UI page). The examples below use license keys (ingest keys), but personal API keys (user keys) are queried in similar ways. We recommend you experiment with queries using the GraphiQL explorer. Create keys You can create multiple keys in a single mutation, for multiple accounts and key types. Note that the mutation can return successfully created keys as well as any errors encountered trying to create keys. Example of creating a key: mutation { apiAccessCreateKeys(keys: {ingest: {accountId: YOUR_ACCOUNT_ID, ingestType: BROWSER, name: \"Browser Key\", notes: \"A note.\"}}) { createdKeys { id key name accountId notes type ... on ApiAccessIngestKey { ingestType } } errors { message type ... on ApiAccessIngestKeyError { accountId errorType ingestType } } } } Results will vary depending on your data. Use the GraphiQL explorer to experiment with mutations and queries. Update keys The update mutation takes the key ID, not the key string, to identify keys. mutation { apiAccessUpdateKeys(keys: {ingest: {keyId: KEY_ID, name: \"Updated name\", notes: \"A new note!\"}}) { updatedKeys { id key type name notes } errors { message } } } Results will vary depending on your data. Use the GraphiQL explorer to experiment with mutations and queries. Delete keys The delete mutation takes the key ID, not the key string, to identify keys. Deleted keys will no longer grant access to New Relic systems and will no longer be returned by queries to the API access GraphQL API. mutation { apiAccessDeleteKeys(keys: {ingestKeyIds: INGEST_KEY_ID}) { deletedKeys { id } errors { message } } } Results will vary depending on your data. Use the GraphiQL explorer to experiment with mutations and queries. Query keys You can access ingest and user keys by querying a single key or all keys, scoped to the actor. If querying for a single key, you must provide the key ID and type (INGEST or USER). Querying for multiple keys is done via a key search, which uses a mandatory types list and an optional scope to filter results. User keys belonging to other users will be obfuscated in the results. Single key example query: query { actor { apiAccess { key(id: INGEST_KEY_ID, keyType: INGEST) { key name type ... on ApiAccessIngestKey { ingestType } } } } } Key search example query: query { actor { apiAccess { keySearch(query: {types: INGEST, scope: {ingestTypes: BROWSER}}) { keys { name key type ... on ApiAccessIngestKey { ingestType } } } } } } Results will vary depending on your data. Use the GraphiQL explorer to experiment with mutations and queries. For more help If you need more help, check out these support and learning resources: Browse the Explorers Hub to get help from the community and join in discussions. Find answers on our sites and learn how to use our support portal. Run New Relic Diagnostics, our troubleshooting tool for Linux, Windows, and macOS. Review New Relic's data security and licenses documentation.",
- "_index": "520d1d5d14cc8a32e600034b",
- "_type": "520d1d5d14cc8a32e600034c",
- "_score": 288.55103,
- "_version": null,
- "_explanation": null,
- "sort": null,
- "highlight": {
- "title": "Use NerdGraph to manage license keys and personal API keys",
- "sections": "NerdGraph",
- "info": "Use New Relic NerdGraph (our GraphQL API) to create and manage your New Relic license keys, browser license keys, and personal API keys. ",
- "category_1": "NerdGraph",
- "body": ". Note that you can't use this NerdGraph functionality to manage or delete your original license keys; you can only create additional license keys and manage the ones you've created. General notes about this functionality: All mutations can accept multiple keys as arguments, and will return details",
- "breadcrumb": "Contents / APIs / NerdGraph / Examples"
- },
- "id": "5efe0487196a6710b1766452"
- },
- {
- "nodeid": 37751,
- "sections": [
- "New Relic Alerts",
- "Get started",
- "Alert policies",
- "Alert conditions",
- "Alert violations",
- "Alert Incidents",
- "Alert notifications",
- "Troubleshooting",
- "Rules, limits, and glossary",
- "Alerts and Nerdgraph",
- "REST API alerts",
- "NerdGraph API: Examples",
- "Alerts features you can manage with NerdGraph",
- "NerdGraph API explorer",
- "Queries",
- "Mutations",
- "For more help"
- ],
- "title": "NerdGraph API: Examples ",
- "category_0": "Alerts and Applied intelligence",
- "type": "docs",
- "category_1": "New Relic Alerts",
- "external_id": "017d6c34d340b9bc035e91483d675915fa5252eb",
- "image": "https://docs.newrelic.com/sites/default/files/thumbnails/image/alerts_query_0.png",
- "url": "https://docs.newrelic.com/docs/alerts-applied-intelligence/new-relic-alerts/alerts-nerdgraph/nerdgraph-api-examples",
- "published_at": "2020-08-25T18:41:45Z",
- "updated_at": "2020-08-11T04:59:00Z",
- "breadcrumb": "Contents / Alerts and Applied intelligence / New Relic Alerts / Alerts and Nerdgraph",
- "document_type": "page",
- "popularity": 1,
- "info": "Read about how you can manage alerts conditions, policies, and muting rules using NerdGraph.",
- "body": "You can manage your policies, conditions, and muting rules programmatically using our GraphQL NerdGraph API. This is a powerful alternative to managing them in New Relic One or through the REST API. Alerts features you can manage with NerdGraph Here's what you can do in NerdGraph: Manage policies Use NRQL conditions Muting rules: suppress notifications The easiest way to discover alerts queries and mutations is through the NerdGraph API explorer. NerdGraph API explorer Our NerdGraph API explorer is a GraphiQL editor where you can prototype queries and mutations. Here are some examples showing how to find fields for queries and mutations. For general information about NerdGraph, see Introduction to NerdGraph. Queries To explore the various queries, look for the available queries under the actor.account.alerts namespace in NerdGraph API explorer: Mutations To explore various mutations, look in the alerts dropdown in the NerdGraph API explorer: For more help If you need more help, check out these support and learning resources: Browse the Explorers Hub to get help from the community and join in discussions. Find answers on our sites and learn how to use our support portal. Run New Relic Diagnostics, our troubleshooting tool for Linux, Windows, and macOS. Review New Relic's data security and licenses documentation.",
- "_index": "520d1d5d14cc8a32e600034b",
- "_type": "520d1d5d14cc8a32e600034c",
- "_score": 218.03085,
- "_version": null,
- "_explanation": null,
- "sort": null,
- "highlight": {
- "title": "NerdGraph API: Examples ",
- "sections": "Mutations",
- "info": "Read about how you can manage alerts conditions, policies, and muting rules using NerdGraph.",
- "body": " Use NRQL conditions Muting rules: suppress notifications The easiest way to discover alerts queries and mutations is through the NerdGraph API explorer. NerdGraph API explorer Our NerdGraph API explorer is a GraphiQL editor where you can prototype queries and mutations. Here are some examples showing",
- "breadcrumb": "Contents / Alerts and Applied intelligence / New Relic Alerts / Alerts and Nerdgraph"
- },
- "id": "5f2dbad864441fd15456a9eb"
- },
- {
- "category_2": "Examples",
- "nodeid": 17141,
- "sections": [
- "NerdGraph",
- "Get started",
- "Examples",
- "NerdGraph cloud integrations API tutorial",
- "Requirements",
- "Access the NerdGraph GraphiQL explorer",
- "Query examples",
- "Mutation examples",
- "Enable an Amazon AWS integration",
- "Change polling interval for Amazon AWS integration",
- "Disable Amazon AWS integration",
- "For more help"
- ],
- "title": "NerdGraph cloud integrations API tutorial",
- "category_0": "APIs",
- "type": "docs",
- "category_1": "NerdGraph",
- "external_id": "15caa0b35be84f2e6245826a5c9ac8e49cad6a89",
- "image": "",
- "url": "https://docs.newrelic.com/docs/apis/nerdgraph/examples/nerdgraph-cloud-integrations-api-tutorial",
- "published_at": "2020-08-25T21:35:41Z",
- "updated_at": "2020-08-10T23:22:01Z",
- "breadcrumb": "Contents / APIs / NerdGraph / Examples",
- "document_type": "page",
- "popularity": 1,
- "info": "Use New Relic's NerdGraph (our GraphQL API) to query your New Relic Infrastructure cloud integration data. ",
- "body": "This document provides examples of how to use New Relic NerdGraph to query and modify your cloud integration configuration data, including Amazon AWS, Microsoft Azure, and Google Cloud Platform (GCP). Using the NerdGraph GraphiQL explorer, you can also query NRQL data. These examples for querying cloud integration configuration data use GraphQL queries and mutations: Queries: requests that are intended to only fetch data Mutations: requests that create or update data on the server Requirements Before querying cloud integration data with NerdGraph, ensure you have: Followed the instructions to connect cloud integrations with New Relic. Created an API key. Access the NerdGraph GraphiQL explorer To access the NerdGraph GraphiQL explorer: Go to https://api.newrelic.com/graphiql. Add any of the following examples. Query examples Queries are requests that are intended to only fetch data (no side effects). Queries in NerdGraph are not static, meaning that you can ask for more or less data depending on your needs. For each query, you can specify exactly what data you want to retrieve, as long as it is supported by the schema. Available provider accounts This query returns a list of all provider accounts available in your infrastructure data. Depending on the provider, additional properties can be requested. For example, for GCP, you can also ask for the serviceAccountId property, which is needed when linking a new GCP project to New Relic. Anonymous: { actor { account(id: ) { cloud { providers { id name slug ... on CloudGcpProvider { serviceAccountId } } } } } } Named: query cloudProviders { actor { account(id: ) { cloud { providers { id name slug } } } } } Specific provider account information This query returns information about a specific provider account for your Amazon AWS integration. The properties id, name, slug are requested, along with a list of integrations available to be monitored. { actor { account(id: ) { cloud { provider(slug: \"aws\") { id slug name services { id slug name } } } } } } Specific integration data from a specific cloud provider This query returns information about a specific cloud service integration of a provider. In this example, the integration is the Amazon AWS ALB monitoring integration and the provider is AWS. The properties id, name, slug, and isAllowed are requested with the available configuration parameters. { actor { account(id: ) { cloud { provider(slug: \"aws\") { service(slug: \"alb\") { id name slug isEnabled } } } } } } List of enabled cloud accounts This query returns the list of cloud accounts enabled with your New Relic account. (Your cloud account associates your New Relic account and a specific provider account with your integration.) You can enable multiple cloud provider accounts in the same New Relic account, even with the same cloud provider. { actor { account(id: ) { cloud { linkedAccounts { id name createdAt provider { id name } } } } } } Specific linked account data This query returns information about a linked account, including the properties name, providerId, and a list of the cloud integrations enabled for monitoring. { actor { account(id: ) { cloud { linkedAccount(id: ) { name provider { id name } integrations { id name createdAt updatedAt } } } } } } Enabled cloud integrations for all linked accounts This query returns all monitored integrations for all the provider cloud accounts. { actor { account(id: ) { cloud { linkedAccounts { name provider { id name } integrations { id name service { id name } createdAt updatedAt } } } } } } Specific cloud integration data for a specific linked account This query returns information about a specific integration from a specific linked account. { actor { account(id: ) { cloud { linkedAccount(id: ) { name provider { id name } integration(id: ) { id name service { id name } createdAt updatedAt } } } } } } Mutation examples Mutations are requests that are intended to have side effects, such as creating or updating data on the server. Mutations require the keyword mutation and the name of the mutation. NerdGraph mutations are restricted to a subset of all possible mutations. Link an account This mutation allows linking cloud provider accounts to a New Relic account, creating one or more linked accounts. It can link one specific cloud provider account (for example aws) to the New Relic account or multiple cloud provider accounts to one New Relic account. Required: The parameter is required and cannot be empty. It must be unique in your New Relic account. Other parameters are specific to the provider (AWS, GCP, and Azure) and are also required. In the following sections, you can see which parameters are required for each provider account. After linking an account the createdAt and updatedAt values are equal. mutation { cloudLinkAccount( accounts: { accountId: , aws: [{ name: , }] azure: [{ name: , }] gcp: [{ name: , }] } ) { linkedAccounts { id name authLabel createdAt updatedAt } } } } Link an Amazon AWS account This mutation links an Amazon AWS provider account to your New Relic account. mutation { cloudLinkAccount( accountId: , accounts: { aws: [{ name: , arn: }] } ) { linkedAccounts { id name authLabel createdAt updatedAt } } } } Link a Microsoft Azure account This mutation links a Microsoft Azure cloud subscription to the New Relic account. mutation { cloudLinkAccount( accountId: , accounts: { azure: [{ name: , applicationId: , clientSecret: , tenantId: , subscriptionId: }] } ) { linkedAccounts { id name authLabel createdAt updatedAt } } } Link a Google Cloud Platform (GCP) project This mutation links a GCP project to the New Relic account. mutation { cloudLinkAccount( accountId: , accounts: { gcp: [{ name: , projectId: }] } ) { linkedAccounts { id name authLabel createdAt updatedAt } } } Rename one or more cloud accounts This mutation allows you to rename one or more linked provider accounts. The name parameter is required, cannot be empty, and must be unique within your New Relic account. mutation { cloudRenameAccount( accountId: , accounts: [ { id: , name: }, { id: , name: } ] ) { linkedAccounts { id name } } } Enable an integration in a cloud account This mutation allows you to enable the monitoring of one or more specific cloud integrations in an existing cloud account. With this mutation, New Relic records data for the enabled integration from the provider account. For each provider account you have access to different input parameters, matching each available service. mutation { cloudConfigureIntegration ( accountId: , integrations: { : { : [{ linkedAccountId: , }] } } ) { integrations { id name integration { id slug } ... on SqsIntegration { awsRegions } } } } Enable an integration in multiple cloud accounts If you have many provider accounts linked, you can enable the same integration in the many cloud accounts at the same time. For the output of the operation, you can use GraphQL fragments for integration specific configuration parameters. mutation { cloudConfigureIntegration ( accountId: , integrations: { : { : [ { linkedAccountId: }, { linkedAccountId: } ] } } ) { integrations { id name integration { id name } ... on SqsIntegration { awsRegions } } } } Enable multiple integrations in multiple cloud accounts If you have multiple cloud accounts linked, you can also enable multiple integrations in multiple linked cloud accounts at the same time. For the output of the operation, you can use GraphQL fragments to ask for integration specific configuration parameters. mutation { cloudConfigureIntegration ( accountId: , integrations: { : { : [ { linkedAccountId: } ] : [ { linkedAccountId: } ] }, : { : [ { linkedAccountId: }, { linkedAccountId: } ] } } ) { integrations { id name service { id name } ... on SqsIntegration { awsRegions } } } } Modify an integration's configuration (regions, polling intervals, etc.) This mutation also allows you to modify one or more cloud integrations and change one or more configuration parameters. Each service will have specific parameters that you can modify. For parameters of a type list (for example, awsRegion) supply the full list. For the output of the operation, you can use GraphQL fragments to ask for integration specific configuration parameters. mutation { cloudConfigureIntegration ( accountId: , integrations: { : { : [{ linkedAccountId: , metricsPollingInterval: , : , : , }] } } ) { integrations { id name service { id slug } ... on SqsIntegration { metricsPollingInterval, , } } errors { type message } } } Disable (remove) an integration This mutation allows you to disable an integration and stop data collection for the specific cloud integration. mutation { cloudDisableIntegration ( accountId: , integrations: { : { : [ { linkedAccountId: } ] } } ) { disabledIntegrations { id name authLabel provider { id } } errors { type message } } } Unlink account This mutation allows you to unlink cloud provider accounts from New Relic account. This action can not be undone. However, you can link the account again, but account history will still be lost. mutation { cloudUnlinkAccount ( accountId: , accounts: { { linkedAccountId: } } ) { unlinkedAccounts { id name } errors { type message } } } Enable an Amazon AWS integration This example uses an Amazon AWS SQS integration and assumes you have connected an AWS account to New Relic. To enable an Amazon AWS integration: Send query to fetch account data Send a query to fetch data about the account, specifically available providers and already created provider accounts: { actor { account(id: ) { cloud { providers { id name slug } linkedAccounts { name integrations { id name } } } } } } Link AWS provider account Link an AWS provider account, if there is not one already linked or if you want to link another AWS account: Use your New Relic account identifier in the parameter. Provide a name for the provider account in the . Include the ARN of the AWS role used to fetch data from your AWS account. mutation { cloudLinkAccount( accountId: , accounts: { aws: [{ name: , arn: }] } ) { linkedAccounts { id name authLabel createdAt updatedAt } errors { type message } } } Enable Amazon AWS SQS integration Use your New Relic account ID in the parameter and the ID of the provider account in the parameter value. mutation { cloudConfigureIntegration ( accountId: , integrations: { aws: { sqs: [ { linkedAccountId: } ] } } ) { integrations { id name service { id name } } errors { type message } } } Enable integration in multiple provider accounts If you have multiple accounts with the same provider account, you can enable the same integration in multiple provider accounts at the same time. Use your New Relic account ID in the parameter and the ID of the provider accounts in the parameter value. mutation { cloudConfigureIntegration ( accountId: , integrations: { aws: { sqs: [ { linkedAccountId: }, { linkedAccountId: , configuration_param_1: value_1, configuration_param_2: value_2 } ] } } }) { integrations { id name service { id name } } errors { type message } } } Change polling interval for Amazon AWS integration This example uses an Amazon AWS SQS integration and assumes you have connected an AWS account to New Relic. To change the polling interval of an AWS integration: Update the polling interval To update the polling interval for an Amazon AWS SQS integration, use your New Relic account ID in the parameter and the id of the linked provider account in the parameter value: mutation { cloudConfigureIntegration( accountId: , integrations: { aws : { sqs: [ { linkedAccountId: , metricsPollingInterval: 300 } ] } } ) { integrations { id name service { id slug } ... on SqsIntegration { metricsPollingInterval } } errors { type message } } } Disable Amazon AWS integration This example uses an Amazon AWS SQS integration and assumes you have connected an AWS account to New Relic. To disable an AWS integration: Disable the SQS integration Use your New Relic account identifier in the parameter and the ID of the linked cloud account the parameter value. mutation { cloudDisableIntegration ( accountId: , integrations: { aws: { sqs : [ { linkedAccountId: } ] } } ) { disabledIntegrations { id accountId name } errors { type message } } } For more help If you need more help, check out these support and learning resources: Browse the Explorers Hub to get help from the community and join in discussions. Find answers on our sites and learn how to use our support portal. Run New Relic Diagnostics, our troubleshooting tool for Linux, Windows, and macOS. Review New Relic's data security and licenses documentation.",
- "_index": "520d1d5d14cc8a32e600034b",
- "_type": "520d1d5d14cc8a32e600034c",
- "_score": 171.44781,
- "_version": null,
- "_explanation": null,
- "sort": null,
- "highlight": {
- "title": "NerdGraph cloud integrations API tutorial",
- "sections": "NerdGraph",
- "info": "Use New Relic's NerdGraph (our GraphQL API) to query your New Relic Infrastructure cloud integration data. ",
- "category_1": "NerdGraph",
- "body": "This document provides examples of how to use New Relic NerdGraph to query and modify your cloud integration configuration data, including Amazon AWS, Microsoft Azure, and Google Cloud Platform (GCP). Using the NerdGraph GraphiQL explorer, you can also query NRQL data. These examples for querying",
- "breadcrumb": "Contents / APIs / NerdGraph / Examples"
- },
- "id": "5d83537b28ccbc263a1b7bf7"
- },
- {
- "nodeid": 37711,
- "sections": [
- "New Relic Alerts",
- "Get started",
- "Alert policies",
- "Alert conditions",
- "Alert violations",
- "Alert Incidents",
- "Alert notifications",
- "Troubleshooting",
- "Rules, limits, and glossary",
- "Alerts and Nerdgraph",
- "REST API alerts",
- "NerdGraph API: NRQL condition alerts",
- "Steps to create a NRQL condition",
- "NRQL static condition",
- "NRQL baseline condition",
- "NRQL outlier condition",
- "Update a condition",
- "Update mutations",
- "List and filter NRQL conditions",
- "Singular NRQL condition queries",
- "Update the description",
- "Delete conditions",
- "For more help"
- ],
- "title": "NerdGraph API: NRQL condition alerts ",
- "category_0": "Alerts and Applied intelligence",
- "type": "docs",
- "category_1": "New Relic Alerts",
- "external_id": "86591bd20017930f1e4eef1b1a76e3806298dbb9",
- "image": "",
- "url": "https://docs.newrelic.com/docs/alerts-applied-intelligence/new-relic-alerts/alerts-nerdgraph/nerdgraph-api-nrql-condition-alerts",
- "published_at": "2020-08-25T21:52:30Z",
- "updated_at": "2020-08-11T04:56:49Z",
- "breadcrumb": "Contents / Alerts and Applied intelligence / New Relic Alerts / Alerts and Nerdgraph",
- "document_type": "page",
- "popularity": 1,
- "info": "Examples of how to use the NerdGraph API explorer to create alert conditions, queries, and mutations.",
- "body": "You can manage alerts conditions using our GraphQL NerdGraph API. Here are some conditions queries and mutations you can develop in our NerdGraph API explorer. See the NerdGraph introduction for help getting started with NerdGraph API explorer. This document covers the following: Steps to create a NRQL condition NRQL static condition NRQL baseline condition NRQL outlier condition Update a condition Update mutations List and filter NRQL conditions Singular NRQL condition queries Create a description Delete conditions Steps to create a NRQL condition Follow these steps: Decide which condition type you want to create (see NRQL Condition threshold types). Find your relevant policyID by doing one of the following: Use the NerdGraph policies API. Go to one.newrelic.com, in the top nav click Alerts & AI, then click Policies. Choose a policy. Find the ID under the policy name. Provide the appropriate mutation for your NRQL condition type and the relevant values. The NerdGraph GraphiQL explorer is the best place to find up-to-date documentation about the per-field specifics of the NerdGraph NRQL Conditions API. For example, questions like \"What does the valueFunction field accept?\" are best answered with the inline NerdGraph documentation. NRQL static condition Here's an example of creating a static condition: mutation { alertsNrqlConditionStaticCreate(accountId: YOUR_ACCOUNT_ID, policyId: YOUR_POLICY_ID, condition: { name: \"Low Host Count - Catastrophic\" enabled: true nrql: { query: \"SELECT uniqueCount(host) from Transaction where appName='my-app-name'\" evaluationOffset: 3 } terms: { threshold: 2 thresholdOccurrences: AT_LEAST_ONCE thresholdDuration: 600 operator: BELOW priority: CRITICAL } valueFunction: SINGLE_VALUE violationTimeLimit: TWENTY_FOUR_HOURS }) { id name } } NRQL baseline condition Here's an example of creating a baseline condition: mutation { alertsNrqlConditionBaselineCreate(accountId: YOUR_ACCOUNT_ID, policyId: YOUR_POLICY_ID, condition: { name: \"Baseline Condition\" enabled: true baselineDirection: UPPER_ONLY nrql: { query: \"SELECT average(duration) FROM Transaction\" evaluationOffset: 3 } terms: { threshold: 13 thresholdDuration: 180 thresholdOccurrences: ALL operator: ABOVE priority: CRITICAL } violationTimeLimit: TWENTY_FOUR_HOURS }) { id name baselineDirection } } NRQL outlier condition Here's an example of creating an outlier condition: mutation { alertsNrqlConditionOutlierCreate(accountId: YOUR_ACCOUNT_ID, policyId: YOUR_POLICY_ID, condition: { name: \"Outlier Condition\" enabled: true expectedGroups: 4 openViolationOnGroupOverlap: false nrql: { query: \"SELECT average(duration) FROM Transaction FACET httpResponseCode\" evaluationOffset: 3 } terms: { threshold: 1 thresholdDuration: 300 thresholdOccurrences: ALL operator: ABOVE priority: CRITICAL } violationTimeLimit: TWENTY_FOUR_HOURS }) { id name expectedGroups openViolationOnGroupOverlap } } Update a condition Complete the following: Determine the type of your existing condition by requesting the type field in a nrqlConditionsSearch query like this: { actor { account(id: YOUR_ACCOUNT_ID) { alerts { nrqlConditionsSearch { nrqlConditions { id type } } } } } } The type returned is what you use for your update mutation. For example, if the type returned is STATIC, use alertsNrqlConditionStaticUpdate. If the type returned is BASELINE, use alertsNrqlConditionBaselineUpdate. If the type returned is OUTLIER, use alertsNrqlConditionOutlierUpdate. Provide the id of your condition to your relevant condition type mutation. Note that you can only update conditions of the relevant type. Only provide update mutations for the fields you want to update. Fields you don't provide in the update are not touched. Update mutations Only fields that you provide in the update are changed. In the following example, baselineDirection returns unchanged, but name is updated. mutation { alertsNrqlConditionBaselineUpdate(id: YOUR_CONDITION_ID, accountId: YOUR_ACCOUNT_ID, condition: { name: \"Your updated name\" }) { id name baselineDirection } } List and filter NRQL conditions To list or filter your NRQL conditions, use the nrqlConditionsSearch query in NerdGraph. Use cursor pagination The basic of list functionality for NRQL conditions allows you to paginate through your NRQL conditions as well as request the total count of conditions per account. The nrqlConditionsSearch query utilizes cursor pagination to paginate through resources. The idea behind cursor pagination is that the client will request a cursor in a programmatic loop until the cursor comes back empty. An initial list response will look something like this: { actor { account(id: YOUR_ACCOUNT_ID) { alerts { nrqlConditionsSearch { nextCursor nrqlConditions { id name type } totalCount } } } } } This example returns a JSON response like this: { \"data\": { \"actor\": { \"account\": { \"alerts\": { \"nrqlConditionsSearch\": { \"nextCursor\": \"WOwfJ4+TWm9QTFeKMGyg+w==:QqkI8S4+Wwnpno6z+uk8kQ==\", \"nrqlConditions\": [ { \"id\": \"4432\", \"name\": \"Baseline Condition\", \"type\": \"BASELINE\" }, { \"id\": \"443\", \"name\": \"A static condition\", \"type\": \"STATIC\" }, // more conditions here in reality ], \"totalCount\": 435 } } } } }, } In order to paginate through conditions in the response, have the client request the cursor to be returned until the nextCursor returns from the response as null: { actor { account(id: YOUR_ACCOUNT_ID) { alerts { nrqlConditionsSearch(cursor: \"WOwfJ4+TWm9QTFeKMGyg+w==:QqkI8S4+Wwnpno6z+uk8kQ==\", ) { nextCursor nrqlConditions { id name type } totalCount } } } } } Request type-specific fields Certain fields are only available on specific NRQL condition types. The main reason that mutations are split between the different condition types is because they have minor differences between the fields they accept. For example, valueFunction is only relevant for static NRQL conditions and baselineDirection is only relevant on baseline NRQL conditions. But if these fields are only available on these certain condition types, how do we return them in a list of all of our condition types? The answer is a GraphQL convention known as inline fragments. Inline fragments allow you to access the data on a specific type of NRQL condition: { actor { account(id: YOUR_ACCOUNT_ID) { alerts { nrqlConditionsSearch { nrqlConditions { id name type ...on AlertsNrqlStaticCondition { valueFunction } ...on AlertsNrqlBaselineCondition { baselineDirection } ...on AlertsNrqlOutlierCondition { expectedGroups } } } } } } } In the previous example query, we are asking GraphQL to do the hard work for us to determine which NRQL conditions are the correct type. So, when the returned type is a static condition, it will return the valueFunction in the object. When the returned type is a baseline condition, it will return baselineDirection instead, and when the type is an outlier condition, it will return expectedGroups. Here is an example response: { \"data\": { \"actor\": { \"account\": { \"alerts\": { \"nrqlConditionsSearch\": { \"nrqlConditions\": [ { \"baselineDirection\": \"UPPER_ONLY\", \"id\": \"342\", \"name\": \"My baseline condition\", \"type\": \"BASELINE\" }, { \"id\": \"553\", \"name\": \"My static condition\", \"type\": \"STATIC\", \"valueFunction\": \"SINGLE_VALUE\" }, { \"expectedGroups\": 4, \"id\": \"802\", \"name\": \"My outlier condition\", \"type\": \"OUTLIER\" } ] } } } } } } Filter NRQL conditions You can filter NRQL conditions with the searchCriteria argument of the nrqlConditionsSearch query: Here's an example of filtering NRQL conditions with matching by name. This query returns NRQL conditions that match the provided name. Note that this match is case insensitive. { actor { account(id: YOUR_ACCOUNT_ID) { alerts { nrqlConditionsSearch(searchCriteria: { name: \"Baseline Condition\" }) { nrqlConditions { id name type } } } } } } Singular NRQL condition queries You can use the NRQL condition API to query for a singular condition. Run the nrqlCondition query in the alerts namespace. Similar to type specific fields on the nrqlConditionSearch query, you can also use these inline fragmentsto request fields that are restricted to a NRQL condition type. { actor { account(id: YOUR_ACCOUNT_ID) { alerts { nrqlCondition(id: YOUR_CONDITION_ID) { id name ...on AlertsNrqlStaticCondition { valueFunction } } } } } } Update the description This will walk you through the procedure to create a description for a NRQL alert condition. 1. Get all the conditions for a policy: { actor { account(id: YOUR_ACCOUNT_ID) { alerts { nrqlConditions(policyId: YOUR_POLICY_ID) { nextCursor results { id name description enabled nrql { query sinceValue } policyId runbookUrl terms { duration operator priority timeFunction threshold } type violationTimeLimit } } } } } } 2. Get the details for a single condition: { actor { account(id: YOUR_ACCOUNT_ID) { alerts { nrqlCondition(id: \"YOUR_CONDITION_ID\") { description id enabled name nrql { query evaluationOffset } policyId runbookUrl terms { operator priority threshold thresholdDuration thresholdOccurrences } type violationTimeLimit } } } } } 3. Create a mutation with the description. Here's an empty mutation template: mutation { alertsNrqlConditionStaticUpdate(accountId: YOUR_ACCOUNT_ID, id: \"YOUR_CONDITION_ID\", condition: {description: \"\"}) { description } } Here'a an example mutation with an included example description: mutation { alertsNrqlConditionStaticUpdate(accountId: 123456, id: \"123456\", condition: {description: \"timestamp : {{timestamp}} \\n accountId : {{accountId}} \\n type : {{type}} \\n event : {{event}} \\n description : {{description}} \\n policyId : {{policyId}} \\n policyName: {{policyName}} \\n conditionName : {{conditionName}} \\n conditionId : {{conditionId}} \\n product : {{product}} \\n conditionType : {{conditionType}} \\n RunbookUrl : {{runbookUrl}} \\n nrqlQuery : {{nrqlQuery}} \\n nrqlEventType : {{nrqlEventType}} \\n targetID : {{targetId}} \\n targetName : {{targetName}} \\n commandLine : {{tag.commandLine}} \\n entityGuid : {{tag.entityGuid}} \\n entityName : {{tag.entityName}} \\n fullHostname : {{tag.fullHostname}} \\n instanceType : {{tag.instanceType}} \\n processDisplayName : {{tag.processDisplayName}}\"}) { description } } Delete conditions You can use the alertsConditionDelete mutation to delete any type of condition. You can only request the id field on a delete mutation; for example: mutation { alertsConditionDelete(accountId: YOUR_ACCOUNT_ID, id: YOUR_CONDITION_ID) { id } } For more help If you need more help, check out these support and learning resources: Browse the Explorers Hub to get help from the community and join in discussions. Find answers on our sites and learn how to use our support portal. Run New Relic Diagnostics, our troubleshooting tool for Linux, Windows, and macOS. Review New Relic's data security and licenses documentation.",
- "_index": "520d1d5d14cc8a32e600034b",
- "_type": "520d1d5d14cc8a32e600034c",
- "_score": 169.57275,
+ "_score": 92.73967,
"_version": null,
"_explanation": null,
"sort": null,
"highlight": {
- "title": "NerdGraph API: NRQL condition alerts ",
- "sections": "Update mutations",
- "info": "Examples of how to use the NerdGraph API explorer to create alert conditions, queries, and mutations.",
- "body": "You can manage alerts conditions using our GraphQL NerdGraph API. Here are some conditions queries and mutations you can develop in our NerdGraph API explorer. See the NerdGraph introduction for help getting started with NerdGraph API explorer. This document covers the following: Steps to create",
- "breadcrumb": "Contents / Alerts and Applied intelligence / New Relic Alerts / Alerts and Nerdgraph"
+ "title": "Query and store data",
+ "sections": "Query and store data",
+ "info": "Reference guide for SDK query components using NerdGraph",
+ "tags": "nerdgraph query components",
+ "body": ", EntityByGuidQuery, EntityByNameQuery. Storage queries: New Relic One provides a simple storage mechanism that we call NerdStorage. This can be used by Nerdpack creators to store application configuration setting data, user-specific data, and other small pieces of data. Components in this category"
},
- "id": "5f2dee1128ccbc562e88dfc1"
- },
+ "id": "5efa989e28ccbc2f15307deb"
+ }
+ ],
+ "/build-apps/add-time-picker-guide": [
{
"sections": [
"Intro to New Relic One API components",
@@ -3237,7 +3003,7 @@
"external_id": "3620920c26bcd66c59c810dccb1200931b23b8c2",
"image": "",
"url": "https://developer.newrelic.com/explore-docs/intro-to-sdk/",
- "published_at": "2020-08-28T01:49:25Z",
+ "published_at": "2020-08-29T01:59:19Z",
"updated_at": "2020-08-14T01:47:12Z",
"document_type": "page",
"popularity": 1,
@@ -3245,1175 +3011,1320 @@
"body": "Intro to New Relic One API components To help you build New Relic One applications, we provide you with the New Relic One SDK. Here we give you an introduction to the types of API calls and components in the SDK. The SDK provides everything you need to build your Nerdlets, create visualizations, and fetch New Relic or third-party data. Components of the SDK SDK components are located in the Node module package named nr1, which you get when you install the NR1 CLI. The nr1 components can be divided into several categories: UI components Chart components Query and storage components Platform APIs UI components The UI components category of the SDK contains React UI components, including: Text components: These components provide basic font and heading elements. These include HeadingText and BlockText. Layout components: These components give you control over the layout, and help you build complex layout designs without having to deal with the CSS. Layout components include: Grid and GridItem: for organizing more complex, larger scale page content in rows and columns Stack and StackItem: for organizing simpler, smaller scale page content (in column or row) Tabs and TabsItem: group various related pieces of content into separate hideable sections List and ListItem: for providing a basic skeleton of virtualized lists Card, CardHeader and CardBody : used to group similar concepts and tasks together Form components: These components provide the basic building blocks to interact with the UI. These include Button, TextField, Dropdown and DropdownItem, Checkbox, RadioGroup, Radio, and Checkbox. Feedback components: These components are used to provide feedback to users about actions they have taken. These include: Spinnerand Toast. Overlaid components: These components are used to display contextual information and options in the form of an additional child view that appears above other content on screen when an action or event is triggered. They can either require user interaction (like modals), or be augmenting (like a tooltip). These include: Modal and Tooltip. Components suffixed with Item can only operate as direct children of that name without the suffix. For example: GridItem should only be found as a child of Grid. Chart components The Charts category of the SDK contains components representing different types of charts. The ChartGroup component helps a group of related charts share data and be aligned. Some chart components can perform NRQL queries on their own; some accept a customized set of data. Query and storage components The Query components category contains components for fetching and storing New Relic data. The main way to fetch data is with NerdGraph, our GraphQL endpoint. This can be queried using NerdGraphQuery. To simplify use of NerdGraph queries, we provide some components with pre-defined queries. For more on using NerdGraph, see Queries and mutations. We also provide storage for storing small data sets, such as configuration settings data, or user-specific data. For more on this, see NerdStorage. Platform APIs The Platform API components of the SDK enable your application to interact with different parts of the New Relic One platform, by reading and writing state from and to the URL, setting the configuration, etc. They can be divided into these categories: PlatformStateContext: provides read access to the platform URL state variables. Example: timeRange in the time picker. navigation: an object that allows programmatic manipulation of the navigation in New Relic One. Example: opening a new Nerdlet. NerdletStateContext: provides read access to the Nerdlet URL state variables. Example: an entityGuid in the entity explorer. nerdlet: an object that provides write access to the Nerdlet URL state.",
"_index": "520d1d5d14cc8a32e600034b",
"_type": "520d1d5d14cc8a32e600034c",
- "_score": 161.55847,
+ "_score": 159.29568,
"_version": null,
"_explanation": null,
"sort": null,
"highlight": {
- "sections": "Query and storage components",
- "tags": "query and storage components",
- "body": " is with NerdGraph, our GraphQL endpoint. This can be queried using NerdGraphQuery. To simplify use of NerdGraph queries, we provide some components with pre-defined queries. For more on using NerdGraph, see Queries and mutations. We also provide storage for storing small data sets, such as configuration"
+ "tags": "New Relic One apps",
+ "body": ". They can be divided into these categories: PlatformStateContext: provides read access to the platform URL state variables. Example: timeRange in the timepicker. navigation: an object that allows programmatic manipulation of the navigation in New Relic One. Example: opening a new Nerdlet"
},
"id": "5efa989e28ccbc4071307de5"
- }
- ],
- "/collect-data/collect-data-from-any-source": [
+ },
{
- "category_2": "Ingest APIs",
- "nodeid": 35471,
+ "image": "",
+ "url": "https://developer.newrelic.com/build-apps/",
"sections": [
- "Ingest and manage data",
- "Get started",
- "Understand data",
- "Manage data",
- "Ingest APIs",
- "Telemetry SDKs: Report custom telemetry data",
- "Requirements and compatibility",
- "Available libraries",
- "Write your own Telemetry SDK or contribute to an existing one",
- "Integrations built with the Telemetry SDKs",
- "For more help"
+ "Build apps",
+ "Guides to build apps",
+ "Create a \"Hello, World!\" application",
+ "Permissions for managing applications",
+ "Set up your development environment",
+ "Add, query, and mutate data using NerdStorage",
+ "Add the NerdGraphQuery component to an application",
+ "Add a time picker to your app",
+ "Add a table to your app",
+ "Publish and deploy apps",
+ "Create a custom map view"
],
- "title": "Telemetry SDKs: Report custom telemetry data",
- "category_0": "Telemetry Data Platform",
- "type": "docs",
- "category_1": "Ingest and manage data",
- "external_id": "47a4c8f38c1b1674504ea302d865fd499e90ea39",
- "image": "",
- "url": "https://docs.newrelic.com/docs/telemetry-data-platform/get-started/capabilities/telemetry-sdks-send-custom-telemetry-data-new-relic",
- "published_at": "2020-08-26T04:10:46Z",
- "updated_at": "2020-08-11T01:15:34Z",
- "breadcrumb": "Contents / Telemetry Data Platform / Ingest and manage data / Ingest APIs",
+ "published_at": "2020-08-29T01:50:40Z",
+ "title": "Build apps",
+ "updated_at": "2020-08-29T01:50:40Z",
+ "type": "developer",
+ "external_id": "abafbb8457d02084a1ca06f3bc68f7ca823edf1d",
"document_type": "page",
"popularity": 1,
- "info": "Report custom telemetry data with New Relic's open-source Telemetry SDKs.",
- "body": "Our Telemetry SDKs are an open source set of API client libraries that send metrics and trace data to the New Relic platform. We offer open-source integrations for telemetry tools like Prometheus, Istio, and OpenCensus that were created using our Telemetry SDKs. If those solutions (or our other integrations) don't meet your needs, you can use the Telemetry SDKs to create your own telemetry data solutions. Requirements and compatibility To build with the Telemetry SDKs, you will need an Event API insert key. New Relic has contributed the Telemetry SDK to the open source community under an Apache 2.0 license. Available libraries The Telemetry SDKs are open source software on GitHub. Use the language-specific GitHub links below to get library details, coding examples, and procedures for how to use the SDKs. We currently support the following libraries, with more to be created in the future: Language Library Supported data types Java Java library on GitHub New Relic Metrics New Relic Traces Node/TypeScript NodeJS library on GitHub New Relic Metrics New Relic Traces Python Python library on GitHub New Relic Metrics New Relic Events New Relic Traces Go Go library on Github New Relic Metrics New Relic Traces .NET .NET library on GitHub .NET package in NuGet New Relic Metrics New Relic Traces For more on the supported data types: Metrics: see the Metric API Traces: see the Trace API Write your own Telemetry SDK or contribute to an existing one If you need a Telemetry SDK in a language that does not currently exist or want to contribute to an existing library, please see the Telemetry SDK specifications. Integrations built with the Telemetry SDKs To see the integrations built using our Telemetry SDKs, see Open source telemetry integrations. For all monitoring solutions, see our integrations page. For more help If you need more help, check out these support and learning resources: Browse the Explorers Hub to get help from the community and join in discussions. Find answers on our sites and learn how to use our support portal. Run New Relic Diagnostics, our troubleshooting tool for Linux, Windows, and macOS. Review New Relic's data security and licenses documentation.",
+ "body": "Build apps You know better than anyone what information is crucial to your business, and how best to visualize it. Sometimes, this means going beyond dashboards to creating your own app. With React and GraphQL, you can create custom views tailored to your business. These guides are designed to help you start building apps, and dive into our library of components. We also have a growing number of open source apps that you can use to get started. The rest is up to you. Guides to build apps 15 min Create a \"Hello, World!\" application Build a \"Hello, World!\" app and publish it to New Relic One Permissions for managing applications Learn about permissions for subscribing to apps 20 min Set up your development environment Prepare to build apps and contribute to this site 45 min Add, query, and mutate data using NerdStorage NerdStorage is a document database accessible within New Relic One. It allows you to modify, save, and retrieve documents from one session to the next. 20 minutes Add the NerdGraphQuery component to an application The NerdGraphQuery component allows you to query data from your account and add it to a dropdown menu in an application 20 min Add a time picker to your app Add a time picker to a sample application 30 min Add a table to your app Add a table to your New Relic One app 30 min Publish and deploy apps Start sharing the apps you build 30 min Create a custom map view Build an app to show page view data on a map",
+ "info": "",
"_index": "520d1d5d14cc8a32e600034b",
"_type": "520d1d5d14cc8a32e600034c",
- "_score": 158.98557,
+ "_score": 156.37874,
"_version": null,
"_explanation": null,
"sort": null,
"highlight": {
- "title": "TelemetrySDKs: Report custom telemetry data",
- "sections": "TelemetrySDKs: Report custom telemetry data",
- "info": "Report custom telemetry data with New Relic's open-source TelemetrySDKs.",
- "category_0": "Telemetry Data Platform",
- "category_2": "Ingest APIs",
- "body": " Metrics New Relic Traces .NET .NET library on GitHub .NET package in NuGet New Relic Metrics New Relic Traces For more on the supported data types: Metrics: see the MetricAPI Traces: see the TraceAPI Write your own TelemetrySDK or contribute to an existing one If you need a TelemetrySDK",
- "breadcrumb": "Contents / Telemetry Data Platform / Ingest and manage data / Ingest APIs"
+ "title": "Build apps",
+ "sections": "Add a timepicker to your app",
+ "body": " app Add a timepicker to a sample application 30 min Add a table to your app Add a table to your New Relic One app 30 min Publish and deploy apps Start sharing the apps you build 30 min Create a custom map view Build an app to show page view data on a map"
},
- "id": "5d89fefbe7b9d2537ed30dc1"
+ "id": "5efa999d64441fc0f75f7e21"
},
{
- "category_2": "Get started",
- "nodeid": 36051,
+ "image": "https://developer.newrelic.com/static/nerd-days-cd32e6ce7bce9feb13142801151df03c.png",
+ "url": "https://developer.newrelic.com/",
"sections": [
- "Ingest and manage data",
- "Get started",
- "Understand data",
- "Manage data",
- "Ingest APIs",
- "Get data into New Relic",
- "New Relic-built agents and integrations",
- "Agent APIs",
- "Telemetry SDKs",
- "APIs for sending metrics, traces, logs, and events",
- "New Relic One applications",
- "For more help"
+ "Mark your calendar for Nerd Days 1.0",
+ "Get coding",
+ "Create custom events",
+ "Add tags to apps",
+ "Build a Hello, World! app",
+ "Get inspired",
+ "Add a table to your app",
+ "Collect data - any source",
+ "Automate common tasks",
+ "Create a custom map view",
+ "Add a time picker to your app",
+ "Add custom attributes",
+ "New Relic developer champions",
+ "New Relic Podcasts"
],
- "title": "Get data into New Relic",
- "category_0": "Telemetry Data Platform",
- "type": "docs",
- "category_1": "Ingest and manage data",
- "external_id": "7a413b4d7e5bd81088a08507ae4bad64c7e24b2d",
+ "published_at": "2020-08-29T01:49:31Z",
+ "title": "New Relic Developers",
+ "updated_at": "2020-08-29T01:39:08Z",
+ "type": "developer",
+ "external_id": "214583cf664ff2645436a1810be3da7a5ab76fab",
+ "document_type": "page",
+ "popularity": 1,
+ "body": "Mark your calendar for Nerd Days 1.0 Nerd Days is a FREE engineering conference that kicks off October 13 (Dates vary by region). Focused on building more perfect software, our goal is to spend less time looking at slides that tell you what software can do and more time on getting your hands on the software to solve problems efficiently. Got a cool project you want to share with fellow engineers? Submit your proposal! Submissions are due September 1, 2020 at 11:59 PM PT. 4 Days : 13 Hours : 10 Minutes : 0 Seconds Learn more Get coding Create a free account 5 min Create custom events Define, visualize, and get alerts on the data you want using custom events Start the guide 7 min Add tags to apps Add tags to applications you instrument for easier filtering and organization Start the guide 12 min Build a Hello, World! app Build a Hello, World! app and publish it to your local New Relic One Catalog Start the guide Get inspired 30 min Add a table to your app Add a table to your New Relic One app 15 min Collect data - any source APIs, agents, OS emitters - get any data 20 min Automate common tasks Use the New Relic CLI to tag apps and create deployment markers 30 min Create a custom map view Build an app to show page view data on a map 20 min Add a time picker to your app Add a time picker to a sample application Add custom attributes Use custom attributes for deeper analysis Show 20 more guides Looking for more inspiration? Check out the open source projects built by the New Relic community. New Relic developer champions New Relic Champions are solving big problems using New Relic as their linchpin and are recognized as experts and leaders in the New Relic technical community. Nominate a developer champion Learn more about developer champions New Relic Podcasts We like to talk, especially to developers about developer things. Join us for conversations on open source, observability, software design and industry news. Listen",
+ "info": "",
+ "_index": "520d1d5d14cc8a32e600034b",
+ "_type": "520d1d5d14cc8a32e600034c",
+ "_score": 149.95256,
+ "_version": null,
+ "_explanation": null,
+ "sort": null,
+ "highlight": {
+ "sections": "Add a timepicker to your app",
+ "body": " view Build an app to show page view data on a map 20 min Add a timepicker to your app Add a timepicker to a sample application Add custom attributes Use custom attributes for deeper analysis Show 20 more guides Looking for more inspiration? Check out the open source projects built by the New"
+ },
+ "id": "5d6fe49a64441f8d6100a50f"
+ },
+ {
+ "sections": [
+ "Add tables to your New Relic One application",
+ "Before you begin",
+ "Clone and set up the example application",
+ "Work with table components",
+ "Next steps"
+ ],
+ "title": "Add tables to your New Relic One application",
+ "type": "developer",
+ "tags": [
+ "table in app",
+ "Table component",
+ "TableHeaderc omponent",
+ "TableHeaderCell component",
+ "TableRow component",
+ "TableRowCell component"
+ ],
+ "external_id": "7ff7a8426eb1758a08ec360835d9085fae829936",
+ "image": "https://developer.newrelic.com/static/e637c7eb75a9dc01740db8fecc4d85bf/1d6ec/table-new-cells.png",
+ "url": "https://developer.newrelic.com/build-apps/howto-use-nrone-table-components/",
+ "published_at": "2020-08-29T01:56:36Z",
+ "updated_at": "2020-08-14T01:46:10Z",
+ "document_type": "page",
+ "popularity": 1,
+ "info": "Add a table to your New Relic One app.",
+ "body": "Add tables to your New Relic One application 30 min Tables are a popular way of displaying data in New Relic applications. For example, with the query builder you can create tables from NRQL queries. Whether you need to have more control over tables or you're importing third-party data, you can build your own tables into your New Relic One application. In this guide, you are going to build a sample table using various New Relic One components. Before you begin If you haven't already installed the New Relic One CLI, step through the quick start in New Relic One. This process also gets you an API key. In addition, to complete the steps in this guide, you need a GitHub account, and to have Node.js installed on your machine. See [Setting up your development environment](/build-apps/set-up-dev-env) for more info. Clone and set up the example application Step 1 of 4 Clone the nr1-how-to example application from GitHub to your local machine. Then, navigate to the app directory. The example app lets you experiment with tables. git clone https://github.com/newrelic/nr1-how-to.git` cd nr1-how-to/create-a-table/nerdlets/create-a-table-nerdlet` Copy Step 2 of 4 Edit the index.json file and set this.accountId to your Account ID as shown in the example. export default class Nr1HowtoAddTimePicker extends React.Component { constructor(props){ super(props) this.accountId = YOUR_ACCOUNT_ID; } ... } Copy Step 3 of 4 Run the demo application Change the directory back to nr1-how-to/create-a-table. Before you can load the demo application, you need to update its unique id by invoking the New Relic One CLI. Once you've assigned a new UUID to the app, install the dependencies and serve the demo app locally, so that you can test any change live in your browser. nr1 nerdpack:uuid -gf # Update the app unique ID npm install # Install dependencies nr1 nerdpack:serve # Serve the demo app locally Copy Step 4 of 4 Open one.newrelic.com/?nerdpacks=local in your browser. Click Apps*, and then in the Other apps section, you should see a Create a table** launcher. That's the demo application you're going to work on. Go ahead and select it. Have a good look at the demo app. There's a TableChart on the left side named Transaction Overview, with an AreaChart next to it. You'll use Table components to add a new table in the second row. Work with table components Step 1 of 10 Navigate to the `nerdlets/create-a-table-nerdlet` subdirectory and open the `index.js` file. Add the following components to the import statement at the top of the file so that it looks like the example: Table TableHeader TableHeaderCell TableRow TableRowCell import { Table, TableHeader, TableHeaderCell, TableRow, TableRowCell, PlatformStateContext, Grid, GridItem, HeadingText, AreaChart, TableChart, } from 'nr1'; Copy Step 2 of 10 Add a basic Table component Locate the empty GridItem in index.js: This is where you start building the table. Add the initial
component. The items property collects the data by calling _getItems(), which contains sample values.
; Copy with this export code: export default class PageViewApp extends React.Component { render() { return (
); } } Copy Step 7 of 8 Customize the look of your table (optional) You can use standard CSS to customize the look of your components. In the styles.scss file, add this CSS. Feel free to customize this CSS to your taste. .container { width: 100%; height: 99vh; display: flex; flex-direction: column; .row { margin: 10px; display: flex; flex-direction: row; } .chart { height: 250px; } } Copy Step 8 of 8 Get your data into that table Now that you've got a table, you can drop a TableChart populated with data from the NRQL query you wrote at the very beginning of this guide. Put this code into the row div. ; Copy Go to New Relic One and click your app to see your data in the table. (You might need to serve your app to New Relic again.) Congratulations! You made your app! Continue on to make it interactive and show your data on a map. Make your app interactive with a text field Once you confirm that data is getting to New Relic from your app, you can start customizing it and making it interactive. To do this, you add a text field to filter your data. Later, you use a third-party library called Leaflet to show that data on a world map. Step 1 of 3 Import the TextField component Like you did with the TableChart component, you need to import a TextField component from New Relic One. import { TextField } from 'nr1'; Copy Step 2 of 3 Add a row for your text field To add a text field filter above the table, put this code above the TableChart div. The text field will have a default value of \"US\".
; Copy Step 3 of 3 Build the text field object Above the render() function, add a constructor to build the text field object. constructor(props) { super(props); this.state = { countryCode: null } } Copy Then, add a constructor to your render() function. Above return, add: const { countryCode } = this.state; Copy Now add countryCode to your table chart query. ; Copy Reload your app to try out the text field. Get your data on a map To create the map, you use npm to install Leaflet. Step 1 of 9 Install Leaflet In your terminal, type: npm install --save leaflet react-leaflet Copy In your nerdlets styles.scss file, import the Leaflet CSS: @import `~leaflet/dist/leaflet.css`; Copy While you're in styles.scss, fix the width and height of your map: .containerMap { width: 100%; z-index: 0; height: 70vh; } Copy Step 2 of 9 Add a webpack config file for Leaflet Add a webpack configuration file .extended-webpackrc.js to the top-level folder in your nerdpack. This supports your use of map tiling information data from Leaflet. module.exports = { module: { rules: [ { test: /\\.(png|jpe?g|gif)$/, use: [ { loader: 'file-loader', options: {}, }, { loader: 'url-loader', options: { limit: 25000 }, }, ], }, ], }, }; Copy Step 3 of 9 Import modules from Leaflet In index.js, import modules from Leaflet. import { Map, CircleMarker, TileLayer } from 'react-leaflet'; Copy Step 4 of 9 Import additional modules from New Relic One You need several more modules from New Relic One to make the Leaflet map work well. Import them with this code: import { NerdGraphQuery, Spinner, Button, BlockText } from 'nr1'; Copy NerdGraphQuery lets you make multiple NRQL queries at once and is what will populate the map with data. Spinner adds a loading spinner. Button gives you button components. BlockText give you block text components. Step 5 of 9 Get data for the map Using latitude and longitude with country codes, you can put New Relic data on a map. mapData() { const { countryCode } = this.state; const query = `{ actor { account(id: 1606862) { mapData: nrql(query: \"SELECT count(*) as x, average(duration) as y, sum(asnLatitude)/count(*) as lat, sum(asnLongitude)/count(*) as lng FROM PageView FACET regionCode, countryCode WHERE appName = 'WebPortal' ${countryCode ? ` WHERE countryCode like '%${countryCode}%' ` : ''} LIMIT 1000 \") { results nrql } } } }`; return query; }; Copy Step 6 of 9 Customize the map marker colors Above the mapData function, add this code to customize the map marker colors. getMarkerColor(measure, apdexTarget = 1.7) { if (measure <= apdexTarget) { return '#11A600'; } else if (measure >= apdexTarget && measure <= apdexTarget * 4) { return '#FFD966'; } else { return '#BF0016'; } }; Copy Feel free to change the HTML color code values to your taste. In this example, #11A600 is green, #FFD966 is sort of yellow, and #BF0016 is red. Step 7 of 9 Set your map's default center point Set a default center point for your map using latitude and longitude. const defaultMapCenter = [10.5731, -7.5898]; Copy Step 8 of 9 Add a row for your map Between the text field row and the table chart row, insert a new row for the map content using NerdGraphQuery.
{({ loading, error, data }) => { if (loading) { return ; } if (error) { return 'Error'; } const { results } = data.actor.account.mapData; console.debug(results); return 'Hello'; }}
; } } Copy Step 4 of 9 As an optional step, you can add a custom launcher icon using any image file named icon.png. Replace the default icon.png file under launcher by dragging in your new image file: Step 5 of 9 To change the name of the launcher to something meaningful, in your code editor under launchers, open nr1.json. Step 6 of 9 Change the value for displayName to anything you want as the launcher label, and save the file: { \"schemaType\": \"LAUNCHER\", \"id\": \"my-awesome-nerdpack-launcher\", \"description\": \"Describe me\", \"displayName\": \"INSERT_YOUR_TILE_LABEL_HERE\", \"rootNerdletId\": \"my-awesome-nerdpack-nerdlet\" } Copy Step 7 of 9 To see your new changes locally, start the Node server with this command in your terminal: npm start Copy Step 8 of 9 Open a browser and go to https://one.newrelic.com/?nerdpacks=local (this url is also shown in the terminal). Step 9 of 9 When the browser opens, click Apps, and then in the Other apps section, click the new launcher for your application. Here's an example where we inserted a leaf icon: After you click the new launcher, your \"Hello, World!\" appears: Publish your application to New Relic Your colleagues can't see your local application, so when you are ready to share it, publish it to the New Relic One catalog. The catalog is where you can find any pre-existing custom applications, as well as any applications you create in your own organization. Step 1 of 4 Execute the following in your terminal: nr1 nerdpack:publish Copy Step 2 of 4 Close your local New Relic One development tab, and open New Relic One. Step 3 of 4 Click the Apps launcher. Step 4 of 4 Under New Relic One catalog, click the launcher for your new application. When your new application opens, notice that it doesn't display any helpful descriptive information. The next section shows you how to add descriptive metadata. Add details to describe your project Now that your new application is in the New Relic One catalog, you can add details that help users understand what your application does and how to use it. Step 1 of 5 Go to your project in the terminal and execute the following: nr1 create Copy Step 2 of 5 Select catalog, which creates a stub in your project under the catalog directory. Here's how the results might look in your code editor: Step 3 of 5 In the catalog directory of your project, add screenshots or various types of metadata to describe your project. For details about what you can add, see Add catalog metadata and screenshots. Step 4 of 5 After you add the screenshots and descriptions you want, execute the following to save your metadata to the catalog: nr1 catalog:submit Copy Step 5 of 5 Return to the catalog and refresh the page to see your new screenshots and metadata describing your project. Subscribe accounts to your application To make sure other users see your application in the catalog, you need to subscribe accounts to the application. Any user with the NerdPack manager or admin role can subscribe to an application from accounts that they have permission to manage. Step 1 of 3 If you're not already displaying your application's description page in the browser, click the launcher for the application in the catalog under Your company applications. Step 2 of 3 On your application's description page, click Add this app. Step 3 of 3 Select the accounts you want to subscribe to the application, and then click Update accounts to save your selections. When you return to the Apps page, you'll see the launcher for your new application. Summary Now that you've completed the steps in this example, you learned the basic steps to: Create a local application. Publish the application to the New Relic One catalog so you can share it with your colleagues. Add details to the project in the catalog so users understand how to use it. Subscribe accounts to your application so other users can use it. Related information Create a local application. Publish the application to the New Relic One catalog so you can share it with your colleagues. Add details to the project in the catalog so users understand how to use it. Subscribe accounts to your application so other users can see it directly on their homepage.",
"_index": "520d1d5d14cc8a32e600034b",
"_type": "520d1d5d14cc8a32e600034c",
- "_score": 779.327,
+ "_score": 638.45496,
"_version": null,
"_explanation": null,
"sort": null,
"highlight": {
- "sections": "Use NerdStorage in your apps",
- "info": "Intro to NerdStorage on NewRelicOne",
- "tags": "newreliconeapps",
- "body": "Intro to NerdStorage 30 min To help you build a NewRelicOne application, we provide you with the NewRelicOneSDK. On this page, you’ll learn how to use NerdStorageSDKcomponents. Use NerdStorage in your apps NerdStorage is used to store and retrieve simple sets of data, including users"
+ "sections": "Publish your application to NewRelic",
+ "info": "Build a "Hello, World!" app and publish it to NewRelicOne",
+ "tags": "Nerdpackfilestructure",
+ "body": "!" application The CLI allows you to run a local version of NewRelicOne. You can develop your application locally before you publish it in NewRelicOne. If you followed all the steps in the CLI quick start, you now have files under a new directory named after your nerdpack project. Here's how you edit"
},
- "id": "5efa989ee7b9d2048e7bab92"
+ "id": "5efa9973196a67d16d76645c"
},
{
"sections": [
@@ -4435,7 +4346,7 @@
"external_id": "c45638a9cd548d1ffffc9f1c7708f115a92ae04a",
"image": "",
"url": "https://developer.newrelic.com/build-apps/set-up-dev-env/",
- "published_at": "2020-08-28T01:45:16Z",
+ "published_at": "2020-08-29T01:50:40Z",
"updated_at": "2020-08-26T01:47:20Z",
"document_type": "page",
"popularity": 1,
@@ -4443,104 +4354,154 @@
"body": "Set up your development environment 20 min If you've decided to build a custom app or modify one of our open source apps, you need a few essential tools: The New Relic One command line interface (CLI) An API key, which you get when you download the CLI Depending on what you want to do with your app, you might have some additional setup and configuration. This guide covers: Downloading the New Relic One CLI to build or modify apps Contribute content to this website Before you begin You must have: A github account account - While not strictly necessary for building apps, a GitHub account enables you to download and customize our open source apps, and contribute an open source project. A New Relic developer account - if you don't already have one, you can get a free trial account for developing New Relic applications. npm - If you've installed Node.js, then you already have npm, which is used to share, reuse, and update JavaScript code, and is necessary for working with React components that are the framework for New Relic apps and this website. A note on support Building a New Relic One application is the same as building any JavaScript/React application. We offer support to help with our building tools (our CLI and SDK library). However, we don't offer support for basic JavaScript or React coding questions or issues. For common questions and answers about building, see the Explorers Hub page on building on New Relic One. Tip Use the New Relic One VSCode extension to build your apps. Prepare to build or modify apps Step 1 of 1 Download the CLI and API key. On the Build New Relic One applications page, complete the Quick start steps. These six Quick start steps get you an API key for use with developing apps, and the New Relic One CLI, for building and deploying apps. At the end of the Quick start, you have a project consisting of the following: A Nerdpack - The package containing all the files required by your application. It contains two types of files that you customize to build your app: Nerdlets, and the launcher. One or more Nerdlet files - A specific UI view or window. A Nerdlet is a React JavaScript package that includes an index.js file, a stylesheet, and a JSON-format config file. It can contain any JS functionality (charts, interactive fields, tooltips, etc.). A launcher file: This is the basis for the launcher, which is used to open your application from New Relic One after you publish your app. Start building Step 1 of 1 If you're ready to code, cd to your Nerdpack and get started. If you want to learn more about building applications, try these step-by-step guides: Build a \"Hello, World!\" application shows how to create a little application, publish it to New Relic One, and share it with others by subscribing accounts to it. Map pageviews by region takes you through the steps to create one of our popular open source apps. You learn to add a custom query to an app and view it in a table, then add that data to a map. Contribute to developer.newrelic.com This site is open source, and we want your input. Create a pull request if you see a mistake you know how to fix. Drop us a GitHub issue if you see some content gaps you want us to work on. Or write up a whole new guide if you have one you'd like to share. Read on to learn how. Step 1 of 3 Fork the developer-website GithHub repo. Forking the repo enables you to work on your own copy of the developer.newrelic.com files, and build the site locally. It also enables us to more easily manage incomimg pull requests. On the developer-website page in GitHub, select the Fork button on the top right of the page, choose the account you want to fork to, and wait a few seconds while the fork is created. Sync regularly to keep your fork up to date with changes and additions to the main branch upstream. Step 2 of 3 Make a feature or documentation request. On any page, select the GitHub button at the top of the page, and then select the kind of change you want, and fill out the GitHub form. Step 3 of 3 Contribute a new guide. Check out our contributors guidelines, which will walk you through the process.",
"_index": "520d1d5d14cc8a32e600034b",
"_type": "520d1d5d14cc8a32e600034c",
- "_score": 711.45966,
+ "_score": 507.1029,
"_version": null,
"_explanation": null,
"sort": null,
"highlight": {
- "sections": "Prepare to build or modify apps",
- "info": "Prepare to build appsand contribute to this site",
- "tags": "NewRelicOne CLI",
- "body": ", publish it to NewRelicOne, and share it with others by subscribing accounts to it. Map pageviews by region takes you through the steps to create one of our popular open source apps. You learn to add a custom query to an app and view it in a table, then add that data to a map. Contribute"
+ "tags": "NewRelicOneCLI",
+ "body": ". At the end of the Quick start, you have a project consisting of the following: A Nerdpack - The package containing all the files required by your application. It contains two types of files that you customize to build your app: Nerdlets, and the launcher. One or more Nerdlet files - A specific UI view"
},
"id": "5efa9973e7b9d242237bab39"
},
{
- "category_2": "Install plugins",
- "nodeid": 3276,
"sections": [
- "Plugins for New Relic",
- "Get started",
- "Install plugins",
- "Custom dashboards and custom views",
- "Use a Plugin Central plugin",
- "View plugin dashboard details",
- "Delete a plugin",
- "For more help"
+ "Serve, publish, and deploy your New Relic One app",
+ "Before you begin",
+ "Serve your app locally",
+ "Add images and metadata to your apps",
+ "screenshots folder",
+ "documentation.md",
+ "additionalInfo.md",
+ "config.json",
+ "Publish your app",
+ "Deploy your app",
+ "Subscribe or unsubsribe apps",
+ "Handle duplicate applications"
],
- "title": "Use a Plugin Central plugin",
- "category_0": "Plugins",
- "type": "docs",
- "category_1": "Plugins for New Relic",
- "external_id": "87cd571d7a3530a85d10babe6f32ab7ad68ca788",
+ "title": "Serve, publish, and deploy your New Relic One app",
+ "type": "developer",
+ "tags": [
+ "publish apps",
+ "deploy apps",
+ "subscribe apps",
+ "add metadata apps"
+ ],
+ "external_id": "63283ee8efdfa419b6a69cb8bd135d4bc2188d2c",
+ "image": "https://developer.newrelic.com/static/f6d5070509ac08ec96c6c522d5109471/b01d9/apps_catalog.png",
+ "url": "https://developer.newrelic.com/build-apps/publish-deploy/",
+ "published_at": "2020-08-29T01:56:37Z",
+ "updated_at": "2020-08-26T01:50:42Z",
+ "document_type": "page",
+ "popularity": 1,
+ "info": "Start sharing and using the custom New Relic One apps you build",
+ "body": "Serve, publish, and deploy your New Relic One app 30 min When you build a New Relic One app, chances are you'll want to share it with others in your organization. You might even want to share it broadly through our open source channel. But first, you probably want to try it out locally to make sure it's working properly. From the New Relic One Apps page, you can review available apps and subscribe to the ones you want for accounts you manage. The Other apps section shows launchers for New Relic apps, as well as any third-party apps that you subscribe to. The New Relic One catalog provides apps that you haven't subscribed to, some developed by New Relic engineers to provide visualizations we think you'll want, like Cloud Optimizer, which analyzes your cloud environment, or PageView Map, which uses Browser events to chart performance across geographies. Other apps in the catalog are created by third-party contributors and are submitted via opensource.newrelic.com. All are intended to help you visualize the data you need, the way you want it. Here, you learn to: Serve your app locally Add images and metadata to your app Publish it Subscribe and unsubscribe accounts you manage to the app Handle duplicate applications Before you begin This guide requires the following: A New Relic One app or Nerdpack New Relic One CLI A Nerdpack manager role for publishing, deploying, and subscribing apps. Serve your app locally You can locally serve the app you create to New Relic One to test it out. Step 1 of 1 In the parent root folder of your Nerdpack, run nr1 nerdpack:serve. Go to one.newrelic.com/?nerdpacks=local. The ?nerdpacks=local URL suffix will load any locally served Nerdpacks that are available. When you make a change to a locally served Nerdpack, New Relic One will automatically reload it. Add images and metadata to your apps Application creators can include a description of what their apps do and how they're best used when they build an app. They can also include screenshots, icons, and metadata that help to make them easy to spot amongst other applications. Some metadata is added automatically when an app is published: Related entities, listed if there are any. Origin label to indicate where the app comes from: local, custom, or public. The New Relic One CLI enables you to provide the information and images you want to include with your application. Then it's a matter of kicking off a catalog command that validates the information and saves it to the catalog. Step 1 of 3 Update the New Relic One CLI to ensure you're working with the latest version. nr1 update Copy Step 2 of 3 Add catalog metadata and screenshots. Run nr1 create and then select catalog to add a catalog folder to your New Relic One project. The folder contains the following empty files and folder. Add the information as described in the following table for the process to succeed. screenshots folder A directory that must contain no more than 6 images and meet these criteria: 3:2 aspect ratio PNG format landscape orientation 1600 to 2400 pixels wide documentation.md A markdown file that presents usage information pulled into the Documentation tab for the application in the catalog. additionalInfo.md An optional markdown file for any additional information about using your application. config.json A JSON file that contains the following fields: tagline: A brief headline for the application. Must not exceed 30 characters. repository: The URL to the GitHub repo for the application. Must not exceed 1000 characters. details: Describes the purpose of the application and how to use it. Information must not exceed 1000. Use carriage returns for formatting. Do not include any markdown or HTML. support: An object that contains: issues: A valid URL to the GitHub repository's issues list, generally the GitHub Issues tab for the repo. email: A valid email address for the team supporting the application. community: URL to a support thread, forum, or website for troubleshooting and usage support. whatsNew: A bulleted list of changes in this version. Must not exceed 500 characters. Use carriage returns for formatting. Do not include markdown or HTML. Example: { \"tagline\": \"Map your workloads & entities\", \"repository\": \"https://github.com/newrelic/nr1-workload-geoops.git\", \"details\": \"Describe, consume, and manage Workloads and Entities in a geographic model that supports location-specific KPI's, custom metadata, drill-down navigation into Entities and Workloads, real-time configuration, and configuration via automation using the newrelic-cli.\", \"support\": { \"issues\": { \"url\": \"https://github.com/newrelic/nr1-workload-geoops/issues\" }, \"email\": { \"address\": \"opensource+nr1-workload-geoops@newrelic.com\" }, \"community\": { \"url\": \"https://discuss.newrelic.com/t/workload-geoops-nerdpack/99478\" } }, \"whatsNew\": \"\\n-Feat: Geographic mapping of Workloads and Entities\\n-Feat: Programmatic alerting rollup of underlying Entities\\n-Feat: Custom KPI measurement per location\\n-Feat: Empty-state edit workflow\\n-Feat: JSON file upload format\\n-Feat: Published (in open source docs) guide to automating configuration using the newrelic-cli\" } Copy Step 3 of 3 Save the metadata and screenshots to the catalog. This validates the information you added to the catalog directory against the criteria described in the previous step, and saves it to the catalog. nr1 catalog:submit Copy Publish your app Publishing places your Nerdpack in New Relic One. To publish or deploy, you must be a Nerdpack manager. Step 1 of 1 To publish your Nerdpack, run nr1 nerdpack:publish. Deploy your app Deploying is applying a Nerdpack version to a specific channel (for example, BETA, or STABLE). A channel can only have one Nerdpack version deployed to it at one time. If a channel has an existing Nerdpack associated with it, deploying a new Nerdpack version to that channel will undeploy the previous one. Channels are meant to be an easier way to control application version access than having to be concerned with specific version numbers. Step 1 of 1 To deploy an application, run nr1 nerdpack:deploy. Subscribe or unsubsribe apps Whether you want to subscribe accounts to an app you've created or to apps already available in the catalog, the process is the same. Note that if you subscribe to an app in the catalog, you'll automatically get any updates that are added to the app. To learn about the appropriate permissions for subscribing, see Permissions for managing applications. Step 1 of 2 Subscribe accounts to an application. Select an application you want to add to your New Relic account. Click Add this app. Note that this button says Manage access if the app has already been subscribed to an account you manage. On the Account access page listing the accounts you can subscribe to an application: Select the accounts you want to subscribe the app to. Choose the channel you want to subscribe the app to, Stable or Dev. This can only be Stable for the public apps created by New Relic. Click the update button. Now you and members of the accounts you have subscribed to the app can launch it from New Relic One. Step 2 of 2 Unsubsribe from an application. On the Apps page, open the app you want to unsubscribe. Click Manage access. Clear the check box for any accounts you want to unsubscribe, and then click the update button. The application is no longer listed in the Other apps section of the Apps page, and you have unsubscribed. Handle duplicate applications You might end up with duplicate applications on your New Relic One Apps page. This can happen when you subscribe to the same app using both the CLI and the catalog. Or if you clone an app, modify, and deploy it, but keep the original name. You can manage duplicates with the catalog. Good to know before you start: You need a user role with the ability to manage Nerdpacks for accounts that you want to unsubscribe and undeploy from applications. You can't remove the public apps. When a duplicate application has no accounts subscribed to it, you undeploy it. For applications that have accounts subscribed to them, you unscubscribe and undeploy. The unsubscribe and undeploy process happens in a batch. To remove an account from an application, but ensure that other accounts continue to be subscribed, select the checkbox, Resubscribe these accounts to the new application. Step 1 of 1 Remove duplicates. In the New Relic One catalog, click a public application that has one or more duplicates. (You can only manage duplicates from the public version of the application.) On the application information page, select Clean up applications. Review the information about the application that's open, as well as any duplicates. Click Manage app for duplicates you want to remove. If needed, select Resubscribe these accounts to the new application. Click Unsubscribe and undeploy, and agree to the terms and conditions.",
+ "_index": "520d1d5d14cc8a32e600034b",
+ "_type": "520d1d5d14cc8a32e600034c",
+ "_score": 445.62674,
+ "_version": null,
+ "_explanation": null,
+ "sort": null,
+ "highlight": {
+ "title": "Serve, publish, and deploy your NewRelicOne app",
+ "sections": "Serve, publish, and deploy your NewRelicOne app",
+ "info": "Start sharing and using the custom NewRelicOne apps you build",
+ "body": " to the app Handle duplicate applications Before you begin This guide requires the following: A NewRelicOne app or NerdpackNewRelicOneCLI A Nerdpack manager role for publishing, deploying, and subscribing apps. Serve your app locally You can locally serve the app you create to NewRelicOne to test"
+ },
+ "id": "5efa999de7b9d283e67bab8f"
+ },
+ {
"image": "",
- "url": "https://docs.newrelic.com/docs/plugins/plugins-new-relic/install-plugins/use-plugin-central-plugin",
- "published_at": "2020-08-26T21:57:16Z",
- "updated_at": "2020-08-20T06:46:42Z",
- "breadcrumb": "Contents / Plugins / Plugins for New Relic / Install plugins",
+ "url": "https://developer.newrelic.com/explore-docs/nr1-common/",
+ "sections": [
+ "New Relic One CLI common commands",
+ "Command details",
+ "nr1 help",
+ "See commands and get details",
+ "Usage",
+ "Arguments",
+ "Examples",
+ "nr1 update",
+ "Update your CLI",
+ "nr1 create",
+ "Create a new component",
+ "Options",
+ "nr1 profiles",
+ "Manage your profiles keychain",
+ "Commands",
+ "nr1 autocomplete",
+ "See autocomplete installation instructions",
+ "nr1 nrql",
+ "Query using NRQL"
+ ],
+ "published_at": "2020-08-29T01:58:05Z",
+ "title": "New Relic One CLI common commands",
+ "updated_at": "2020-08-14T01:48:10Z",
+ "type": "developer",
+ "external_id": "503e515e1095418f8d19329517344ab209d143a4",
"document_type": "page",
"popularity": 1,
- "info": "How to navigate the user interface for plugins you install from Plugin Central in New Relic One.",
- "body": "For an even better experience than plugins, go to: newrelic.com/integrations: Integrate the on-host and cloud systems you already use with New Relic, so you can filter and analyze data, create dashboards, and set alerts within a single platform. developer.newrelic.com: Use developer tools to collect data from any source, automate workflows, build apps, and use our APIs. Each plugin in Plugin Central includes procedures for how to install, use, troubleshoot, and uninstall it. After you install a plugin, it starts to receive data, usually within five minutes. The plugin automatically appears with a short name and icon on your Plugins menu in New Relic One. You do not need to select it from Plugin Central. Plugins in Plugin Central are not supported with accounts that host data in the EU region data center. View plugin dashboard details The amount and types of information on the plugin's summary page and dashboards depend on the specific plugin. For example, a plugin may have one or more components (instances) and one or more dashboards. To view summary and dashboard details about the plugin: Go to one.newrelic.com > More > Plugins, and select your plugin. From the plugin's summary page, review the list of components or instances, summary metrics, and list of Recent Events. To view dashboard details about any component or instance, select its name. Plugin summary Depending on the plugin, the summary includes: One or more components or instances (what the plugin agent is monitoring, typically a host/port pair) Zero to five summary metrics for the past three minutes (values such as average, total, minimum, maximum, standard deviation, rate, or count) with optional alerts Recent events list, including deployments, notifications, and alerts Other information about alert violations, events, and activity If your plugin has 100 or more components or instances, you can search for a specific component instance. Here is a summary of additional standard features. If you want to... Do this... View version information for a component's or instance's agent Mouse over the component's name. Change the sort order On the title row of the plugin's summary page, select the up or down arrow for a component (instance) or a summary metric's label. Show or hide items on the events and activity list Select an event icon, or select All. View details about an event On the events and activity list, select the link. View page details for a component or instance Select the name or a summary metric for the component (instance). Plugin dashboards Depending on the plugin, it may have one or more dashboards, and each dashboard may present data as a chart or a table. You can use any of New Relic's standard dashboard features to drill down into detailed information. The customized dashboards that show plugin data are part of the plugin. Users cannot add or remove these dashboards. This must be done by the author or publisher as part of a plugin update. Plugin alerts If the plugin publisher set Critical (red) or Caution (yellow) alert conditions for your plugin's components or instances, you can view details direct in the user interface. For example, you can: Select and view alert details. Change the existing thresholds. Set your alert notification options; for example, to receive email notifications for Critical events. Delete a plugin Each plugin in Plugin Central includes procedures for how to uninstall it. When you select the plugin's Download or Continue button, the plugin should include a README file or refer to other documentation resources. Remove plugin components (instances) At a minimum, your plugin must stop reporting data before you start uninstalling it. Make sure the health status for your plugin's components (instances) are gray. Depending on the plugin, there may be other dependencies before disabling or uninstalling it. For example, plugins from SaaS providers may have different requirements. Be sure to review the instructions that the plugin's publisher provides. Then, to remove individual components from your plugin, click the settings settings icon for each component (instance). Delete the plugin After you remove each component (instance) for the plugin, the plugin icon will automatically disappear from your Plugins menu in the New Relic UI. You do not need to do anything else to delete the plugin. If you are the plugin's publisher and need to delete the plugin from Plugin Central, go to support.newrelic.com. For more help If you need more help, check out these support and learning resources: Review the documentation provided by the plugin publisher, or contact the publisher's support resources (identified in the plugin's Get support link). Browse the Explorers Hub to get help from the community and join in discussions. Find answers on our sites and learn how to use our support portal. Run New Relic Diagnostics, our troubleshooting tool for Linux, Windows, and macOS. Review New Relic's data security and licenses documentation.",
+ "info": "An overview of common commands you can use with the New Relic One CLI.",
+ "body": "New Relic One CLI common commands Here's a list of common commands to get you started with the New Relic One CLI. You can click any command to see its usage options and additional details about the command. Command Description nr1 help Shows all nr1 commands or details about each command. nr1 update Updates to the latest version of the CLI. nr1 create Creates a new component from a template (Nerdpack, Nerdlet, launcher, or catalog). nr1 profiles Manages the profiles you use to run CLI commands. nr1 autocomplete Displays autocomplete installation instructions. nr1 nrql Fetches data using NRQL (New Relic query language). See our other New Relic One CLI docs for commands specific to Nerdpack set-up, Nerdpack subscriptions, CLI configuration, plugins, or catalogs. Command details nr1 help See commands and get details Shows all nr1 commands by default. To get details about a specific command, run nr1 help COMMAND_NAME. Usage $ nr1 help Arguments COMMAND_NAME The name of a particular command. Examples $ nr1 help $ nr1 help nerdpack $ nr1 help nerdpack:deploy nr1 update Update your CLI Updates to latest version of the CLI. You can specify which channel to update if you'd like. Usage $ nr1 update Arguments CHANNEL The name of a particular channel. Examples $ nr1 update $ nr1 update somechannel nr1 create Create a new component Creates a new component from our template (either a Nerdpack, Nerdlet, launcher, or catalog). The CLI will walk you through this process. To learn more about Nerdpacks and their file structure, see Nerdpack file structure. For more on how to set up your Nerdpacks, see our Nerdpack CLI commands. Usage $ nr1 create Options -f, --force If present, overrides existing files without asking. -n, --name=NAME Names the component. -t, --type=TYPE Specifies the component type. --path=PATH The route to the component. --profile=PROFILE The authentication profile you want to use. --verbose Adds extra information to the output. nr1 profiles Manage your profiles keychain Displays a list of commands you can use to manage your profiles. Run nr1 help profiles:COMMAND for more on their specific usages. You can have more than one profile, which is helpful for executing commands on multiple New Relic accounts. To learn more about setting up profiles, see our Github workshop. Usage $ nr1 profiles:COMMAND Commands profiles:add Adds a new profile to your profiles keychain. profiles:default Chooses which profile should be default. profiles:list Lists the profiles on your keychain. profiles:remove Removes a profile from your keychain. nr1 autocomplete See autocomplete installation instructions Displays the autocomplete installation instructions. By default, the command displays the autocomplete instructions for zsh. If you want instructions for bash, run nr1 autocomplete bash. Usage $ nr1 autocomplete Arguments SHELL The shell type you want instructions for. Options -r, --refresh-cache Refreshes cache (ignores displaying instructions). Examples $ nr1 autocomplete $ nr1 autocomplete zsh $ nr1 autocomplete bash $ nr1 autocomplete --refresh-cache nr1 nrql Query using NRQL Fetches data from databases using a NRQL query. To learn more about NRQL and how to use it, see our NRQL docs. Usage $ nr1 nrql OPTION ... Options -a, --account=ACCOUNT The user account ID. required -q, --query=QUERY The NRQL query to run. required -u, --ugly Displays the content without tabs or spaces. --profile=PROFILE The authentication profile you want to use. --verbose Adds extra information to the output.",
"_index": "520d1d5d14cc8a32e600034b",
"_type": "520d1d5d14cc8a32e600034c",
- "_score": 623.41144,
+ "_score": 380.46973,
"_version": null,
"_explanation": null,
"sort": null,
"highlight": {
- "sections": "Plugins for NewRelic",
- "info": "How to navigate the user interface for plugins you install from Plugin Central in NewRelicOne.",
- "category_1": "Plugins for NewRelic",
- "body": "For an even better experience than plugins, go to: newrelic.com/integrations: Integrate the on-host and cloud systems you already use with NewRelic, so you can filter and analyze data, create dashboards, and set alerts within a single platform. developer.newrelic.com: Use developer tools",
- "breadcrumb": "Contents / Plugins / Plugins for NewRelic / Install plugins"
+ "title": "NewRelicOneCLI common commands",
+ "sections": "NewRelicOneCLI common commands",
+ "info": "An overview of common commands you can use with the NewRelicOneCLI.",
+ "body": " update Updates to the latest version of the CLI. nr1 create Creates a new component from a template (Nerdpack, Nerdlet, launcher, or catalog). nr1 profiles Manages the profiles you use to run CLI commands. nr1 autocomplete Displays autocomplete installation instructions. nr1 nrql Fetches data using NRQL"
},
- "id": "5f2ef9b3196a67c2a0fbd721"
+ "id": "5f28bd6ae7b9d267996ade94"
},
{
"sections": [
- "Add tables to your New Relic One application",
- "Before you begin",
- "Clone and set up the example application",
- "Work with table components",
- "Next steps"
+ "New Relic One CLI reference",
+ "Installing the New Relic One CLI",
+ "Tip",
+ "New Relic One CLI Commands",
+ "Get started",
+ "Configure your CLI preferences",
+ "Set up your Nerdpacks",
+ "Manage your Nerdpack subscriptions",
+ "Install and manage plugins",
+ "Manage catalog information"
],
- "title": "Add tables to your New Relic One application",
+ "title": "New Relic One CLI reference",
"type": "developer",
"tags": [
- "table in app",
- "Table component",
- "TableHeaderc omponent",
- "TableHeaderCell component",
- "TableRow component",
- "TableRowCell component"
+ "New Relic One app",
+ "nerdpack commands"
],
- "external_id": "7ff7a8426eb1758a08ec360835d9085fae829936",
- "image": "https://developer.newrelic.com/static/e637c7eb75a9dc01740db8fecc4d85bf/1d6ec/table-new-cells.png",
- "url": "https://developer.newrelic.com/build-apps/howto-use-nrone-table-components/",
- "published_at": "2020-08-28T01:51:51Z",
- "updated_at": "2020-08-14T01:46:10Z",
+ "external_id": "858339a44ead21c83257778ce60b4c352cd30d3b",
+ "image": "https://developer.newrelic.com/static/2c6d337608b38a3312b4fc740afe6167/7272b/developercenter.png",
+ "url": "https://developer.newrelic.com/explore-docs/nr1-cli/",
+ "published_at": "2020-08-29T01:58:45Z",
+ "updated_at": "2020-08-18T01:50:36Z",
"document_type": "page",
"popularity": 1,
- "info": "Add a table to your New Relic One app.",
- "body": "Add tables to your New Relic One application 30 min Tables are a popular way of displaying data in New Relic applications. For example, with the query builder you can create tables from NRQL queries. Whether you need to have more control over tables or you're importing third-party data, you can build your own tables into your New Relic One application. In this guide, you are going to build a sample table using various New Relic One components. Before you begin If you haven't already installed the New Relic One CLI, step through the quick start in New Relic One. This process also gets you an API key. In addition, to complete the steps in this guide, you need a GitHub account, and to have Node.js installed on your machine. See [Setting up your development environment](/build-apps/set-up-dev-env) for more info. Clone and set up the example application Step 1 of 4 Clone the nr1-how-to example application from GitHub to your local machine. Then, navigate to the app directory. The example app lets you experiment with tables. git clone https://github.com/newrelic/nr1-how-to.git` cd nr1-how-to/create-a-table/nerdlets/create-a-table-nerdlet` Copy Step 2 of 4 Edit the index.json file and set this.accountId to your Account ID as shown in the example. export default class Nr1HowtoAddTimePicker extends React.Component { constructor(props){ super(props) this.accountId = YOUR_ACCOUNT_ID; } ... } Copy Step 3 of 4 Run the demo application Change the directory back to nr1-how-to/create-a-table. Before you can load the demo application, you need to update its unique id by invoking the New Relic One CLI. Once you've assigned a new UUID to the app, install the dependencies and serve the demo app locally, so that you can test any change live in your browser. nr1 nerdpack:uuid -gf # Update the app unique ID npm install # Install dependencies nr1 nerdpack:serve # Serve the demo app locally Copy Step 4 of 4 Open one.newrelic.com/?nerdpacks=local in your browser. Click Apps*, and then in the Other apps section, you should see a Create a table** launcher. That's the demo application you're going to work on. Go ahead and select it. Have a good look at the demo app. There's a TableChart on the left side named Transaction Overview, with an AreaChart next to it. You'll use Table components to add a new table in the second row. Work with table components Step 1 of 10 Navigate to the `nerdlets/create-a-table-nerdlet` subdirectory and open the `index.js` file. Add the following components to the import statement at the top of the file so that it looks like the example: Table TableHeader TableHeaderCell TableRow TableRowCell import { Table, TableHeader, TableHeaderCell, TableRow, TableRowCell, PlatformStateContext, Grid, GridItem, HeadingText, AreaChart, TableChart, } from 'nr1'; Copy Step 2 of 10 Add a basic Table component Locate the empty GridItem in index.js: This is where you start building the table. Add the initial
component. The items property collects the data by calling _getItems(), which contains sample values.
; } } Copy nr1.json The Nerdlet configuration file. { \"schemaType\": \"NERDLET\", \"id\": \"my-awesome-nerdpack-nerdlet\", \"description\": \"Describe me\", \"displayName\": \"MyAwesomeNerdpack\" } Copy Besides using the launcher as the access point for your application, you can also associate the application with a monitored entity to get it to appear in the entity explorer. To do this, add two additional fields to the config file of the first-launched Nerdlet: entities and actionCategory. In the following example, the Nerdlet has been associated with all Browser-monitored applications and will appear under the Monitor UI category : { \"schemaType\": \"NERDLET\", \"id\": \"my-nerdlet\", \"description\": \"Describe me\", \"displayName\": \"Custom Data\", \"entities\": [{ \"domain\": \"BROWSER\", \"type\": \"APPLICATION\" }], \"actionCategory\": \"monitor\" } Copy To see this application in the UI, you would go to the entity explorer, select Browser applications, and select a monitored application. styles.scss An empty SCSS file for styling your application. icon.png The launcher icon that appears on the Apps page in New Relic One when an application is deployed. Launcher file structure Launchers have their own file structure. Note that: A launcher is not required; as an alternative to using a launcher, you can associate your application with a monitored entity. An application can have more than one launcher, which might be desired for an application with multiple Nerdlets. After generating a launcher using the nr1 create command, its folder contains two files: nr1.json The configuration file. { \"schemaType\": \"LAUNCHER\", \"id\": \"my-awesome-nerdpack-launcher\", \"description\": \"Describe me\", \"displayName\": \"MyAwesomeNerdpack\", \"rootNerdletId\": \"my-awesome-nerdpack-nerdlet\" } Copy To connect a launcher to a Nerdlet, the rootNerdletId must match the id in the launched Nerdlet's nr1.json config file. For Nerdpacks with multiple Nerdlets, this needs to be done only for the first-launched Nerdlet. icon.png The icon displayed on the launcher for the app on the Apps page.",
+ "_index": "520d1d5d14cc8a32e600034b",
+ "_type": "520d1d5d14cc8a32e600034c",
+ "_score": 243.22112,
+ "_version": null,
+ "_explanation": null,
+ "sort": null,
+ "highlight": {
+ "title": "Nerdpackfilestructure",
+ "sections": "Nerdpackfilestructure",
+ "info": "An overview of the NerdpackFileStructure",
+ "tags": "filestructure",
+ "body": " components, see our app building guides and the New Relic OneCLI command reference. Nerdpackfilestructure When you generate a Nerdpack template using the nr1 create command, it has the following filestructure: my-nerdlet ├── README.md ├── launchers │ └── my-nerdlet-launcher │ ├── icon.png"
+ },
+ "id": "5efa989e196a671300766404"
+ },
+ {
+ "image": "",
+ "url": "https://developer.newrelic.com/explore-docs/nr1-common/",
+ "sections": [
+ "New Relic One CLI common commands",
+ "Command details",
+ "nr1 help",
+ "See commands and get details",
+ "Usage",
+ "Arguments",
+ "Examples",
+ "nr1 update",
+ "Update your CLI",
+ "nr1 create",
+ "Create a new component",
+ "Options",
+ "nr1 profiles",
+ "Manage your profiles keychain",
+ "Commands",
+ "nr1 autocomplete",
+ "See autocomplete installation instructions",
+ "nr1 nrql",
+ "Query using NRQL"
+ ],
+ "published_at": "2020-08-29T01:58:05Z",
+ "title": "New Relic One CLI common commands",
+ "updated_at": "2020-08-14T01:48:10Z",
+ "type": "developer",
+ "external_id": "503e515e1095418f8d19329517344ab209d143a4",
+ "document_type": "page",
+ "popularity": 1,
+ "info": "An overview of common commands you can use with the New Relic One CLI.",
+ "body": "New Relic One CLI common commands Here's a list of common commands to get you started with the New Relic One CLI. You can click any command to see its usage options and additional details about the command. Command Description nr1 help Shows all nr1 commands or details about each command. nr1 update Updates to the latest version of the CLI. nr1 create Creates a new component from a template (Nerdpack, Nerdlet, launcher, or catalog). nr1 profiles Manages the profiles you use to run CLI commands. nr1 autocomplete Displays autocomplete installation instructions. nr1 nrql Fetches data using NRQL (New Relic query language). See our other New Relic One CLI docs for commands specific to Nerdpack set-up, Nerdpack subscriptions, CLI configuration, plugins, or catalogs. Command details nr1 help See commands and get details Shows all nr1 commands by default. To get details about a specific command, run nr1 help COMMAND_NAME. Usage $ nr1 help Arguments COMMAND_NAME The name of a particular command. Examples $ nr1 help $ nr1 help nerdpack $ nr1 help nerdpack:deploy nr1 update Update your CLI Updates to latest version of the CLI. You can specify which channel to update if you'd like. Usage $ nr1 update Arguments CHANNEL The name of a particular channel. Examples $ nr1 update $ nr1 update somechannel nr1 create Create a new component Creates a new component from our template (either a Nerdpack, Nerdlet, launcher, or catalog). The CLI will walk you through this process. To learn more about Nerdpacks and their file structure, see Nerdpack file structure. For more on how to set up your Nerdpacks, see our Nerdpack CLI commands. Usage $ nr1 create Options -f, --force If present, overrides existing files without asking. -n, --name=NAME Names the component. -t, --type=TYPE Specifies the component type. --path=PATH The route to the component. --profile=PROFILE The authentication profile you want to use. --verbose Adds extra information to the output. nr1 profiles Manage your profiles keychain Displays a list of commands you can use to manage your profiles. Run nr1 help profiles:COMMAND for more on their specific usages. You can have more than one profile, which is helpful for executing commands on multiple New Relic accounts. To learn more about setting up profiles, see our Github workshop. Usage $ nr1 profiles:COMMAND Commands profiles:add Adds a new profile to your profiles keychain. profiles:default Chooses which profile should be default. profiles:list Lists the profiles on your keychain. profiles:remove Removes a profile from your keychain. nr1 autocomplete See autocomplete installation instructions Displays the autocomplete installation instructions. By default, the command displays the autocomplete instructions for zsh. If you want instructions for bash, run nr1 autocomplete bash. Usage $ nr1 autocomplete Arguments SHELL The shell type you want instructions for. Options -r, --refresh-cache Refreshes cache (ignores displaying instructions). Examples $ nr1 autocomplete $ nr1 autocomplete zsh $ nr1 autocomplete bash $ nr1 autocomplete --refresh-cache nr1 nrql Query using NRQL Fetches data from databases using a NRQL query. To learn more about NRQL and how to use it, see our NRQL docs. Usage $ nr1 nrql OPTION ... Options -a, --account=ACCOUNT The user account ID. required -q, --query=QUERY The NRQL query to run. required -u, --ugly Displays the content without tabs or spaces. --profile=PROFILE The authentication profile you want to use. --verbose Adds extra information to the output.",
+ "_index": "520d1d5d14cc8a32e600034b",
+ "_type": "520d1d5d14cc8a32e600034c",
+ "_score": 207.20837,
+ "_version": null,
+ "_explanation": null,
+ "sort": null,
+ "highlight": {
+ "title": "New Relic OneCLI common commands",
+ "sections": "New Relic OneCLI common commands",
+ "info": "An overview of common commands you can use with the New Relic OneCLI.",
+ "body": " Nerdpacks and their filestructure, see Nerdpackfilestructure. For more on how to set up your Nerdpacks, see our NerdpackCLI commands. Usage $ nr1 create Options -f, --force If present, overrides existing files without asking. -n, --name=NAME Names the component. -t, --type=TYPE Specifies"
+ },
+ "id": "5f28bd6ae7b9d267996ade94"
+ },
+ {
+ "sections": [
+ "Permissions for managing applications",
+ "New Relic One pricing plan",
+ "Original product-based pricing",
+ "About versions"
+ ],
+ "title": "Permissions for managing applications",
+ "type": "developer",
+ "tags": [
+ "nerdpack manager",
+ "permissions",
+ "managing apps"
+ ],
+ "external_id": "c7f4c7fbd9d093d303c7f8268f8560ff9f435230",
+ "image": "",
+ "url": "https://developer.newrelic.com/build-apps/permission-manage-apps/",
+ "published_at": "2020-08-29T01:54:46Z",
+ "updated_at": "2020-08-26T01:47:20Z",
+ "document_type": "page",
+ "popularity": 1,
+ "info": "Learn about permissions for subscribing to apps",
+ "body": "Permissions for managing applications When you create an app, you'll likely want to share it. From New Relic One's Apps page, you can subscribe to apps you create, publish, and deploy, and to other publicly available apps. You must have the Nerdpack manager role to subcribe accounts to apps. Read on to learn about permissions and versions. Permissions for managing applications The Nerdpack manager role is a New Relic add-on role. When you create a Nerdpack, you have the Nerdpack manager role for handling that Nerdpack. New Relic account administrators have the Nerdpack manager role automatically, and can subscribe their accounts to available Nerdpacks. User permissions vary depending on which pricing plan you are on. New Relic One pricing plan For accounts with New Relic One pricing, there are permissions differences for basic users and full users: Full users have the Nerdpack manager role and have full capabilities for creating and managing New Relic One applications, as well as accessing all types of applications in the New Relic One catalog. A basic user can develop and view their own local New Relic One apps, but they cannot: Subscribe other users to apps they’ve created. Access or manage apps in the New Relic One catalog. Access apps in the entity explorer sidebar. Original product-based pricing For accounts on our original product-based pricing, here are access details: Subscribe to publicly available applications To subscribe to publicly available applications, you must have the Nerdpack manager role. Nerdpack manager permissions are automatically assigned to New Relic account owners and admins and can be assigned to individual users. If you aren’t an owner or admin, you can request Nerdpack manager permission, or ask your New Relic admin or owner to subscribe the apps to your account for you. You can add any of the publicly available applications to master accounts or separate sub-accounts on which you have the Nerdpack manager role, or to separate sub-accounts under a master account you own or administer. If you add the application to a master account, the access flows to all of its sub-accounts as well. Subscribe to applications that you create You also must have the Nerdpack manager role to subscribe the applications you create to accounts. Applications that you publish and deploy can only be subscribed to the master account that was used to publish them, or to its sub-accounts. This means you might want a New Relic admin to deploy your applications for you if they need to be available across the organization. About versions New Relic One requires that only one version (following semantic versioning) of a Nerdpack can be published. Thus, the nr1 nerdpack:publish command requires the following: The Nerdpack manager role A unique version as specified in the version attribute found in the app's package.json.",
"_index": "520d1d5d14cc8a32e600034b",
"_type": "520d1d5d14cc8a32e600034c",
- "_score": 67.448074,
+ "_score": 168.2799,
"_version": null,
"_explanation": null,
"sort": null,
"highlight": {
- "sections": "Event definitions and attributes",
- "body": ". Spans are used for distributed tracing. Distributed tracing relies on data sampling; 10% of invocations are sampled to generate spans. Customevent types: With some agentAPIs, customevents can be created and associated with a particular Lambda invocation, and then queried with NRQL. For more"
+ "title": "Permissions for managing applications",
+ "sections": "Permissions for managing applications",
+ "info": "Learn about permissions for subscribing to apps",
+ "tags": "nerdpack manager",
+ "body": "Permissions for managing applications When you create an app, you'll likely want to share it. From New Relic One's Apps page, you can subscribe to apps you create, publish, and deploy, and to other publicly available apps. You must have the Nerdpack manager role to subcribe accounts to apps. Read"
},
- "id": "5ce2ef6f0711e86fccbf7939"
- }
- ],
- "/explore-docs/nerdpack-file-structure": [
+ "id": "5f45bf2864441ffb4dfdcdbb"
+ },
{
"sections": [
- "Create a \"Hello, World!\" application",
+ "Map page views by region in a custom app",
"Before you begin",
- "Tip",
- "Create a local version of the \"Hello, World!\" application",
- "Publish your application to New Relic",
- "Add details to describe your project",
- "Subscribe accounts to your application",
- "Summary",
- "Related information"
+ "New Relic terminology",
+ "Build a custom app with a table chart",
+ "Query your browser data",
+ "Create and serve a new Nerdpack",
+ "Review your app files and view your app locally",
+ "Hard code your account ID",
+ "Import the TableChart component",
+ "Add a table with a single row",
+ "Customize the look of your table (optional)",
+ "Get your data into that table",
+ "Make your app interactive with a text field",
+ "Import the TextField component",
+ "Add a row for your text field",
+ "Build the text field object",
+ "Get your data on a map",
+ "Install Leaflet",
+ "Add a webpack config file for Leaflet",
+ "Import modules from Leaflet",
+ "Import additional modules from New Relic One",
+ "Get data for the map",
+ "Customize the map marker colors",
+ "Set your map's default center point",
+ "Add a row for your map",
+ "Replace \"Hello\" with the Leaflet code"
],
- "title": "Create a \"Hello, World!\" application",
+ "title": "Map page views by region in a custom app",
"type": "developer",
"tags": [
- "nr1 cli",
- "Nerdpack file structure",
- "NR One Catalog",
- "Subscribe applications"
+ "custom app",
+ "map",
+ "page views",
+ "region",
+ "nerdpack"
],
- "external_id": "aa427030169067481fb69a3560798265b6b52b7c",
- "image": "https://developer.newrelic.com/static/cb65a35ad6fa52f5245359ecd24158ff/9466d/hello-world-output-local.png",
- "url": "https://developer.newrelic.com/build-apps/build-hello-world-app/",
- "published_at": "2020-08-28T01:46:14Z",
- "updated_at": "2020-08-21T01:45:19Z",
+ "external_id": "6ff5d696556512bb8d8b33fb31732f22bab455cb",
+ "image": "https://developer.newrelic.com/static/d87a72e8ee14c52fdfcb91895567d268/0086b/pageview.png",
+ "url": "https://developer.newrelic.com/build-apps/map-pageviews-by-region/",
+ "published_at": "2020-08-29T01:57:13Z",
+ "updated_at": "2020-08-14T01:45:09Z",
"document_type": "page",
"popularity": 1,
- "info": "Build a \"Hello, World!\" app and publish it to New Relic One",
- "body": "Create a \"Hello, World!\" application 15 min Here's how you can quickly build a \"Hello, World!\" application in New Relic One. In these steps, you create a local version of the New Relic One site where you can prototype your application. Then, when you're ready to share the application with others, you can publish it to New Relic One. See the video, which demonstrates the steps in this guide in five minutes. Before you begin To get started, make sure you have accounts in GitHub and New Relic. To develop projects, you need the New Relic One CLI (command line interface). If you haven't already installed it, do the following: Install Node.js. Complete all the steps in the CLI quick start. For additional details about setting up your environment, see Set up your development environment. Tip Use the NR1 VS Code extension to build your apps. Create a local version of the \"Hello, World!\" application The CLI allows you to run a local version of New Relic One. You can develop your application locally before you publish it in New Relic One. If you followed all the steps in the CLI quick start, you now have files under a new directory named after your nerdpack project. Here's how you edit those files to create a \"Hello, World!\" project: Step 1 of 9 Open a code editor and point it to the new directory named after your nerdpack project (for example, my-awesome-nerdpack). Your code editor displays two artifacts: launchers containing the homepage tile nerdlets containing your application code Step 2 of 9 Expand nerdlets in your code editor, and open index.js. Step 3 of 9 Change the default return message to \"Hello, World!\": import React from 'react'; // https://docs.newrelic.com/docs/new-relic-programmable-platform-introduction export default class MyAwesomeNerdpackNerdletNerdlet extends React.Component { render() { return
\"Hello, World!\"
; } } Copy Step 4 of 9 As an optional step, you can add a custom launcher icon using any image file named icon.png. Replace the default icon.png file under launcher by dragging in your new image file: Step 5 of 9 To change the name of the launcher to something meaningful, in your code editor under launchers, open nr1.json. Step 6 of 9 Change the value for displayName to anything you want as the launcher label, and save the file: { \"schemaType\": \"LAUNCHER\", \"id\": \"my-awesome-nerdpack-launcher\", \"description\": \"Describe me\", \"displayName\": \"INSERT_YOUR_TILE_LABEL_HERE\", \"rootNerdletId\": \"my-awesome-nerdpack-nerdlet\" } Copy Step 7 of 9 To see your new changes locally, start the Node server with this command in your terminal: npm start Copy Step 8 of 9 Open a browser and go to https://one.newrelic.com/?nerdpacks=local (this url is also shown in the terminal). Step 9 of 9 When the browser opens, click Apps, and then in the Other apps section, click the new launcher for your application. Here's an example where we inserted a leaf icon: After you click the new launcher, your \"Hello, World!\" appears: Publish your application to New Relic Your colleagues can't see your local application, so when you are ready to share it, publish it to the New Relic One catalog. The catalog is where you can find any pre-existing custom applications, as well as any applications you create in your own organization. Step 1 of 4 Execute the following in your terminal: nr1 nerdpack:publish Copy Step 2 of 4 Close your local New Relic One development tab, and open New Relic One. Step 3 of 4 Click the Apps launcher. Step 4 of 4 Under New Relic One catalog, click the launcher for your new application. When your new application opens, notice that it doesn't display any helpful descriptive information. The next section shows you how to add descriptive metadata. Add details to describe your project Now that your new application is in the New Relic One catalog, you can add details that help users understand what your application does and how to use it. Step 1 of 5 Go to your project in the terminal and execute the following: nr1 create Copy Step 2 of 5 Select catalog, which creates a stub in your project under the catalog directory. Here's how the results might look in your code editor: Step 3 of 5 In the catalog directory of your project, add screenshots or various types of metadata to describe your project. For details about what you can add, see Add catalog metadata and screenshots. Step 4 of 5 After you add the screenshots and descriptions you want, execute the following to save your metadata to the catalog: nr1 catalog:submit Copy Step 5 of 5 Return to the catalog and refresh the page to see your new screenshots and metadata describing your project. Subscribe accounts to your application To make sure other users see your application in the catalog, you need to subscribe accounts to the application. Any user with the NerdPack manager or admin role can subscribe to an application from accounts that they have permission to manage. Step 1 of 3 If you're not already displaying your application's description page in the browser, click the launcher for the application in the catalog under Your company applications. Step 2 of 3 On your application's description page, click Add this app. Step 3 of 3 Select the accounts you want to subscribe to the application, and then click Update accounts to save your selections. When you return to the Apps page, you'll see the launcher for your new application. Summary Now that you've completed the steps in this example, you learned the basic steps to: Create a local application. Publish the application to the New Relic One catalog so you can share it with your colleagues. Add details to the project in the catalog so users understand how to use it. Subscribe accounts to your application so other users can use it. Related information Create a local application. Publish the application to the New Relic One catalog so you can share it with your colleagues. Add details to the project in the catalog so users understand how to use it. Subscribe accounts to your application so other users can see it directly on their homepage.",
+ "info": "Build a New Relic app showing page view data on a world map.",
+ "body": "Map page views by region in a custom app 30 min New Relic has powerful and flexible tools for building custom apps and populating them with data. This guide shows you how to build a custom app and populate it with page view data using New Relic's Query Language (NRQL - pronounced 'nurkle'). Then you make your data interactive. And last, if you have a little more time and want to install a third-party React library, you can display the page view data you collect on a map of the world. In this guide, you build an app to display page view data in two ways: In a table On a map Please review the Before you begin section to make sure you have everything you need and don't get stuck halfway through. Before you begin In order to get the most out of this guide, you must have: A New Relic developer account, API key, and the command-line tool. If you don't have these yet, see the steps in Setting up your development environment New Relic Browser page view data to populate the app. Without this data, you won't be able to complete this guide. To add your data to a world map in the second half of the guide: npm, which you'll use during this section of the guide to install Leaflet, a third-party JavaScript React library used to build interactive maps. If you're new to React and npm, you can go here to install Node.js and npm. New Relic terminology The following are some terms used in this guide: New Relic application: The finished product where data is rendered in New Relic One. This might look like a series of interactive charts or a map of the world. Nerdpack: New Relic's standard collection of JavaScript, JSON, CSS, and other files that control the functionality and look of your application. For more information, see Nerdpack file structure. Launcher: The button on New Relic One that launches your application. Nerdlets: New Relic React components used to build your application. The three default files are index.js, nr1.json, and styles.scss, but you can customize and add your own. Build a custom app with a table chart Step 1 of 8 Query your browser data Use Query builder to write a NRQL query to see your page view data, as follows. On New Relic One, select Query your data (in the top right corner). That puts you in NRQL mode. You'll use NRQL to test your query before dropping the data into your table. Copy and paste this query into a clear query field, and then select Run. FROM PageView SELECT count(*), average(duration) WHERE appName = 'WebPortal' FACET countryCode, regionCode SINCE 1 week ago LIMIT 1000 Copy If you have PageView data, this query shows a week of average page views broken down by country and limited to a thousand items. The table will be full width and use the \"chart\" class defined in the CSS. If you don't have any results at this point, ensure your query doesn't have any errors. If your query is correct, you might not have the Browser agent installed. Step 2 of 8 Create and serve a new Nerdpack To get started, create a new Nerdpack, and serve it up to New Relic from your local development environment: Create a new Nerdpack for this app: nr1 create --type nerdpack --name pageviews-app Copy Serve the project up to New Relic: cd pageviews-app && nr1 nerdpack:serve Copy Step 3 of 8 Review your app files and view your app locally Navigate to your pageviews-app to see how it's structured. It contains a launcher folder, where you can customize the description and icon that will be displayed on the app's launcher in New Relic One. It also contains nerdlets, which each contain three default files: index.js, nr1.json, and styles.scss. You'll edit some of these files as part of this guide. For more information, see Nerdpack file structure. Now in your browser, open https://one.newrelic.com/?nerdpacks=local, and then click Apps to see the pageview-apps Nerdpack that you served up. When you select the launcher, you see a Hello message. Step 4 of 8 Hard code your account ID For the purposes of this exercise and for your convenience, hard code your account ID. In the pageview-app-nerdlet directory, in the index.js file, add this code between the import and export lines. (Read about finding your account ID here). const accountId = [Replace with your account ID]; Copy Step 5 of 8 Import the TableChart component To show your data in a table chart, import the TableChart component from New Relic One. To do so, in index.js, add this code under import React. import { TableChart } from `nr1`; Copy Step 6 of 8 Add a table with a single row To add a table with a single row, in the index.js file, replace this line: return
Hello, pageview-app-nerdlet Nerdlet!
; Copy with this export code: export default class PageViewApp extends React.Component { render() { return (
); } } Copy Step 7 of 8 Customize the look of your table (optional) You can use standard CSS to customize the look of your components. In the styles.scss file, add this CSS. Feel free to customize this CSS to your taste. .container { width: 100%; height: 99vh; display: flex; flex-direction: column; .row { margin: 10px; display: flex; flex-direction: row; } .chart { height: 250px; } } Copy Step 8 of 8 Get your data into that table Now that you've got a table, you can drop a TableChart populated with data from the NRQL query you wrote at the very beginning of this guide. Put this code into the row div. ; Copy Go to New Relic One and click your app to see your data in the table. (You might need to serve your app to New Relic again.) Congratulations! You made your app! Continue on to make it interactive and show your data on a map. Make your app interactive with a text field Once you confirm that data is getting to New Relic from your app, you can start customizing it and making it interactive. To do this, you add a text field to filter your data. Later, you use a third-party library called Leaflet to show that data on a world map. Step 1 of 3 Import the TextField component Like you did with the TableChart component, you need to import a TextField component from New Relic One. import { TextField } from 'nr1'; Copy Step 2 of 3 Add a row for your text field To add a text field filter above the table, put this code above the TableChart div. The text field will have a default value of \"US\".
; Copy Step 3 of 3 Build the text field object Above the render() function, add a constructor to build the text field object. constructor(props) { super(props); this.state = { countryCode: null } } Copy Then, add a constructor to your render() function. Above return, add: const { countryCode } = this.state; Copy Now add countryCode to your table chart query. ; Copy Reload your app to try out the text field. Get your data on a map To create the map, you use npm to install Leaflet. Step 1 of 9 Install Leaflet In your terminal, type: npm install --save leaflet react-leaflet Copy In your nerdlets styles.scss file, import the Leaflet CSS: @import `~leaflet/dist/leaflet.css`; Copy While you're in styles.scss, fix the width and height of your map: .containerMap { width: 100%; z-index: 0; height: 70vh; } Copy Step 2 of 9 Add a webpack config file for Leaflet Add a webpack configuration file .extended-webpackrc.js to the top-level folder in your nerdpack. This supports your use of map tiling information data from Leaflet. module.exports = { module: { rules: [ { test: /\\.(png|jpe?g|gif)$/, use: [ { loader: 'file-loader', options: {}, }, { loader: 'url-loader', options: { limit: 25000 }, }, ], }, ], }, }; Copy Step 3 of 9 Import modules from Leaflet In index.js, import modules from Leaflet. import { Map, CircleMarker, TileLayer } from 'react-leaflet'; Copy Step 4 of 9 Import additional modules from New Relic One You need several more modules from New Relic One to make the Leaflet map work well. Import them with this code: import { NerdGraphQuery, Spinner, Button, BlockText } from 'nr1'; Copy NerdGraphQuery lets you make multiple NRQL queries at once and is what will populate the map with data. Spinner adds a loading spinner. Button gives you button components. BlockText give you block text components. Step 5 of 9 Get data for the map Using latitude and longitude with country codes, you can put New Relic data on a map. mapData() { const { countryCode } = this.state; const query = `{ actor { account(id: 1606862) { mapData: nrql(query: \"SELECT count(*) as x, average(duration) as y, sum(asnLatitude)/count(*) as lat, sum(asnLongitude)/count(*) as lng FROM PageView FACET regionCode, countryCode WHERE appName = 'WebPortal' ${countryCode ? ` WHERE countryCode like '%${countryCode}%' ` : ''} LIMIT 1000 \") { results nrql } } } }`; return query; }; Copy Step 6 of 9 Customize the map marker colors Above the mapData function, add this code to customize the map marker colors. getMarkerColor(measure, apdexTarget = 1.7) { if (measure <= apdexTarget) { return '#11A600'; } else if (measure >= apdexTarget && measure <= apdexTarget * 4) { return '#FFD966'; } else { return '#BF0016'; } }; Copy Feel free to change the HTML color code values to your taste. In this example, #11A600 is green, #FFD966 is sort of yellow, and #BF0016 is red. Step 7 of 9 Set your map's default center point Set a default center point for your map using latitude and longitude. const defaultMapCenter = [10.5731, -7.5898]; Copy Step 8 of 9 Add a row for your map Between the text field row and the table chart row, insert a new row for the map content using NerdGraphQuery.
{({ loading, error, data }) => { if (loading) { return ; } if (error) { return 'Error'; } const { results } = data.actor.account.mapData; console.debug(results); return 'Hello'; }}
; Copy Reload your application in New Relic One to test that it works. Step 9 of 9 Replace \"Hello\" with the Leaflet code Replace return \"Hello\"; with: return ( ); Copy This code creates a world map centered on the latitude and longitude you chose using OpenStreetMap data and your marker colors. Reload your app to see the pageview data on the map!",
"_index": "520d1d5d14cc8a32e600034b",
"_type": "520d1d5d14cc8a32e600034c",
- "_score": 662.2763,
+ "_score": 140.02951,
"_version": null,
"_explanation": null,
"sort": null,
"highlight": {
- "sections": "Publish your application to NewRelic",
- "info": "Build a "Hello, World!" app and publish it to NewRelicOne",
- "tags": "Nerdpackfilestructure",
- "body": "!" application The CLI allows you to run a local version of NewRelicOne. You can develop your application locally before you publish it in NewRelicOne. If you followed all the steps in the CLI quick start, you now have files under a new directory named after your nerdpack project. Here's how you edit"
+ "sections": "Create and serve a new Nerdpack",
+ "tags": "nerdpack",
+ "body": " look like a series of interactive charts or a map of the world. Nerdpack: New Relic's standard collection of JavaScript, JSON, CSS, and other files that control the functionality and look of your application. For more information, see Nerdpackfilestructure. Launcher: The button on New Relic One"
},
- "id": "5efa9973196a67d16d76645c"
- },
+ "id": "5efa993c196a67066b766469"
+ }
+ ],
+ "/explore-docs/nr1-catalog": [
{
"sections": [
- "Set up your development environment",
- "Before you begin",
- "A note on support",
+ "New Relic One CLI reference",
+ "Installing the New Relic One CLI",
"Tip",
- "Prepare to build or modify apps",
- "Start building",
- "Contribute to developer.newrelic.com"
+ "New Relic One CLI Commands",
+ "Get started",
+ "Configure your CLI preferences",
+ "Set up your Nerdpacks",
+ "Manage your Nerdpack subscriptions",
+ "Install and manage plugins",
+ "Manage catalog information"
],
- "title": "Set up your development environment",
+ "title": "New Relic One CLI reference",
"type": "developer",
"tags": [
- "developer account",
- "API key",
- "New Relic One CLI"
+ "New Relic One app",
+ "nerdpack commands"
],
- "external_id": "c45638a9cd548d1ffffc9f1c7708f115a92ae04a",
- "image": "",
- "url": "https://developer.newrelic.com/build-apps/set-up-dev-env/",
- "published_at": "2020-08-28T01:45:16Z",
- "updated_at": "2020-08-26T01:47:20Z",
+ "external_id": "858339a44ead21c83257778ce60b4c352cd30d3b",
+ "image": "https://developer.newrelic.com/static/2c6d337608b38a3312b4fc740afe6167/7272b/developercenter.png",
+ "url": "https://developer.newrelic.com/explore-docs/nr1-cli/",
+ "published_at": "2020-08-29T01:58:45Z",
+ "updated_at": "2020-08-18T01:50:36Z",
"document_type": "page",
"popularity": 1,
- "info": "Prepare to build apps and contribute to this site",
- "body": "Set up your development environment 20 min If you've decided to build a custom app or modify one of our open source apps, you need a few essential tools: The New Relic One command line interface (CLI) An API key, which you get when you download the CLI Depending on what you want to do with your app, you might have some additional setup and configuration. This guide covers: Downloading the New Relic One CLI to build or modify apps Contribute content to this website Before you begin You must have: A github account account - While not strictly necessary for building apps, a GitHub account enables you to download and customize our open source apps, and contribute an open source project. A New Relic developer account - if you don't already have one, you can get a free trial account for developing New Relic applications. npm - If you've installed Node.js, then you already have npm, which is used to share, reuse, and update JavaScript code, and is necessary for working with React components that are the framework for New Relic apps and this website. A note on support Building a New Relic One application is the same as building any JavaScript/React application. We offer support to help with our building tools (our CLI and SDK library). However, we don't offer support for basic JavaScript or React coding questions or issues. For common questions and answers about building, see the Explorers Hub page on building on New Relic One. Tip Use the New Relic One VSCode extension to build your apps. Prepare to build or modify apps Step 1 of 1 Download the CLI and API key. On the Build New Relic One applications page, complete the Quick start steps. These six Quick start steps get you an API key for use with developing apps, and the New Relic One CLI, for building and deploying apps. At the end of the Quick start, you have a project consisting of the following: A Nerdpack - The package containing all the files required by your application. It contains two types of files that you customize to build your app: Nerdlets, and the launcher. One or more Nerdlet files - A specific UI view or window. A Nerdlet is a React JavaScript package that includes an index.js file, a stylesheet, and a JSON-format config file. It can contain any JS functionality (charts, interactive fields, tooltips, etc.). A launcher file: This is the basis for the launcher, which is used to open your application from New Relic One after you publish your app. Start building Step 1 of 1 If you're ready to code, cd to your Nerdpack and get started. If you want to learn more about building applications, try these step-by-step guides: Build a \"Hello, World!\" application shows how to create a little application, publish it to New Relic One, and share it with others by subscribing accounts to it. Map pageviews by region takes you through the steps to create one of our popular open source apps. You learn to add a custom query to an app and view it in a table, then add that data to a map. Contribute to developer.newrelic.com This site is open source, and we want your input. Create a pull request if you see a mistake you know how to fix. Drop us a GitHub issue if you see some content gaps you want us to work on. Or write up a whole new guide if you have one you'd like to share. Read on to learn how. Step 1 of 3 Fork the developer-website GithHub repo. Forking the repo enables you to work on your own copy of the developer.newrelic.com files, and build the site locally. It also enables us to more easily manage incomimg pull requests. On the developer-website page in GitHub, select the Fork button on the top right of the page, choose the account you want to fork to, and wait a few seconds while the fork is created. Sync regularly to keep your fork up to date with changes and additions to the main branch upstream. Step 2 of 3 Make a feature or documentation request. On any page, select the GitHub button at the top of the page, and then select the kind of change you want, and fill out the GitHub form. Step 3 of 3 Contribute a new guide. Check out our contributors guidelines, which will walk you through the process.",
+ "info": "An overview of the CLI to help you build, deploy, and manage New Relic apps.",
+ "body": "New Relic One CLI reference To build a New Relic One app, you must install the New Relic One CLI. The CLI helps you build, publish, and manage your New Relic app. We provide a variety of tools for building apps, including the New Relic One CLI (command line interface). This page explains how to use CLI commands to: Generate Nerdpack/Nerdlet templates Locally serve Nerdpacks (when developing) Publish and deploy Subscribe to Nerdpacks Add screenshots and metadata to the catalog Installing the New Relic One CLI In New Relic, click Apps and then in the New Relic One catalog area, click the Build your own application launcher and follow the quick start instructions. The quick start automatically generates an API key for the account you select, and gives you the pre-populated commands to create a profile, generate your first \"Hello World\" app, and serve it locally. Tip Use the NR1 VS Code extension to build your apps. New Relic One CLI Commands This table provides descriptions for the New Relic One commands. For more context, including usage and option details, click any individual command or the command category. For details on user permissions, see Authentication and permissions. For more on how to serve and publish your application, see our guide on Deploying your New Relic One app. Get started nr1 help Shows all nr1 commands or details about each command. nr1 update Updates to the latest version of the CLI. nr1 create Creates a new component from a template (Nerdpack, Nerdlet, launcher, or catalog). nr1 profiles Manages the profiles you use to run CLI commands. nr1 autocomplete Displays autocomplete installation instructions. nr1 nrql Fetches data using NRQL (New Relic query language). Configure your CLI preferences nr1 config:set Sets a specific configuration value. nr1 config:get Shows a specific configuration. nr1 config:list Lists your configuration choices. nr1 config:delete Removes the value of a specific configuration. Set up your Nerdpacks nr1 nerdpack:clone Clones an open source Nerdpack from our GitHub repository. nr1 nerdpack:serve Serves your Nerdpack for testing and development purposes. nr1 nerdpack:uuid Shows or regenerates the UUID of a Nerdpack. nr1 nerdpack:publish Publishes your Nerdpack to New Relic. nr1 nerdpack:deploy Deploys a Nerdpack version to a specific channel. nr1 nerdpack:undeploy Undeploys a Nerdpack version from a specific channel. Manage your Nerdpack subscriptions nr1 subscription:set Subscribes your account to a Nerdpack and channel. nr1 subscription:list Lists all the Nerdpacks your account is subscribed to. nr1 subscription:unset Unsubscribes your account from a Nerdpack. Install and manage plugins nr1 plugins:install Installs a plugin into the CLI. nr1 plugins:link Links a plugin into the CLI for development. nr1 plugins:update Updates your installed plugins. nr1 plugins:uninstall Removes a plugin from the CLI. Manage catalog information nr1 catalog:info Shows the Nerdpack info stored in the catalog. nr1 catalog:submit Gathers and submits the catalog info on the current folder.",
"_index": "520d1d5d14cc8a32e600034b",
"_type": "520d1d5d14cc8a32e600034c",
- "_score": 543.18024,
+ "_score": 328.46286,
"_version": null,
"_explanation": null,
"sort": null,
"highlight": {
- "tags": "NewRelicOneCLI",
- "body": ". At the end of the Quick start, you have a project consisting of the following: A Nerdpack - The package containing all the files required by your application. It contains two types of files that you customize to build your app: Nerdlets, and the launcher. One or more Nerdlet files - A specific UI view"
+ "title": "NewRelicOneCLI reference",
+ "sections": "NewRelicOneCLICommands",
+ "info": "An overview of the CLI to help you build, deploy, and manage NewRelic apps.",
+ "tags": "NewRelicOne app",
+ "body": " CLIcommands to: Generate Nerdpack/Nerdlet templates Locally serve Nerdpacks (when developing) Publish and deploy Subscribe to Nerdpacks Add screenshots and metadata to the catalog Installing the NewRelicOneCLI In NewRelic, click Apps and then in the NewRelicOnecatalog area, click the Build"
},
- "id": "5efa9973e7b9d242237bab39"
+ "id": "5efa989e28ccbc535a307dd0"
},
{
"sections": [
@@ -5956,7 +6134,7 @@
"external_id": "63283ee8efdfa419b6a69cb8bd135d4bc2188d2c",
"image": "https://developer.newrelic.com/static/f6d5070509ac08ec96c6c522d5109471/b01d9/apps_catalog.png",
"url": "https://developer.newrelic.com/build-apps/publish-deploy/",
- "published_at": "2020-08-28T01:51:50Z",
+ "published_at": "2020-08-29T01:56:37Z",
"updated_at": "2020-08-26T01:50:42Z",
"document_type": "page",
"popularity": 1,
@@ -5964,7 +6142,7 @@
"body": "Serve, publish, and deploy your New Relic One app 30 min When you build a New Relic One app, chances are you'll want to share it with others in your organization. You might even want to share it broadly through our open source channel. But first, you probably want to try it out locally to make sure it's working properly. From the New Relic One Apps page, you can review available apps and subscribe to the ones you want for accounts you manage. The Other apps section shows launchers for New Relic apps, as well as any third-party apps that you subscribe to. The New Relic One catalog provides apps that you haven't subscribed to, some developed by New Relic engineers to provide visualizations we think you'll want, like Cloud Optimizer, which analyzes your cloud environment, or PageView Map, which uses Browser events to chart performance across geographies. Other apps in the catalog are created by third-party contributors and are submitted via opensource.newrelic.com. All are intended to help you visualize the data you need, the way you want it. Here, you learn to: Serve your app locally Add images and metadata to your app Publish it Subscribe and unsubscribe accounts you manage to the app Handle duplicate applications Before you begin This guide requires the following: A New Relic One app or Nerdpack New Relic One CLI A Nerdpack manager role for publishing, deploying, and subscribing apps. Serve your app locally You can locally serve the app you create to New Relic One to test it out. Step 1 of 1 In the parent root folder of your Nerdpack, run nr1 nerdpack:serve. Go to one.newrelic.com/?nerdpacks=local. The ?nerdpacks=local URL suffix will load any locally served Nerdpacks that are available. When you make a change to a locally served Nerdpack, New Relic One will automatically reload it. Add images and metadata to your apps Application creators can include a description of what their apps do and how they're best used when they build an app. They can also include screenshots, icons, and metadata that help to make them easy to spot amongst other applications. Some metadata is added automatically when an app is published: Related entities, listed if there are any. Origin label to indicate where the app comes from: local, custom, or public. The New Relic One CLI enables you to provide the information and images you want to include with your application. Then it's a matter of kicking off a catalog command that validates the information and saves it to the catalog. Step 1 of 3 Update the New Relic One CLI to ensure you're working with the latest version. nr1 update Copy Step 2 of 3 Add catalog metadata and screenshots. Run nr1 create and then select catalog to add a catalog folder to your New Relic One project. The folder contains the following empty files and folder. Add the information as described in the following table for the process to succeed. screenshots folder A directory that must contain no more than 6 images and meet these criteria: 3:2 aspect ratio PNG format landscape orientation 1600 to 2400 pixels wide documentation.md A markdown file that presents usage information pulled into the Documentation tab for the application in the catalog. additionalInfo.md An optional markdown file for any additional information about using your application. config.json A JSON file that contains the following fields: tagline: A brief headline for the application. Must not exceed 30 characters. repository: The URL to the GitHub repo for the application. Must not exceed 1000 characters. details: Describes the purpose of the application and how to use it. Information must not exceed 1000. Use carriage returns for formatting. Do not include any markdown or HTML. support: An object that contains: issues: A valid URL to the GitHub repository's issues list, generally the GitHub Issues tab for the repo. email: A valid email address for the team supporting the application. community: URL to a support thread, forum, or website for troubleshooting and usage support. whatsNew: A bulleted list of changes in this version. Must not exceed 500 characters. Use carriage returns for formatting. Do not include markdown or HTML. Example: { \"tagline\": \"Map your workloads & entities\", \"repository\": \"https://github.com/newrelic/nr1-workload-geoops.git\", \"details\": \"Describe, consume, and manage Workloads and Entities in a geographic model that supports location-specific KPI's, custom metadata, drill-down navigation into Entities and Workloads, real-time configuration, and configuration via automation using the newrelic-cli.\", \"support\": { \"issues\": { \"url\": \"https://github.com/newrelic/nr1-workload-geoops/issues\" }, \"email\": { \"address\": \"opensource+nr1-workload-geoops@newrelic.com\" }, \"community\": { \"url\": \"https://discuss.newrelic.com/t/workload-geoops-nerdpack/99478\" } }, \"whatsNew\": \"\\n-Feat: Geographic mapping of Workloads and Entities\\n-Feat: Programmatic alerting rollup of underlying Entities\\n-Feat: Custom KPI measurement per location\\n-Feat: Empty-state edit workflow\\n-Feat: JSON file upload format\\n-Feat: Published (in open source docs) guide to automating configuration using the newrelic-cli\" } Copy Step 3 of 3 Save the metadata and screenshots to the catalog. This validates the information you added to the catalog directory against the criteria described in the previous step, and saves it to the catalog. nr1 catalog:submit Copy Publish your app Publishing places your Nerdpack in New Relic One. To publish or deploy, you must be a Nerdpack manager. Step 1 of 1 To publish your Nerdpack, run nr1 nerdpack:publish. Deploy your app Deploying is applying a Nerdpack version to a specific channel (for example, BETA, or STABLE). A channel can only have one Nerdpack version deployed to it at one time. If a channel has an existing Nerdpack associated with it, deploying a new Nerdpack version to that channel will undeploy the previous one. Channels are meant to be an easier way to control application version access than having to be concerned with specific version numbers. Step 1 of 1 To deploy an application, run nr1 nerdpack:deploy. Subscribe or unsubsribe apps Whether you want to subscribe accounts to an app you've created or to apps already available in the catalog, the process is the same. Note that if you subscribe to an app in the catalog, you'll automatically get any updates that are added to the app. To learn about the appropriate permissions for subscribing, see Permissions for managing applications. Step 1 of 2 Subscribe accounts to an application. Select an application you want to add to your New Relic account. Click Add this app. Note that this button says Manage access if the app has already been subscribed to an account you manage. On the Account access page listing the accounts you can subscribe to an application: Select the accounts you want to subscribe the app to. Choose the channel you want to subscribe the app to, Stable or Dev. This can only be Stable for the public apps created by New Relic. Click the update button. Now you and members of the accounts you have subscribed to the app can launch it from New Relic One. Step 2 of 2 Unsubsribe from an application. On the Apps page, open the app you want to unsubscribe. Click Manage access. Clear the check box for any accounts you want to unsubscribe, and then click the update button. The application is no longer listed in the Other apps section of the Apps page, and you have unsubscribed. Handle duplicate applications You might end up with duplicate applications on your New Relic One Apps page. This can happen when you subscribe to the same app using both the CLI and the catalog. Or if you clone an app, modify, and deploy it, but keep the original name. You can manage duplicates with the catalog. Good to know before you start: You need a user role with the ability to manage Nerdpacks for accounts that you want to unsubscribe and undeploy from applications. You can't remove the public apps. When a duplicate application has no accounts subscribed to it, you undeploy it. For applications that have accounts subscribed to them, you unscubscribe and undeploy. The unsubscribe and undeploy process happens in a batch. To remove an account from an application, but ensure that other accounts continue to be subscribed, select the checkbox, Resubscribe these accounts to the new application. Step 1 of 1 Remove duplicates. In the New Relic One catalog, click a public application that has one or more duplicates. (You can only manage duplicates from the public version of the application.) On the application information page, select Clean up applications. Review the information about the application that's open, as well as any duplicates. Click Manage app for duplicates you want to remove. If needed, select Resubscribe these accounts to the new application. Click Unsubscribe and undeploy, and agree to the terms and conditions.",
"_index": "520d1d5d14cc8a32e600034b",
"_type": "520d1d5d14cc8a32e600034c",
- "_score": 474.80585,
+ "_score": 242.1569,
"_version": null,
"_explanation": null,
"sort": null,
@@ -5972,7 +6150,7 @@
"title": "Serve, publish, and deploy your NewRelicOne app",
"sections": "Serve, publish, and deploy your NewRelicOne app",
"info": "Start sharing and using the custom NewRelicOne apps you build",
- "body": " to the app Handle duplicate applications Before you begin This guide requires the following: A NewRelicOne app or NerdpackNewRelicOneCLI A Nerdpack manager role for publishing, deploying, and subscribing apps. Serve your app locally You can locally serve the app you create to NewRelicOne to test"
+ "body": " a matter of kicking off a catalogcommand that validates the information and saves it to the catalog. Step 1 of 3 Update the NewRelicOneCLI to ensure you're working with the latest version. nr1 update Copy Step 2 of 3 Add catalog metadata and screenshots. Run nr1 create and then select catalog"
},
"id": "5efa999de7b9d283e67bab8f"
},
@@ -6000,7 +6178,7 @@
"nr1 nrql",
"Query using NRQL"
],
- "published_at": "2020-08-28T01:50:39Z",
+ "published_at": "2020-08-29T01:58:05Z",
"title": "New Relic One CLI common commands",
"updated_at": "2020-08-14T01:48:10Z",
"type": "developer",
@@ -6011,60 +6189,98 @@
"body": "New Relic One CLI common commands Here's a list of common commands to get you started with the New Relic One CLI. You can click any command to see its usage options and additional details about the command. Command Description nr1 help Shows all nr1 commands or details about each command. nr1 update Updates to the latest version of the CLI. nr1 create Creates a new component from a template (Nerdpack, Nerdlet, launcher, or catalog). nr1 profiles Manages the profiles you use to run CLI commands. nr1 autocomplete Displays autocomplete installation instructions. nr1 nrql Fetches data using NRQL (New Relic query language). See our other New Relic One CLI docs for commands specific to Nerdpack set-up, Nerdpack subscriptions, CLI configuration, plugins, or catalogs. Command details nr1 help See commands and get details Shows all nr1 commands by default. To get details about a specific command, run nr1 help COMMAND_NAME. Usage $ nr1 help Arguments COMMAND_NAME The name of a particular command. Examples $ nr1 help $ nr1 help nerdpack $ nr1 help nerdpack:deploy nr1 update Update your CLI Updates to latest version of the CLI. You can specify which channel to update if you'd like. Usage $ nr1 update Arguments CHANNEL The name of a particular channel. Examples $ nr1 update $ nr1 update somechannel nr1 create Create a new component Creates a new component from our template (either a Nerdpack, Nerdlet, launcher, or catalog). The CLI will walk you through this process. To learn more about Nerdpacks and their file structure, see Nerdpack file structure. For more on how to set up your Nerdpacks, see our Nerdpack CLI commands. Usage $ nr1 create Options -f, --force If present, overrides existing files without asking. -n, --name=NAME Names the component. -t, --type=TYPE Specifies the component type. --path=PATH The route to the component. --profile=PROFILE The authentication profile you want to use. --verbose Adds extra information to the output. nr1 profiles Manage your profiles keychain Displays a list of commands you can use to manage your profiles. Run nr1 help profiles:COMMAND for more on their specific usages. You can have more than one profile, which is helpful for executing commands on multiple New Relic accounts. To learn more about setting up profiles, see our Github workshop. Usage $ nr1 profiles:COMMAND Commands profiles:add Adds a new profile to your profiles keychain. profiles:default Chooses which profile should be default. profiles:list Lists the profiles on your keychain. profiles:remove Removes a profile from your keychain. nr1 autocomplete See autocomplete installation instructions Displays the autocomplete installation instructions. By default, the command displays the autocomplete instructions for zsh. If you want instructions for bash, run nr1 autocomplete bash. Usage $ nr1 autocomplete Arguments SHELL The shell type you want instructions for. Options -r, --refresh-cache Refreshes cache (ignores displaying instructions). Examples $ nr1 autocomplete $ nr1 autocomplete zsh $ nr1 autocomplete bash $ nr1 autocomplete --refresh-cache nr1 nrql Query using NRQL Fetches data from databases using a NRQL query. To learn more about NRQL and how to use it, see our NRQL docs. Usage $ nr1 nrql OPTION ... Options -a, --account=ACCOUNT The user account ID. required -q, --query=QUERY The NRQL query to run. required -u, --ugly Displays the content without tabs or spaces. --profile=PROFILE The authentication profile you want to use. --verbose Adds extra information to the output.",
"_index": "520d1d5d14cc8a32e600034b",
"_type": "520d1d5d14cc8a32e600034c",
- "_score": 388.57184,
+ "_score": 225.61298,
"_version": null,
"_explanation": null,
"sort": null,
"highlight": {
- "title": "NewRelicOneCLI common commands",
- "sections": "NewRelicOneCLI common commands",
- "info": "An overview of common commands you can use with the NewRelicOneCLI.",
- "body": " update Updates to the latest version of the CLI. nr1 create Creates a new component from a template (Nerdpack, Nerdlet, launcher, or catalog). nr1 profiles Manages the profiles you use to run CLI commands. nr1 autocomplete Displays autocomplete installation instructions. nr1 nrql Fetches data using NRQL"
+ "title": "NewRelicOneCLI common commands",
+ "sections": "NewRelicOneCLI common commands",
+ "info": "An overview of common commands you can use with the NewRelicOneCLI.",
+ "body": "NewRelicOneCLI common commands Here's a list of common commands to get you started with the NewRelicOneCLI. You can click any command to see its usage options and additional details about the command. Command Description nr1 help Shows all nr1 commands or details about each command. nr1"
},
"id": "5f28bd6ae7b9d267996ade94"
},
{
"sections": [
- "New Relic One CLI reference",
- "Installing the New Relic One CLI",
+ "Create a \"Hello, World!\" application",
+ "Before you begin",
"Tip",
- "New Relic One CLI Commands",
- "Get started",
- "Configure your CLI preferences",
- "Set up your Nerdpacks",
- "Manage your Nerdpack subscriptions",
- "Install and manage plugins",
- "Manage catalog information"
+ "Create a local version of the \"Hello, World!\" application",
+ "Publish your application to New Relic",
+ "Add details to describe your project",
+ "Subscribe accounts to your application",
+ "Summary",
+ "Related information"
],
- "title": "New Relic One CLI reference",
+ "title": "Create a \"Hello, World!\" application",
"type": "developer",
"tags": [
- "New Relic One app",
- "nerdpack commands"
+ "nr1 cli",
+ "Nerdpack file structure",
+ "NR One Catalog",
+ "Subscribe applications"
],
- "external_id": "858339a44ead21c83257778ce60b4c352cd30d3b",
- "image": "https://developer.newrelic.com/static/2c6d337608b38a3312b4fc740afe6167/7272b/developercenter.png",
- "url": "https://developer.newrelic.com/explore-docs/nr1-cli/",
- "published_at": "2020-08-28T01:50:39Z",
- "updated_at": "2020-08-18T01:50:36Z",
+ "external_id": "aa427030169067481fb69a3560798265b6b52b7c",
+ "image": "https://developer.newrelic.com/static/cb65a35ad6fa52f5245359ecd24158ff/9466d/hello-world-output-local.png",
+ "url": "https://developer.newrelic.com/build-apps/build-hello-world-app/",
+ "published_at": "2020-08-29T01:50:40Z",
+ "updated_at": "2020-08-21T01:45:19Z",
"document_type": "page",
"popularity": 1,
- "info": "An overview of the CLI to help you build, deploy, and manage New Relic apps.",
- "body": "New Relic One CLI reference To build a New Relic One app, you must install the New Relic One CLI. The CLI helps you build, publish, and manage your New Relic app. We provide a variety of tools for building apps, including the New Relic One CLI (command line interface). This page explains how to use CLI commands to: Generate Nerdpack/Nerdlet templates Locally serve Nerdpacks (when developing) Publish and deploy Subscribe to Nerdpacks Add screenshots and metadata to the catalog Installing the New Relic One CLI In New Relic, click Apps and then in the New Relic One catalog area, click the Build your own application launcher and follow the quick start instructions. The quick start automatically generates an API key for the account you select, and gives you the pre-populated commands to create a profile, generate your first \"Hello World\" app, and serve it locally. Tip Use the NR1 VS Code extension to build your apps. New Relic One CLI Commands This table provides descriptions for the New Relic One commands. For more context, including usage and option details, click any individual command or the command category. For details on user permissions, see Authentication and permissions. For more on how to serve and publish your application, see our guide on Deploying your New Relic One app. Get started nr1 help Shows all nr1 commands or details about each command. nr1 update Updates to the latest version of the CLI. nr1 create Creates a new component from a template (Nerdpack, Nerdlet, launcher, or catalog). nr1 profiles Manages the profiles you use to run CLI commands. nr1 autocomplete Displays autocomplete installation instructions. nr1 nrql Fetches data using NRQL (New Relic query language). Configure your CLI preferences nr1 config:set Sets a specific configuration value. nr1 config:get Shows a specific configuration. nr1 config:list Lists your configuration choices. nr1 config:delete Removes the value of a specific configuration. Set up your Nerdpacks nr1 nerdpack:clone Clones an open source Nerdpack from our GitHub repository. nr1 nerdpack:serve Serves your Nerdpack for testing and development purposes. nr1 nerdpack:uuid Shows or regenerates the UUID of a Nerdpack. nr1 nerdpack:publish Publishes your Nerdpack to New Relic. nr1 nerdpack:deploy Deploys a Nerdpack version to a specific channel. nr1 nerdpack:undeploy Undeploys a Nerdpack version from a specific channel. Manage your Nerdpack subscriptions nr1 subscription:set Subscribes your account to a Nerdpack and channel. nr1 subscription:list Lists all the Nerdpacks your account is subscribed to. nr1 subscription:unset Unsubscribes your account from a Nerdpack. Install and manage plugins nr1 plugins:install Installs a plugin into the CLI. nr1 plugins:link Links a plugin into the CLI for development. nr1 plugins:update Updates your installed plugins. nr1 plugins:uninstall Removes a plugin from the CLI. Manage catalog information nr1 catalog:info Shows the Nerdpack info stored in the catalog. nr1 catalog:submit Gathers and submits the catalog info on the current folder.",
+ "info": "Build a \"Hello, World!\" app and publish it to New Relic One",
+ "body": "Create a \"Hello, World!\" application 15 min Here's how you can quickly build a \"Hello, World!\" application in New Relic One. In these steps, you create a local version of the New Relic One site where you can prototype your application. Then, when you're ready to share the application with others, you can publish it to New Relic One. See the video, which demonstrates the steps in this guide in five minutes. Before you begin To get started, make sure you have accounts in GitHub and New Relic. To develop projects, you need the New Relic One CLI (command line interface). If you haven't already installed it, do the following: Install Node.js. Complete all the steps in the CLI quick start. For additional details about setting up your environment, see Set up your development environment. Tip Use the NR1 VS Code extension to build your apps. Create a local version of the \"Hello, World!\" application The CLI allows you to run a local version of New Relic One. You can develop your application locally before you publish it in New Relic One. If you followed all the steps in the CLI quick start, you now have files under a new directory named after your nerdpack project. Here's how you edit those files to create a \"Hello, World!\" project: Step 1 of 9 Open a code editor and point it to the new directory named after your nerdpack project (for example, my-awesome-nerdpack). Your code editor displays two artifacts: launchers containing the homepage tile nerdlets containing your application code Step 2 of 9 Expand nerdlets in your code editor, and open index.js. Step 3 of 9 Change the default return message to \"Hello, World!\": import React from 'react'; // https://docs.newrelic.com/docs/new-relic-programmable-platform-introduction export default class MyAwesomeNerdpackNerdletNerdlet extends React.Component { render() { return
\"Hello, World!\"
; } } Copy Step 4 of 9 As an optional step, you can add a custom launcher icon using any image file named icon.png. Replace the default icon.png file under launcher by dragging in your new image file: Step 5 of 9 To change the name of the launcher to something meaningful, in your code editor under launchers, open nr1.json. Step 6 of 9 Change the value for displayName to anything you want as the launcher label, and save the file: { \"schemaType\": \"LAUNCHER\", \"id\": \"my-awesome-nerdpack-launcher\", \"description\": \"Describe me\", \"displayName\": \"INSERT_YOUR_TILE_LABEL_HERE\", \"rootNerdletId\": \"my-awesome-nerdpack-nerdlet\" } Copy Step 7 of 9 To see your new changes locally, start the Node server with this command in your terminal: npm start Copy Step 8 of 9 Open a browser and go to https://one.newrelic.com/?nerdpacks=local (this url is also shown in the terminal). Step 9 of 9 When the browser opens, click Apps, and then in the Other apps section, click the new launcher for your application. Here's an example where we inserted a leaf icon: After you click the new launcher, your \"Hello, World!\" appears: Publish your application to New Relic Your colleagues can't see your local application, so when you are ready to share it, publish it to the New Relic One catalog. The catalog is where you can find any pre-existing custom applications, as well as any applications you create in your own organization. Step 1 of 4 Execute the following in your terminal: nr1 nerdpack:publish Copy Step 2 of 4 Close your local New Relic One development tab, and open New Relic One. Step 3 of 4 Click the Apps launcher. Step 4 of 4 Under New Relic One catalog, click the launcher for your new application. When your new application opens, notice that it doesn't display any helpful descriptive information. The next section shows you how to add descriptive metadata. Add details to describe your project Now that your new application is in the New Relic One catalog, you can add details that help users understand what your application does and how to use it. Step 1 of 5 Go to your project in the terminal and execute the following: nr1 create Copy Step 2 of 5 Select catalog, which creates a stub in your project under the catalog directory. Here's how the results might look in your code editor: Step 3 of 5 In the catalog directory of your project, add screenshots or various types of metadata to describe your project. For details about what you can add, see Add catalog metadata and screenshots. Step 4 of 5 After you add the screenshots and descriptions you want, execute the following to save your metadata to the catalog: nr1 catalog:submit Copy Step 5 of 5 Return to the catalog and refresh the page to see your new screenshots and metadata describing your project. Subscribe accounts to your application To make sure other users see your application in the catalog, you need to subscribe accounts to the application. Any user with the NerdPack manager or admin role can subscribe to an application from accounts that they have permission to manage. Step 1 of 3 If you're not already displaying your application's description page in the browser, click the launcher for the application in the catalog under Your company applications. Step 2 of 3 On your application's description page, click Add this app. Step 3 of 3 Select the accounts you want to subscribe to the application, and then click Update accounts to save your selections. When you return to the Apps page, you'll see the launcher for your new application. Summary Now that you've completed the steps in this example, you learned the basic steps to: Create a local application. Publish the application to the New Relic One catalog so you can share it with your colleagues. Add details to the project in the catalog so users understand how to use it. Subscribe accounts to your application so other users can use it. Related information Create a local application. Publish the application to the New Relic One catalog so you can share it with your colleagues. Add details to the project in the catalog so users understand how to use it. Subscribe accounts to your application so other users can see it directly on their homepage.",
"_index": "520d1d5d14cc8a32e600034b",
"_type": "520d1d5d14cc8a32e600034c",
- "_score": 381.40512,
+ "_score": 206.766,
"_version": null,
"_explanation": null,
"sort": null,
"highlight": {
- "title": "NewRelicOneCLI reference",
- "sections": "NewRelicOneCLI reference",
- "info": "An overview of the CLI to help you build, deploy, and manage NewRelic apps.",
- "tags": "NewRelicOne app",
- "body": " CLI commands to: Generate Nerdpack/Nerdlet templates Locally serve Nerdpacks (when developing) Publish and deploy Subscribe to Nerdpacks Add screenshots and metadata to the catalog Installing the NewRelicOneCLI In NewRelic, click Apps and then in the NewRelicOne catalog area, click the Build"
+ "sections": "Publish your application to NewRelic",
+ "info": "Build a "Hello, World!" app and publish it to NewRelicOne",
+ "tags": "NR OneCatalog",
+ "body": ", you can publish it to NewRelicOne. See the video, which demonstrates the steps in this guide in five minutes. Before you begin To get started, make sure you have accounts in GitHub and NewRelic. To develop projects, you need the NewRelicOneCLI (command line interface). If you haven't already"
},
- "id": "5efa989e28ccbc535a307dd0"
+ "id": "5efa9973196a67d16d76645c"
+ },
+ {
+ "sections": [
+ "Set up your development environment",
+ "Before you begin",
+ "A note on support",
+ "Tip",
+ "Prepare to build or modify apps",
+ "Start building",
+ "Contribute to developer.newrelic.com"
+ ],
+ "title": "Set up your development environment",
+ "type": "developer",
+ "tags": [
+ "developer account",
+ "API key",
+ "New Relic One CLI"
+ ],
+ "external_id": "c45638a9cd548d1ffffc9f1c7708f115a92ae04a",
+ "image": "",
+ "url": "https://developer.newrelic.com/build-apps/set-up-dev-env/",
+ "published_at": "2020-08-29T01:50:40Z",
+ "updated_at": "2020-08-26T01:47:20Z",
+ "document_type": "page",
+ "popularity": 1,
+ "info": "Prepare to build apps and contribute to this site",
+ "body": "Set up your development environment 20 min If you've decided to build a custom app or modify one of our open source apps, you need a few essential tools: The New Relic One command line interface (CLI) An API key, which you get when you download the CLI Depending on what you want to do with your app, you might have some additional setup and configuration. This guide covers: Downloading the New Relic One CLI to build or modify apps Contribute content to this website Before you begin You must have: A github account account - While not strictly necessary for building apps, a GitHub account enables you to download and customize our open source apps, and contribute an open source project. A New Relic developer account - if you don't already have one, you can get a free trial account for developing New Relic applications. npm - If you've installed Node.js, then you already have npm, which is used to share, reuse, and update JavaScript code, and is necessary for working with React components that are the framework for New Relic apps and this website. A note on support Building a New Relic One application is the same as building any JavaScript/React application. We offer support to help with our building tools (our CLI and SDK library). However, we don't offer support for basic JavaScript or React coding questions or issues. For common questions and answers about building, see the Explorers Hub page on building on New Relic One. Tip Use the New Relic One VSCode extension to build your apps. Prepare to build or modify apps Step 1 of 1 Download the CLI and API key. On the Build New Relic One applications page, complete the Quick start steps. These six Quick start steps get you an API key for use with developing apps, and the New Relic One CLI, for building and deploying apps. At the end of the Quick start, you have a project consisting of the following: A Nerdpack - The package containing all the files required by your application. It contains two types of files that you customize to build your app: Nerdlets, and the launcher. One or more Nerdlet files - A specific UI view or window. A Nerdlet is a React JavaScript package that includes an index.js file, a stylesheet, and a JSON-format config file. It can contain any JS functionality (charts, interactive fields, tooltips, etc.). A launcher file: This is the basis for the launcher, which is used to open your application from New Relic One after you publish your app. Start building Step 1 of 1 If you're ready to code, cd to your Nerdpack and get started. If you want to learn more about building applications, try these step-by-step guides: Build a \"Hello, World!\" application shows how to create a little application, publish it to New Relic One, and share it with others by subscribing accounts to it. Map pageviews by region takes you through the steps to create one of our popular open source apps. You learn to add a custom query to an app and view it in a table, then add that data to a map. Contribute to developer.newrelic.com This site is open source, and we want your input. Create a pull request if you see a mistake you know how to fix. Drop us a GitHub issue if you see some content gaps you want us to work on. Or write up a whole new guide if you have one you'd like to share. Read on to learn how. Step 1 of 3 Fork the developer-website GithHub repo. Forking the repo enables you to work on your own copy of the developer.newrelic.com files, and build the site locally. It also enables us to more easily manage incomimg pull requests. On the developer-website page in GitHub, select the Fork button on the top right of the page, choose the account you want to fork to, and wait a few seconds while the fork is created. Sync regularly to keep your fork up to date with changes and additions to the main branch upstream. Step 2 of 3 Make a feature or documentation request. On any page, select the GitHub button at the top of the page, and then select the kind of change you want, and fill out the GitHub form. Step 3 of 3 Contribute a new guide. Check out our contributors guidelines, which will walk you through the process.",
+ "_index": "520d1d5d14cc8a32e600034b",
+ "_type": "520d1d5d14cc8a32e600034c",
+ "_score": 193.12405,
+ "_version": null,
+ "_explanation": null,
+ "sort": null,
+ "highlight": {
+ "tags": "NewRelicOneCLI",
+ "body": "Set up your development environment 20 min If you've decided to build a custom app or modify one of our open source apps, you need a few essential tools: The NewRelicOnecommand line interface (CLI) An API key, which you get when you download the CLI Depending on what you want to do with your app"
+ },
+ "id": "5efa9973e7b9d242237bab39"
}
],
"/build-apps/set-up-dev-env": [
@@ -6090,7 +6306,7 @@
"external_id": "858339a44ead21c83257778ce60b4c352cd30d3b",
"image": "https://developer.newrelic.com/static/2c6d337608b38a3312b4fc740afe6167/7272b/developercenter.png",
"url": "https://developer.newrelic.com/explore-docs/nr1-cli/",
- "published_at": "2020-08-28T01:50:39Z",
+ "published_at": "2020-08-29T01:58:45Z",
"updated_at": "2020-08-18T01:50:36Z",
"document_type": "page",
"popularity": 1,
@@ -6098,7 +6314,7 @@
"body": "New Relic One CLI reference To build a New Relic One app, you must install the New Relic One CLI. The CLI helps you build, publish, and manage your New Relic app. We provide a variety of tools for building apps, including the New Relic One CLI (command line interface). This page explains how to use CLI commands to: Generate Nerdpack/Nerdlet templates Locally serve Nerdpacks (when developing) Publish and deploy Subscribe to Nerdpacks Add screenshots and metadata to the catalog Installing the New Relic One CLI In New Relic, click Apps and then in the New Relic One catalog area, click the Build your own application launcher and follow the quick start instructions. The quick start automatically generates an API key for the account you select, and gives you the pre-populated commands to create a profile, generate your first \"Hello World\" app, and serve it locally. Tip Use the NR1 VS Code extension to build your apps. New Relic One CLI Commands This table provides descriptions for the New Relic One commands. For more context, including usage and option details, click any individual command or the command category. For details on user permissions, see Authentication and permissions. For more on how to serve and publish your application, see our guide on Deploying your New Relic One app. Get started nr1 help Shows all nr1 commands or details about each command. nr1 update Updates to the latest version of the CLI. nr1 create Creates a new component from a template (Nerdpack, Nerdlet, launcher, or catalog). nr1 profiles Manages the profiles you use to run CLI commands. nr1 autocomplete Displays autocomplete installation instructions. nr1 nrql Fetches data using NRQL (New Relic query language). Configure your CLI preferences nr1 config:set Sets a specific configuration value. nr1 config:get Shows a specific configuration. nr1 config:list Lists your configuration choices. nr1 config:delete Removes the value of a specific configuration. Set up your Nerdpacks nr1 nerdpack:clone Clones an open source Nerdpack from our GitHub repository. nr1 nerdpack:serve Serves your Nerdpack for testing and development purposes. nr1 nerdpack:uuid Shows or regenerates the UUID of a Nerdpack. nr1 nerdpack:publish Publishes your Nerdpack to New Relic. nr1 nerdpack:deploy Deploys a Nerdpack version to a specific channel. nr1 nerdpack:undeploy Undeploys a Nerdpack version from a specific channel. Manage your Nerdpack subscriptions nr1 subscription:set Subscribes your account to a Nerdpack and channel. nr1 subscription:list Lists all the Nerdpacks your account is subscribed to. nr1 subscription:unset Unsubscribes your account from a Nerdpack. Install and manage plugins nr1 plugins:install Installs a plugin into the CLI. nr1 plugins:link Links a plugin into the CLI for development. nr1 plugins:update Updates your installed plugins. nr1 plugins:uninstall Removes a plugin from the CLI. Manage catalog information nr1 catalog:info Shows the Nerdpack info stored in the catalog. nr1 catalog:submit Gathers and submits the catalog info on the current folder.",
"_index": "520d1d5d14cc8a32e600034b",
"_type": "520d1d5d14cc8a32e600034c",
- "_score": 274.44977,
+ "_score": 266.47968,
"_version": null,
"_explanation": null,
"sort": null,
@@ -6134,7 +6350,7 @@
"external_id": "c97bcbb0a2b3d32ac93b5b379a1933e7b4e00161",
"image": "",
"url": "https://developer.newrelic.com/explore-docs/nerdpack-file-structure/",
- "published_at": "2020-08-28T01:50:39Z",
+ "published_at": "2020-08-29T01:58:45Z",
"updated_at": "2020-08-14T01:49:25Z",
"document_type": "page",
"popularity": 1,
@@ -6142,7 +6358,7 @@
"body": "Nerdpack file structure A New Relic One application is represented by a Nerdpack folder, which can include one or more Nerdlet files, and (optionally) one or more launcher files. Here we explain: The file structure for a Nerdpack, a Nerdlet, and a launcher How to link a launcher file to a Nerdlet How to link your application with a monitored entity For basic component definitions, see our component reference. Generate Nerdpack components There are two ways to generate a Nerdpack template: Generate a Nerdpack: Use the New Relic One CLI command nr1 create and select Nerdpack to create a Nerdpack template that includes a Nerdlet and a launcher. Generate Nerdlet or launcher individually: Use the New Relic One CLI command nr1 create and choose either Nerdlet or launcher. This can be useful when adding Nerdlets to an existing Nerdpack. For documentation on generating and connecting Nerdpack components, see our app building guides and the New Relic One CLI command reference. Nerdpack file structure When you generate a Nerdpack template using the nr1 create command, it has the following file structure: my-nerdlet ├── README.md ├── launchers │ └── my-nerdlet-launcher │ ├── icon.png │ └── nr1.json ├── nerdlets │ └── my-nerdlet-nerdlet │ ├── index.js │ ├── nr1.json │ └── styles.scss ├── node_modules │ ├── js-tokens │ ├── loose-envify │ ├── object-assign │ ├── prop-types │ ├── react │ ├── react-dom │ ├── react-is │ └── scheduler ├── nr1.json ├── package-lock.json └── package.json Copy Nerdlet file structure A Nerdpack can contain one or more Nerdlets. A Nerdlet folder starts out with three default files, index.js, nr1.json, and styles.scss. Here is what the default files look like after being generated using the nr1 create command: index.js The JavaScript code of the Nerdlet. import React from 'react'; export default class MyAwesomeNerdpack extends React.Component { render() { return
Hello, my-awesome-nerdpack Nerdlet!
; } } Copy nr1.json The Nerdlet configuration file. { \"schemaType\": \"NERDLET\", \"id\": \"my-awesome-nerdpack-nerdlet\", \"description\": \"Describe me\", \"displayName\": \"MyAwesomeNerdpack\" } Copy Besides using the launcher as the access point for your application, you can also associate the application with a monitored entity to get it to appear in the entity explorer. To do this, add two additional fields to the config file of the first-launched Nerdlet: entities and actionCategory. In the following example, the Nerdlet has been associated with all Browser-monitored applications and will appear under the Monitor UI category : { \"schemaType\": \"NERDLET\", \"id\": \"my-nerdlet\", \"description\": \"Describe me\", \"displayName\": \"Custom Data\", \"entities\": [{ \"domain\": \"BROWSER\", \"type\": \"APPLICATION\" }], \"actionCategory\": \"monitor\" } Copy To see this application in the UI, you would go to the entity explorer, select Browser applications, and select a monitored application. styles.scss An empty SCSS file for styling your application. icon.png The launcher icon that appears on the Apps page in New Relic One when an application is deployed. Launcher file structure Launchers have their own file structure. Note that: A launcher is not required; as an alternative to using a launcher, you can associate your application with a monitored entity. An application can have more than one launcher, which might be desired for an application with multiple Nerdlets. After generating a launcher using the nr1 create command, its folder contains two files: nr1.json The configuration file. { \"schemaType\": \"LAUNCHER\", \"id\": \"my-awesome-nerdpack-launcher\", \"description\": \"Describe me\", \"displayName\": \"MyAwesomeNerdpack\", \"rootNerdletId\": \"my-awesome-nerdpack-nerdlet\" } Copy To connect a launcher to a Nerdlet, the rootNerdletId must match the id in the launched Nerdlet's nr1.json config file. For Nerdpacks with multiple Nerdlets, this needs to be done only for the first-launched Nerdlet. icon.png The icon displayed on the launcher for the app on the Apps page.",
"_index": "520d1d5d14cc8a32e600034b",
"_type": "520d1d5d14cc8a32e600034c",
- "_score": 161.23625,
+ "_score": 157.1994,
"_version": null,
"_explanation": null,
"sort": null,
@@ -6168,33 +6384,80 @@
"Tip",
"Next steps"
],
- "title": "Quickly tag a set of resources",
+ "title": "Quickly tag a set of resources",
+ "type": "developer",
+ "tags": [
+ "tags",
+ "new relic CLI"
+ ],
+ "external_id": "c7c374812f8295e409a9b06d552de51ceefc666b",
+ "image": "",
+ "url": "https://developer.newrelic.com/automate-workflows/5-mins-tag-resources/",
+ "published_at": "2020-08-29T01:50:40Z",
+ "updated_at": "2020-08-14T01:45:08Z",
+ "document_type": "page",
+ "popularity": 1,
+ "info": "Add tags to applications you instrument for easier filtering and organization.",
+ "body": "Quickly tag a set of resources 5 min Tags help you group, search, filter, and focus the data about your entities, which can be anything from applications to hosts to services. Tagging entities using the New Relic CLI is a good candidate for automation. In this 5-minute guide, you use the New Relic CLI to add multiple tags to one of your entities. Before you begin For this guide you need your New Relic personal API Key: Create it at the Account settings screen for your account. Step 1 of 6 Install the New Relic CLI You can download the New Relic CLI via Homebrew (macOS), Scoop (Windows), and Snapcraft (Linux). You can also download pre-built binaries for all platforms, including .deb and .rpm packages, and our Windows x64 .msi installer. Linux With Snapcraft installed, run: sudo snap install newrelic-cli macOS With Homebrew installed, run: brew install newrelic-cli Windows With Scoop installed, run: scoop bucket add newrelic-cli https://github.com/newrelic/newrelic-cli.git scoop install newrelic-cli Step 2 of 6 Create your New Relic CLI profile New Relic CLI profiles contain credentials and settings that you can apply to any CLI command. To create your first CLI profile, run the profiles add command. Don't forget to set the region of your New Relic account: use -r to set either us or eu (this is required). # Create the tutorial account for the US region newrelic profiles add -n tutorial --apiKey API_KEY -r us # Set the profile as default newrelic profiles default -n tutorial Copy Step 3 of 6 Search for an entity Your New Relic account might have hundreds of entities: Have a quick look by opening the Entity explorer. In the terminal, run entity search to retrieve a list of entities from your account as JSON. In the example, you're searching for all entities with \"test\" in their name. # Change the `name` to match any of your existing entities newrelic entity search --name \"test\" Copy Step 4 of 6 If there are matching entities in your account, the query yields data in JSON format, similar to this workload example. Select an entity from the results and look for its guid value; the guid is the unique identifier of the entity. Write it down. { \"accountId\": 123456789, \"domain\": \"NR1\", \"entityType\": \"WORKLOAD_ENTITY\", \"guid\": \"F7B7AE59FDED4204B846FB08423DB18E\", \"name\": \"Test workload\", \"reporting\": true, \"type\": \"WORKLOAD\" }, Copy Step 5 of 6 Add tags and tag lists to your entity With your entity guid, you can add tags right away. You can do so by invoking the entities tags create command. What if you want to add multiple tags? You can use tag sets for that: While tags are key-value pairs separated by colons, tag sets are comma-separated lists of tags. For example: tag1:value1,tag2:value2 Note Adding tags is an asynchronous operation: it could take a little while for the tags to get created. # Adding a single tag newrelic entity tags create --guid GUID --tag key:value # Adding multiple tags newrelic entity tags create --guid GUID --tag tag1:test,tag2:test Copy Step 6 of 6 Check that the tags are there To make sure that the tags have been added to your entities, retrieve them using the entity tags get command. All tags associated with your entity are retrieved as a JSON array. newrelic entity tags get --guid GUID Tip Tags can be deleted at any time by invoking the entity tags delete command followed by the same arguments you used to create them. [ { Key: 'tag1', Values: ['true'], }, { Key: 'tag2', Values: ['test'], }, { Key: 'tag3', Values: ['testing'], }, // ... ]; Copy Next steps Have a look at all the New Relic CLI commands. For example, you could create a New Relic workflow using workload create. If you'd like to engage with other community members, visit our New Relic Explorers Hub page. We welcome feature requests or bug reports on GitHub.",
+ "_index": "520d1d5d14cc8a32e600034b",
+ "_type": "520d1d5d14cc8a32e600034c",
+ "_score": 153.61845,
+ "_version": null,
+ "_explanation": null,
+ "sort": null,
+ "highlight": {
+ "sections": "Install the NewRelicCLI",
+ "tags": "newrelicCLI",
+ "body": " CLI to add multiple tags to one of your entities. Before you begin For this guide you need your NewRelic personal APIKey: Create it at the Account settings screen for your account. Step 1 of 6 Install the NewRelicCLI You can download the NewRelicCLI via Homebrew (macOS), Scoop (Windows"
+ },
+ "id": "5efa999d64441fa74a5f7e2d"
+ },
+ {
+ "sections": [
+ "Get started with the New Relic CLI",
+ "Before you begin",
+ "Install the New Relic CLI",
+ "Linux",
+ "macOS",
+ "Windows",
+ "Create your New Relic CLI profile",
+ "Get your application details",
+ "Add a simple tag to your application",
+ "Bonus step: Create a deployment marker",
+ "Next steps"
+ ],
+ "title": "Get started with the New Relic CLI",
"type": "developer",
"tags": [
- "tags",
- "new relic CLI"
+ "api key",
+ "New Relic CLI",
+ "Tags",
+ "Entity",
+ "Deployment markers"
],
- "external_id": "c7c374812f8295e409a9b06d552de51ceefc666b",
+ "external_id": "531f2f3985bf64bb0dc92a642445887095048882",
"image": "",
- "url": "https://developer.newrelic.com/automate-workflows/5-mins-tag-resources/",
- "published_at": "2020-08-28T01:45:16Z",
- "updated_at": "2020-08-14T01:45:08Z",
+ "url": "https://developer.newrelic.com/automate-workflows/get-started-new-relic-cli/",
+ "published_at": "2020-08-29T01:59:18Z",
+ "updated_at": "2020-08-08T01:41:47Z",
"document_type": "page",
"popularity": 1,
- "info": "Add tags to applications you instrument for easier filtering and organization.",
- "body": "Quickly tag a set of resources 5 min Tags help you group, search, filter, and focus the data about your entities, which can be anything from applications to hosts to services. Tagging entities using the New Relic CLI is a good candidate for automation. In this 5-minute guide, you use the New Relic CLI to add multiple tags to one of your entities. Before you begin For this guide you need your New Relic personal API Key: Create it at the Account settings screen for your account. Step 1 of 6 Install the New Relic CLI You can download the New Relic CLI via Homebrew (macOS), Scoop (Windows), and Snapcraft (Linux). You can also download pre-built binaries for all platforms, including .deb and .rpm packages, and our Windows x64 .msi installer. Linux With Snapcraft installed, run: sudo snap install newrelic-cli macOS With Homebrew installed, run: brew install newrelic-cli Windows With Scoop installed, run: scoop bucket add newrelic-cli https://github.com/newrelic/newrelic-cli.git scoop install newrelic-cli Step 2 of 6 Create your New Relic CLI profile New Relic CLI profiles contain credentials and settings that you can apply to any CLI command. To create your first CLI profile, run the profiles add command. Don't forget to set the region of your New Relic account: use -r to set either us or eu (this is required). # Create the tutorial account for the US region newrelic profiles add -n tutorial --apiKey API_KEY -r us # Set the profile as default newrelic profiles default -n tutorial Copy Step 3 of 6 Search for an entity Your New Relic account might have hundreds of entities: Have a quick look by opening the Entity explorer. In the terminal, run entity search to retrieve a list of entities from your account as JSON. In the example, you're searching for all entities with \"test\" in their name. # Change the `name` to match any of your existing entities newrelic entity search --name \"test\" Copy Step 4 of 6 If there are matching entities in your account, the query yields data in JSON format, similar to this workload example. Select an entity from the results and look for its guid value; the guid is the unique identifier of the entity. Write it down. { \"accountId\": 123456789, \"domain\": \"NR1\", \"entityType\": \"WORKLOAD_ENTITY\", \"guid\": \"F7B7AE59FDED4204B846FB08423DB18E\", \"name\": \"Test workload\", \"reporting\": true, \"type\": \"WORKLOAD\" }, Copy Step 5 of 6 Add tags and tag lists to your entity With your entity guid, you can add tags right away. You can do so by invoking the entities tags create command. What if you want to add multiple tags? You can use tag sets for that: While tags are key-value pairs separated by colons, tag sets are comma-separated lists of tags. For example: tag1:value1,tag2:value2 Note Adding tags is an asynchronous operation: it could take a little while for the tags to get created. # Adding a single tag newrelic entity tags create --guid GUID --tag key:value # Adding multiple tags newrelic entity tags create --guid GUID --tag tag1:test,tag2:test Copy Step 6 of 6 Check that the tags are there To make sure that the tags have been added to your entities, retrieve them using the entity tags get command. All tags associated with your entity are retrieved as a JSON array. newrelic entity tags get --guid GUID Tip Tags can be deleted at any time by invoking the entity tags delete command followed by the same arguments you used to create them. [ { Key: 'tag1', Values: ['true'], }, { Key: 'tag2', Values: ['test'], }, { Key: 'tag3', Values: ['testing'], }, // ... ]; Copy Next steps Have a look at all the New Relic CLI commands. For example, you could create a New Relic workflow using workload create. If you'd like to engage with other community members, visit our New Relic Explorers Hub page. We welcome feature requests or bug reports on GitHub.",
+ "info": "Learn the essentials of the New Relic CLI, from install and configuration to basic usage.",
+ "body": "Get started with the New Relic CLI 20 min Access the New Relic platform from the comfort of your terminal: you can use the New Relic CLI to manage entity tags, define workloads, record deployment markers, and much more. Our CLI has been designed for automating common tasks in your DevOps workflow. This guide walks you through the essentials of New Relic CLI, from install and configuration to basic usage. Before you begin For this guide you just need: Your New Relic personal API Key, which you can create from the Account settings of your New Relic account An instrumented application in your New Relic account Step 1 of 10 Install the New Relic CLI The New Relic CLI can be downloaded via Homebrew (macOS), Scoop (Windows), and Snapcraft (Linux). You can also download pre-built binaries for all platforms, including .deb and .rpm packages, and our Windows x64 .msi installer. Linux With Snapcraft installed, run: sudo snap install newrelic-cli macOS With Homebrew installed, run: brew install newrelic-cli Windows With Scoop installed, run: scoop bucket add newrelic-cli https://github.com/newrelic/newrelic-cli.git scoop install newrelic-cli Step 2 of 10 Create your New Relic CLI profile Now that you've installed the New Relic CLI, it's time to create your first profile. Profiles contain credentials and settings that you can apply to any CLI command, which is useful when switching between accounts. To create your first CLI profile, run the profiles add command. Note that you need to set the region of your New Relic account: use -r to set either us or eu (this is required). # Create the tutorial account for the US region newrelic profiles add -n tutorial --apiKey YOUR_NEW_RELIC_API_KEY -r YOUR_REGION # Set the profile as defaults newrelic profiles default -n tutorial Copy Step 3 of 10 Get your application details In this example, you are going to add tags to the application you've instrumented with New Relic. Tags are key-value pairs that can help you organize and filter your entities. An entity (for example, an application) can have a maximum of 100 key-value pairs tied to it. Before searching for your application using the New Relic CLI, write down or copy your Account ID and the name of your application in New Relic - you need both to find applications in the New Relic platform. Step 4 of 10 The New Relic CLI can retrieve your application details as a JSON object. To search for your APM application use the apm application search command. If you get an error, check that the account ID and application name you provided are correct. newrelic apm application search --accountId YOUR_ACCOUNT_ID --name NAME_OF_YOUR_APP Copy Step 5 of 10 If the account ID is valid, and the application name exists in your account, apm application search yields data similar to this example. When you've successfully searched for your application, look for the guid value. It's a unique identifier for your application. You should copy it or write it down. [ { accountId: YOUR_ACCOUNT_ID, applicationId: YOUR_APP_ID, domain: 'APM', entityType: 'APM_APPLICATION_ENTITY', guid: 'A_LONG_GUID', name: 'NAME_OF_YOUR_APP', permalink: 'https://one.newrelic.com/redirect/entity/A_LONG_GUID', reporting: true, type: 'APPLICATION', }, ]; Copy Step 6 of 10 Add a simple tag to your application Now that you have the GUID, you can point the New Relic CLI directly at your application. Adding a tag is the simplest way to try out the CLI capabilities (don't worry, tags can be deleted by using entity tags delete). Let's suppose that you want to add an environment tag to your application. Go ahead and add the dev:testing tag (or any other key-value pair) to your application using the entities tags create command. newrelic entity tags create --guid YOUR_APP_GUID --tag devkit:testing Copy Step 7 of 10 What if you want to add multiple tags? Tag sets come to the rescue! While tags are key-value pairs separated by colons, tag sets are comma separated lists of tags. For example: tag1:value1,tag2:value2 To add multiple tags at once to your application, modify and run the following snippet. newrelic entity tags create --guid YOUR_APP_GUID --tag tag1:test,tag2:test Copy Adding tags is an asynchronous operation: this means it could take a while for the tags to get created. Step 8 of 10 You've created and added some tags to your application, but how do you know they're there? You need to retrieve your application's tags. To retrieve your application's tags, use the entity tags get command. newrelic entity tags get --guid YOUR_APP_GUID All tags associated with your application are retrieved as a JSON array. [ { Key: 'tag1', Values: ['true'], }, { Key: 'tag2', Values: ['test'], }, { Key: 'tag3', Values: ['testing'], }, // ... ]; Copy Step 9 of 10 Bonus step: Create a deployment marker Deployments of applications often go wrong. Deployment markers are labels that, when attached to your application data, help you track deployments and troubleshoot what happened. To create a deployment marker, run the apm deployment create command using the same Application ID from your earlier search. newrelic apm deployment create --applicationId YOUR_APP_ID --revision $(git describe --tags --always) Copy Step 10 of 10 Notice that the JSON response includes the revision and timestamp of the deployment. This workflow could be built into a continuous integration or continuous deployment (CI/CD) system to help indicate changes in your application's behavior after deployments. Here is an example. { \"id\": 37075986, \"links\": { \"application\": 204261368 }, \"revision\": \"v1.2.4\", \"timestamp\": \"2020-03-04T15:11:44-08:00\", \"user\": \"Developer Toolkit Test Account\" } Copy Next steps Have a look at all the available commands. For example, you could create a New Relic workflow using workload create If you'd like to engage with other community members, visit our New Relic Explorers Hub page. We welcome feature requests or bug reports on GitHub.",
"_index": "520d1d5d14cc8a32e600034b",
"_type": "520d1d5d14cc8a32e600034c",
- "_score": 157.04158,
+ "_score": 149.41269,
"_version": null,
"_explanation": null,
"sort": null,
"highlight": {
- "sections": "Install the NewRelicCLI",
- "tags": "newrelicCLI",
- "body": " CLI to add multiple tags to one of your entities. Before you begin For this guide you need your NewRelic personal APIKey: Create it at the Account settings screen for your account. Step 1 of 6 Install the NewRelicCLI You can download the NewRelicCLI via Homebrew (macOS), Scoop (Windows"
+ "title": "Get started with the NewRelicCLI",
+ "sections": "Get started with the NewRelicCLI",
+ "info": "Learn the essentials of the NewRelicCLI, from install and configuration to basic usage.",
+ "tags": "NewRelicCLI",
+ "body": ". This guide walks you through the essentials of NewRelicCLI, from install and configuration to basic usage. Before you begin For this guide you just need: Your NewRelic personal APIKey, which you can create from the Account settings of your NewRelicaccount An instrumented application in your"
},
- "id": "5efa999d64441fa74a5f7e2d"
+ "id": "5efa999c196a67c4e1766461"
},
{
"sections": [
@@ -6222,7 +6485,7 @@
"external_id": "63283ee8efdfa419b6a69cb8bd135d4bc2188d2c",
"image": "https://developer.newrelic.com/static/f6d5070509ac08ec96c6c522d5109471/b01d9/apps_catalog.png",
"url": "https://developer.newrelic.com/build-apps/publish-deploy/",
- "published_at": "2020-08-28T01:51:50Z",
+ "published_at": "2020-08-29T01:56:37Z",
"updated_at": "2020-08-26T01:50:42Z",
"document_type": "page",
"popularity": 1,
@@ -6230,7 +6493,7 @@
"body": "Serve, publish, and deploy your New Relic One app 30 min When you build a New Relic One app, chances are you'll want to share it with others in your organization. You might even want to share it broadly through our open source channel. But first, you probably want to try it out locally to make sure it's working properly. From the New Relic One Apps page, you can review available apps and subscribe to the ones you want for accounts you manage. The Other apps section shows launchers for New Relic apps, as well as any third-party apps that you subscribe to. The New Relic One catalog provides apps that you haven't subscribed to, some developed by New Relic engineers to provide visualizations we think you'll want, like Cloud Optimizer, which analyzes your cloud environment, or PageView Map, which uses Browser events to chart performance across geographies. Other apps in the catalog are created by third-party contributors and are submitted via opensource.newrelic.com. All are intended to help you visualize the data you need, the way you want it. Here, you learn to: Serve your app locally Add images and metadata to your app Publish it Subscribe and unsubscribe accounts you manage to the app Handle duplicate applications Before you begin This guide requires the following: A New Relic One app or Nerdpack New Relic One CLI A Nerdpack manager role for publishing, deploying, and subscribing apps. Serve your app locally You can locally serve the app you create to New Relic One to test it out. Step 1 of 1 In the parent root folder of your Nerdpack, run nr1 nerdpack:serve. Go to one.newrelic.com/?nerdpacks=local. The ?nerdpacks=local URL suffix will load any locally served Nerdpacks that are available. When you make a change to a locally served Nerdpack, New Relic One will automatically reload it. Add images and metadata to your apps Application creators can include a description of what their apps do and how they're best used when they build an app. They can also include screenshots, icons, and metadata that help to make them easy to spot amongst other applications. Some metadata is added automatically when an app is published: Related entities, listed if there are any. Origin label to indicate where the app comes from: local, custom, or public. The New Relic One CLI enables you to provide the information and images you want to include with your application. Then it's a matter of kicking off a catalog command that validates the information and saves it to the catalog. Step 1 of 3 Update the New Relic One CLI to ensure you're working with the latest version. nr1 update Copy Step 2 of 3 Add catalog metadata and screenshots. Run nr1 create and then select catalog to add a catalog folder to your New Relic One project. The folder contains the following empty files and folder. Add the information as described in the following table for the process to succeed. screenshots folder A directory that must contain no more than 6 images and meet these criteria: 3:2 aspect ratio PNG format landscape orientation 1600 to 2400 pixels wide documentation.md A markdown file that presents usage information pulled into the Documentation tab for the application in the catalog. additionalInfo.md An optional markdown file for any additional information about using your application. config.json A JSON file that contains the following fields: tagline: A brief headline for the application. Must not exceed 30 characters. repository: The URL to the GitHub repo for the application. Must not exceed 1000 characters. details: Describes the purpose of the application and how to use it. Information must not exceed 1000. Use carriage returns for formatting. Do not include any markdown or HTML. support: An object that contains: issues: A valid URL to the GitHub repository's issues list, generally the GitHub Issues tab for the repo. email: A valid email address for the team supporting the application. community: URL to a support thread, forum, or website for troubleshooting and usage support. whatsNew: A bulleted list of changes in this version. Must not exceed 500 characters. Use carriage returns for formatting. Do not include markdown or HTML. Example: { \"tagline\": \"Map your workloads & entities\", \"repository\": \"https://github.com/newrelic/nr1-workload-geoops.git\", \"details\": \"Describe, consume, and manage Workloads and Entities in a geographic model that supports location-specific KPI's, custom metadata, drill-down navigation into Entities and Workloads, real-time configuration, and configuration via automation using the newrelic-cli.\", \"support\": { \"issues\": { \"url\": \"https://github.com/newrelic/nr1-workload-geoops/issues\" }, \"email\": { \"address\": \"opensource+nr1-workload-geoops@newrelic.com\" }, \"community\": { \"url\": \"https://discuss.newrelic.com/t/workload-geoops-nerdpack/99478\" } }, \"whatsNew\": \"\\n-Feat: Geographic mapping of Workloads and Entities\\n-Feat: Programmatic alerting rollup of underlying Entities\\n-Feat: Custom KPI measurement per location\\n-Feat: Empty-state edit workflow\\n-Feat: JSON file upload format\\n-Feat: Published (in open source docs) guide to automating configuration using the newrelic-cli\" } Copy Step 3 of 3 Save the metadata and screenshots to the catalog. This validates the information you added to the catalog directory against the criteria described in the previous step, and saves it to the catalog. nr1 catalog:submit Copy Publish your app Publishing places your Nerdpack in New Relic One. To publish or deploy, you must be a Nerdpack manager. Step 1 of 1 To publish your Nerdpack, run nr1 nerdpack:publish. Deploy your app Deploying is applying a Nerdpack version to a specific channel (for example, BETA, or STABLE). A channel can only have one Nerdpack version deployed to it at one time. If a channel has an existing Nerdpack associated with it, deploying a new Nerdpack version to that channel will undeploy the previous one. Channels are meant to be an easier way to control application version access than having to be concerned with specific version numbers. Step 1 of 1 To deploy an application, run nr1 nerdpack:deploy. Subscribe or unsubsribe apps Whether you want to subscribe accounts to an app you've created or to apps already available in the catalog, the process is the same. Note that if you subscribe to an app in the catalog, you'll automatically get any updates that are added to the app. To learn about the appropriate permissions for subscribing, see Permissions for managing applications. Step 1 of 2 Subscribe accounts to an application. Select an application you want to add to your New Relic account. Click Add this app. Note that this button says Manage access if the app has already been subscribed to an account you manage. On the Account access page listing the accounts you can subscribe to an application: Select the accounts you want to subscribe the app to. Choose the channel you want to subscribe the app to, Stable or Dev. This can only be Stable for the public apps created by New Relic. Click the update button. Now you and members of the accounts you have subscribed to the app can launch it from New Relic One. Step 2 of 2 Unsubsribe from an application. On the Apps page, open the app you want to unsubscribe. Click Manage access. Clear the check box for any accounts you want to unsubscribe, and then click the update button. The application is no longer listed in the Other apps section of the Apps page, and you have unsubscribed. Handle duplicate applications You might end up with duplicate applications on your New Relic One Apps page. This can happen when you subscribe to the same app using both the CLI and the catalog. Or if you clone an app, modify, and deploy it, but keep the original name. You can manage duplicates with the catalog. Good to know before you start: You need a user role with the ability to manage Nerdpacks for accounts that you want to unsubscribe and undeploy from applications. You can't remove the public apps. When a duplicate application has no accounts subscribed to it, you undeploy it. For applications that have accounts subscribed to them, you unscubscribe and undeploy. The unsubscribe and undeploy process happens in a batch. To remove an account from an application, but ensure that other accounts continue to be subscribed, select the checkbox, Resubscribe these accounts to the new application. Step 1 of 1 Remove duplicates. In the New Relic One catalog, click a public application that has one or more duplicates. (You can only manage duplicates from the public version of the application.) On the application information page, select Clean up applications. Review the information about the application that's open, as well as any duplicates. Click Manage app for duplicates you want to remove. If needed, select Resubscribe these accounts to the new application. Click Unsubscribe and undeploy, and agree to the terms and conditions.",
"_index": "520d1d5d14cc8a32e600034b",
"_type": "520d1d5d14cc8a32e600034c",
- "_score": 156.5933,
+ "_score": 147.76434,
"_version": null,
"_explanation": null,
"sort": null,
@@ -6241,98 +6504,55 @@
"body": " to the app Handle duplicate applications Before you begin This guide requires the following: A NewRelicOne app or Nerdpack NewRelicOneCLI A Nerdpack manager role for publishing, deploying, and subscribing apps. Serve your app locally You can locally serve the app you create to NewRelicOne to test"
},
"id": "5efa999de7b9d283e67bab8f"
- },
- {
- "sections": [
- "Get started with the New Relic CLI",
- "Before you begin",
- "Install the New Relic CLI",
- "Linux",
- "macOS",
- "Windows",
- "Create your New Relic CLI profile",
- "Get your application details",
- "Add a simple tag to your application",
- "Bonus step: Create a deployment marker",
- "Next steps"
- ],
- "title": "Get started with the New Relic CLI",
- "type": "developer",
- "tags": [
- "api key",
- "New Relic CLI",
- "Tags",
- "Entity",
- "Deployment markers"
- ],
- "external_id": "531f2f3985bf64bb0dc92a642445887095048882",
- "image": "",
- "url": "https://developer.newrelic.com/automate-workflows/get-started-new-relic-cli/",
- "published_at": "2020-08-28T01:50:39Z",
- "updated_at": "2020-08-08T01:41:47Z",
- "document_type": "page",
- "popularity": 1,
- "info": "Learn the essentials of the New Relic CLI, from install and configuration to basic usage.",
- "body": "Get started with the New Relic CLI 20 min Access the New Relic platform from the comfort of your terminal: you can use the New Relic CLI to manage entity tags, define workloads, record deployment markers, and much more. Our CLI has been designed for automating common tasks in your DevOps workflow. This guide walks you through the essentials of New Relic CLI, from install and configuration to basic usage. Before you begin For this guide you just need: Your New Relic personal API Key, which you can create from the Account settings of your New Relic account An instrumented application in your New Relic account Step 1 of 10 Install the New Relic CLI The New Relic CLI can be downloaded via Homebrew (macOS), Scoop (Windows), and Snapcraft (Linux). You can also download pre-built binaries for all platforms, including .deb and .rpm packages, and our Windows x64 .msi installer. Linux With Snapcraft installed, run: sudo snap install newrelic-cli macOS With Homebrew installed, run: brew install newrelic-cli Windows With Scoop installed, run: scoop bucket add newrelic-cli https://github.com/newrelic/newrelic-cli.git scoop install newrelic-cli Step 2 of 10 Create your New Relic CLI profile Now that you've installed the New Relic CLI, it's time to create your first profile. Profiles contain credentials and settings that you can apply to any CLI command, which is useful when switching between accounts. To create your first CLI profile, run the profiles add command. Note that you need to set the region of your New Relic account: use -r to set either us or eu (this is required). # Create the tutorial account for the US region newrelic profiles add -n tutorial --apiKey YOUR_NEW_RELIC_API_KEY -r YOUR_REGION # Set the profile as defaults newrelic profiles default -n tutorial Copy Step 3 of 10 Get your application details In this example, you are going to add tags to the application you've instrumented with New Relic. Tags are key-value pairs that can help you organize and filter your entities. An entity (for example, an application) can have a maximum of 100 key-value pairs tied to it. Before searching for your application using the New Relic CLI, write down or copy your Account ID and the name of your application in New Relic - you need both to find applications in the New Relic platform. Step 4 of 10 The New Relic CLI can retrieve your application details as a JSON object. To search for your APM application use the apm application search command. If you get an error, check that the account ID and application name you provided are correct. newrelic apm application search --accountId YOUR_ACCOUNT_ID --name NAME_OF_YOUR_APP Copy Step 5 of 10 If the account ID is valid, and the application name exists in your account, apm application search yields data similar to this example. When you've successfully searched for your application, look for the guid value. It's a unique identifier for your application. You should copy it or write it down. [ { accountId: YOUR_ACCOUNT_ID, applicationId: YOUR_APP_ID, domain: 'APM', entityType: 'APM_APPLICATION_ENTITY', guid: 'A_LONG_GUID', name: 'NAME_OF_YOUR_APP', permalink: 'https://one.newrelic.com/redirect/entity/A_LONG_GUID', reporting: true, type: 'APPLICATION', }, ]; Copy Step 6 of 10 Add a simple tag to your application Now that you have the GUID, you can point the New Relic CLI directly at your application. Adding a tag is the simplest way to try out the CLI capabilities (don't worry, tags can be deleted by using entity tags delete). Let's suppose that you want to add an environment tag to your application. Go ahead and add the dev:testing tag (or any other key-value pair) to your application using the entities tags create command. newrelic entity tags create --guid YOUR_APP_GUID --tag devkit:testing Copy Step 7 of 10 What if you want to add multiple tags? Tag sets come to the rescue! While tags are key-value pairs separated by colons, tag sets are comma separated lists of tags. For example: tag1:value1,tag2:value2 To add multiple tags at once to your application, modify and run the following snippet. newrelic entity tags create --guid YOUR_APP_GUID --tag tag1:test,tag2:test Copy Adding tags is an asynchronous operation: this means it could take a while for the tags to get created. Step 8 of 10 You've created and added some tags to your application, but how do you know they're there? You need to retrieve your application's tags. To retrieve your application's tags, use the entity tags get command. newrelic entity tags get --guid YOUR_APP_GUID All tags associated with your application are retrieved as a JSON array. [ { Key: 'tag1', Values: ['true'], }, { Key: 'tag2', Values: ['test'], }, { Key: 'tag3', Values: ['testing'], }, // ... ]; Copy Step 9 of 10 Bonus step: Create a deployment marker Deployments of applications often go wrong. Deployment markers are labels that, when attached to your application data, help you track deployments and troubleshoot what happened. To create a deployment marker, run the apm deployment create command using the same Application ID from your earlier search. newrelic apm deployment create --applicationId YOUR_APP_ID --revision $(git describe --tags --always) Copy Step 10 of 10 Notice that the JSON response includes the revision and timestamp of the deployment. This workflow could be built into a continuous integration or continuous deployment (CI/CD) system to help indicate changes in your application's behavior after deployments. Here is an example. { \"id\": 37075986, \"links\": { \"application\": 204261368 }, \"revision\": \"v1.2.4\", \"timestamp\": \"2020-03-04T15:11:44-08:00\", \"user\": \"Developer Toolkit Test Account\" } Copy Next steps Have a look at all the available commands. For example, you could create a New Relic workflow using workload create If you'd like to engage with other community members, visit our New Relic Explorers Hub page. We welcome feature requests or bug reports on GitHub.",
- "_index": "520d1d5d14cc8a32e600034b",
- "_type": "520d1d5d14cc8a32e600034c",
- "_score": 149.63907,
- "_version": null,
- "_explanation": null,
- "sort": null,
- "highlight": {
- "title": "Get started with the NewRelicCLI",
- "sections": "Get started with the NewRelicCLI",
- "info": "Learn the essentials of the NewRelicCLI, from install and configuration to basic usage.",
- "tags": "NewRelicCLI",
- "body": ". This guide walks you through the essentials of NewRelicCLI, from install and configuration to basic usage. Before you begin For this guide you just need: Your NewRelic personal APIKey, which you can create from the Account settings of your NewRelicaccount An instrumented application in your"
- },
- "id": "5efa999c196a67c4e1766461"
}
],
- "/explore-docs/nr1-catalog": [
+ "/build-apps/permission-manage-apps": [
{
+ "category_2": "Build on New Relic One",
+ "nodeid": 37996,
"sections": [
- "New Relic One CLI reference",
- "Installing the New Relic One CLI",
- "Tip",
- "New Relic One CLI Commands",
+ "Use New Relic One",
"Get started",
- "Configure your CLI preferences",
- "Set up your Nerdpacks",
- "Manage your Nerdpack subscriptions",
- "Install and manage plugins",
- "Manage catalog information"
- ],
- "title": "New Relic One CLI reference",
- "type": "developer",
- "tags": [
- "New Relic One app",
- "nerdpack commands"
+ "Core concepts",
+ "UI and data",
+ "Workloads",
+ "Build on New Relic One",
+ "Discover and manage New Relic One applications",
+ "Create and share open source apps",
+ "Permission for managing applications",
+ "Add images and metadata to your apps",
+ "Subscribe accounts to an application",
+ "Unsubscribe to an application",
+ "Handle duplicate applications",
+ "For more help"
],
- "external_id": "858339a44ead21c83257778ce60b4c352cd30d3b",
- "image": "https://developer.newrelic.com/static/2c6d337608b38a3312b4fc740afe6167/7272b/developercenter.png",
- "url": "https://developer.newrelic.com/explore-docs/nr1-cli/",
- "published_at": "2020-08-28T01:50:39Z",
- "updated_at": "2020-08-18T01:50:36Z",
+ "title": "Discover and manage New Relic One applications",
+ "category_0": "New Relic One",
+ "type": "docs",
+ "category_1": "Use New Relic One",
+ "external_id": "66a00fb098d21829d83384d8948e701cd9aa86f0",
+ "image": "https://docs.newrelic.com/sites/default/files/thumbnails/image/nr1_catalog_0.png",
+ "url": "https://docs.newrelic.com/docs/new-relic-one/use-new-relic-one/build-new-relic-one/discover-manage-applications-new-relic-one-catalog",
+ "published_at": "2020-08-25T18:46:47Z",
+ "updated_at": "2020-08-11T05:10:23Z",
+ "breadcrumb": "Contents / New Relic One / Use New Relic One / Build on New Relic One",
"document_type": "page",
"popularity": 1,
- "info": "An overview of the CLI to help you build, deploy, and manage New Relic apps.",
- "body": "New Relic One CLI reference To build a New Relic One app, you must install the New Relic One CLI. The CLI helps you build, publish, and manage your New Relic app. We provide a variety of tools for building apps, including the New Relic One CLI (command line interface). This page explains how to use CLI commands to: Generate Nerdpack/Nerdlet templates Locally serve Nerdpacks (when developing) Publish and deploy Subscribe to Nerdpacks Add screenshots and metadata to the catalog Installing the New Relic One CLI In New Relic, click Apps and then in the New Relic One catalog area, click the Build your own application launcher and follow the quick start instructions. The quick start automatically generates an API key for the account you select, and gives you the pre-populated commands to create a profile, generate your first \"Hello World\" app, and serve it locally. Tip Use the NR1 VS Code extension to build your apps. New Relic One CLI Commands This table provides descriptions for the New Relic One commands. For more context, including usage and option details, click any individual command or the command category. For details on user permissions, see Authentication and permissions. For more on how to serve and publish your application, see our guide on Deploying your New Relic One app. Get started nr1 help Shows all nr1 commands or details about each command. nr1 update Updates to the latest version of the CLI. nr1 create Creates a new component from a template (Nerdpack, Nerdlet, launcher, or catalog). nr1 profiles Manages the profiles you use to run CLI commands. nr1 autocomplete Displays autocomplete installation instructions. nr1 nrql Fetches data using NRQL (New Relic query language). Configure your CLI preferences nr1 config:set Sets a specific configuration value. nr1 config:get Shows a specific configuration. nr1 config:list Lists your configuration choices. nr1 config:delete Removes the value of a specific configuration. Set up your Nerdpacks nr1 nerdpack:clone Clones an open source Nerdpack from our GitHub repository. nr1 nerdpack:serve Serves your Nerdpack for testing and development purposes. nr1 nerdpack:uuid Shows or regenerates the UUID of a Nerdpack. nr1 nerdpack:publish Publishes your Nerdpack to New Relic. nr1 nerdpack:deploy Deploys a Nerdpack version to a specific channel. nr1 nerdpack:undeploy Undeploys a Nerdpack version from a specific channel. Manage your Nerdpack subscriptions nr1 subscription:set Subscribes your account to a Nerdpack and channel. nr1 subscription:list Lists all the Nerdpacks your account is subscribed to. nr1 subscription:unset Unsubscribes your account from a Nerdpack. Install and manage plugins nr1 plugins:install Installs a plugin into the CLI. nr1 plugins:link Links a plugin into the CLI for development. nr1 plugins:update Updates your installed plugins. nr1 plugins:uninstall Removes a plugin from the CLI. Manage catalog information nr1 catalog:info Shows the Nerdpack info stored in the catalog. nr1 catalog:submit Gathers and submits the catalog info on the current folder.",
+ "info": "About the New Relic One catalog, where you can subscribe to open source New Relic One applications, and to which you can deploy your own custom apps. ",
+ "body": "Developers are creating new and innovative apps that extend and enhance your data views. From New Relic One's apps page, you can subscribe to apps you create, publish, and deploy, as well as those created by New Relic engineers and other organizations. You can also launch the apps you subscribe to. Just select Apps from the New Relic One home page to see what's available. one.newrelic.com > Apps: Under the New Relic One catalog section, you can subscribe to applications. Create and share open source apps The Other apps section shows launchers for New Relic apps, as well as any third-party apps that you subscribe to. The New Relic One catalog provides apps that you haven't subscribed to, some developed by New Relic engineers to provide information we think you'll want, like Cloud Optimizer, which analyzes your cloud environment, or PageView Map, which uses Browser events to chart performance across geographies. Other apps in the catalog are created by third-party contributors and are submitted via opensource.newrelic.com. All are intended to help you visualize the data you need, the way you want it. If you’ve started to develop applications on the New Relic One platform, you probably want to share them with your broader organization. That’s where the catalog comes in. When you publish and deploy your app, it’s available to you in the catalog. You can manage the information that you want to share about your application, as well as how it appears on the New Relic One app page. You can also subscribe accounts to it. Permission for managing applications User permissions vary depending on which pricing plan you are on: New Relic One pricing plan For accounts with New Relic One pricing, there are permissions differences for basic users and full users: Full users have the Nerdpack Manager role and have full capabilities for creating and managing New Relic One applications as well as accessing all types of applications in the New Relic One catalog. A basic user can develop and view their own local New Relic One apps, but they cannot: Subscribe other users to apps they’ve created. Access or manage apps in the New Relic One catalog. Access apps in the entity explorer sidebar. Original product-based pricing For accounts on our original product-based pricing, here are access details: Subscribe to publicly available applications To subscribe to publicly available applications, you must have the Nerdpack manager role. Nerdpack manager permissions are automatically assigned to New Relic account owners and admins and can be assigned to individual users. If you aren’t an owner or admin, you can request Nerdpack manager permission, or ask your New Relic admin or owner to subscribe the apps to your account for you. You can add any of the publicly available applications to master accounts or separate sub-accounts on which you have the Nerdpack manager role, or to separate sub-accounts under a master account you own or administer. If you add the application to a master account, the access flows to all of its sub-accounts as well. Subscribe to applications that you create You also must have the Nerdpack manager role to subscribe the applications you create to accounts. Applications that you publish and deploy can only be subscribed to the master account that was used to publish them, or to its sub-accounts. This means you might want a New Relic admin to deploy your applications for you if they need to be available across the organization. Add images and metadata to your apps Application creators can include a description of what the apps do and how they're best used when they build an app. They can also include screenshots, icons, and metadata that help to make them easy to spot amongst other applications. Some metadata is added automatically when an app is published: Related entities, listed if there are any. Origin label to indicate where the app comes from: local (you made it!), custom, or public. Browser Analyzer app with browser app entity listed, plus duplicate clean up tab. The New Relic One CLI enables you to provide the information and images you want to include with your application. Then it's a matter of kicking off a catalog command that validates the information and saves it to the catalog. When you create an application by running nr1 create, a generic icon.png file is added to your project. Replace this with an icon of your choice, but keep the file name icon.png to update your application's icon in the catalog. 1. Update the New Relic One CLI Make sure you have the latest version of the New Relic One CLI by running nr1 update. 2. Add catalog metadata and screenshots Run nr1 create and then select catalog to add a catalog folder to your New Relic One project. The folder contains the following empty files and folder. Add the information as described in the following table for the process to succeed. File Requirements screenshots folder A directory that must contain no more than 6 images and meet these criteria: 3:2 aspect ratio PNG format landscape orientation 1600 to 2400 pixels wide documentation.md A markdown file that presents usage information pulled into the Documentation tab for the application in the catalog. additionalInfo.md An optional markdown file for any additional information about using your application. config.json A JSON file that contains the following fields: tagline: A brief headline for the application. Must not exceed 30 characters. repository: The URL to the GitHub repo for the application. Must not exceed 1000 characters. details: Describes the purpose of the application and how to use it. Information must not exceed 1000. Use carriage returns for formatting. Do not include any markdown or HTML. support: An object that contains: issues: A valid URL to the GitHub repository's issues list, generally the GitHub Issues tab for the repo. email: A valid email address for the team supporting the application. community: URL to a support thread, forum, or website for troubleshooting and usage support. whatsNew: A bulleted list of changes in this version. Must not exceed 500 characters. Use carriage returns for formatting. Do not include markdown or HTML. Example: { \"tagline\": \"Map your workloads & entities\", \"repository\": \"https://github.com/newrelic/nr1-workload-geoops.git\", \"details\": \"Describe, consume, and manage Workloads and Entities in a geographic model that supports location-specific KPI's, custom metadata, drill-down navigation into Entities and Workloads, real-time configuration, and configuration via automation using the newrelic-cli.\", \"support\": { \"issues\": { \"url\": \"https://github.com/newrelic/nr1-workload-geoops/issues\" }, \"email\": { \"address\": \"opensource+nr1-workload-geoops@newrelic.com\" }, \"community\": { \"url\": \"https://discuss.newrelic.com/t/workload-geoops-nerdpack/99478\" } }, \"whatsNew\": \"\\n-Feat: Geographic mapping of Workloads and Entities\\n-Feat: Programmatic alerting rollup of underlying Entities\\n-Feat: Custom KPI measurement per location\\n-Feat: Empty-state edit workflow\\n-Feat: JSON file upload format\\n-Feat: Published (in open source docs) guide to automating configuration using the newrelic-cli\" } 3. Save the metadata and screenshots to the catalog Run nr1 catalog:submit. This validates the information you added to the catalog directory against the criteria described in the previous step, and saves it to the catalog. Subscribe accounts to an application Select an application you want to add to your New Relic account. Click Add this app. Note that this button says Manage access if the app has already been subscribed to an account you manage. On the Account access page listing the accounts you can subscribe to an application: - Select the accounts you want to subscribe the app to. - Choose the channel you want to subscribe the app to, Stable or Dev. This can only be Stable for the Public apps created by New Relic. - Click the update button. Now you and the accounts you subscribed to the app can launch it from New Relic One. Unsubscribe to an application On the Apps page, open the app you want to unsubscribe. Click Manage access. Clear the check box for any accounts you want to unsubscribe, and then click the update button. The application is no longer listed in the Other apps section of the Apps page, and you have unsubscribed. Handle duplicate applications You might end up with duplicate applications on your New Relic One Apps page. This can happen when you subscribe to the same app using both the CLI and the catalog. Or if you clone an app, modify and deploy it, but keep the original name. You can manage duplicates with the catalog. Good to know before you start: You need a user role with the ability to manage Nerdpacks for accounts that you want to unsubscribe and undeploy from applications. You can't remove the public apps. When a duplicate application has no accounts subscribed to it, you undeploy it. For applications that have accounts subscribed to them, you unscubscribe and undeploy. The unsubscribe and undeploy process happens in a batch. To remove an account from an application, but ensure that other accounts continue to be subscribed, select the checkbox, Resubscribe these accounts to the new application. Remove duplicates In the New Relic One catalog, click a public application that has one or more duplicates. (You can only manage duplicates from the public version of the application.) On the application information page, select Clean up applications. Review the information about the application that's open, as well as any duplicates. Click Manage app for duplicates you want to remove. If needed, select Resubscribe these accounts to the new application. Click Unsubscribe and undeploy, and agree to the terms and conditions. For more help Additional documentation resources include: Add-on roles for learning about Nerdpack manager permissions Permissions for managing applications Take a tour of the catalog If you need more help, check out these support and learning resources: Browse the Explorers Hub to get help from the community and join in discussions. Find answers on our sites and learn how to use our support portal. Run New Relic Diagnostics, our troubleshooting tool for Linux, Windows, and macOS. Review New Relic's data security and licenses documentation.",
"_index": "520d1d5d14cc8a32e600034b",
"_type": "520d1d5d14cc8a32e600034c",
- "_score": 337.79315,
+ "_score": 143.86392,
"_version": null,
"_explanation": null,
"sort": null,
"highlight": {
- "title": "NewRelicOneCLI reference",
- "sections": "NewRelicOneCLICommands",
- "info": "An overview of the CLI to help you build, deploy, and manage NewRelic apps.",
- "tags": "NewRelicOne app",
- "body": " CLIcommands to: Generate Nerdpack/Nerdlet templates Locally serve Nerdpacks (when developing) Publish and deploy Subscribe to Nerdpacks Add screenshots and metadata to the catalog Installing the NewRelicOneCLI In NewRelic, click Apps and then in the NewRelicOnecatalog area, click the Build"
+ "title": "Discover and manage New Relic One applications",
+ "sections": "Permission for managingapplications",
+ "info": "About the New Relic One catalog, where you can subscribe to open source New Relic One applications, and to which you can deploy your own custom apps. ",
+ "body": " the NerdpackManager role and have full capabilities for creating and managing New Relic One applications as well as accessing all types of applications in the New Relic One catalog. A basic user can develop and view their own local New Relic One apps, but they cannot: Subscribe other users to apps they’ve"
},
- "id": "5efa989e28ccbc535a307dd0"
+ "id": "5e836492196a679b4102bd12"
},
{
"sections": [
@@ -6360,7 +6580,7 @@
"external_id": "63283ee8efdfa419b6a69cb8bd135d4bc2188d2c",
"image": "https://developer.newrelic.com/static/f6d5070509ac08ec96c6c522d5109471/b01d9/apps_catalog.png",
"url": "https://developer.newrelic.com/build-apps/publish-deploy/",
- "published_at": "2020-08-28T01:51:50Z",
+ "published_at": "2020-08-29T01:56:37Z",
"updated_at": "2020-08-26T01:50:42Z",
"document_type": "page",
"popularity": 1,
@@ -6368,145 +6588,137 @@
"body": "Serve, publish, and deploy your New Relic One app 30 min When you build a New Relic One app, chances are you'll want to share it with others in your organization. You might even want to share it broadly through our open source channel. But first, you probably want to try it out locally to make sure it's working properly. From the New Relic One Apps page, you can review available apps and subscribe to the ones you want for accounts you manage. The Other apps section shows launchers for New Relic apps, as well as any third-party apps that you subscribe to. The New Relic One catalog provides apps that you haven't subscribed to, some developed by New Relic engineers to provide visualizations we think you'll want, like Cloud Optimizer, which analyzes your cloud environment, or PageView Map, which uses Browser events to chart performance across geographies. Other apps in the catalog are created by third-party contributors and are submitted via opensource.newrelic.com. All are intended to help you visualize the data you need, the way you want it. Here, you learn to: Serve your app locally Add images and metadata to your app Publish it Subscribe and unsubscribe accounts you manage to the app Handle duplicate applications Before you begin This guide requires the following: A New Relic One app or Nerdpack New Relic One CLI A Nerdpack manager role for publishing, deploying, and subscribing apps. Serve your app locally You can locally serve the app you create to New Relic One to test it out. Step 1 of 1 In the parent root folder of your Nerdpack, run nr1 nerdpack:serve. Go to one.newrelic.com/?nerdpacks=local. The ?nerdpacks=local URL suffix will load any locally served Nerdpacks that are available. When you make a change to a locally served Nerdpack, New Relic One will automatically reload it. Add images and metadata to your apps Application creators can include a description of what their apps do and how they're best used when they build an app. They can also include screenshots, icons, and metadata that help to make them easy to spot amongst other applications. Some metadata is added automatically when an app is published: Related entities, listed if there are any. Origin label to indicate where the app comes from: local, custom, or public. The New Relic One CLI enables you to provide the information and images you want to include with your application. Then it's a matter of kicking off a catalog command that validates the information and saves it to the catalog. Step 1 of 3 Update the New Relic One CLI to ensure you're working with the latest version. nr1 update Copy Step 2 of 3 Add catalog metadata and screenshots. Run nr1 create and then select catalog to add a catalog folder to your New Relic One project. The folder contains the following empty files and folder. Add the information as described in the following table for the process to succeed. screenshots folder A directory that must contain no more than 6 images and meet these criteria: 3:2 aspect ratio PNG format landscape orientation 1600 to 2400 pixels wide documentation.md A markdown file that presents usage information pulled into the Documentation tab for the application in the catalog. additionalInfo.md An optional markdown file for any additional information about using your application. config.json A JSON file that contains the following fields: tagline: A brief headline for the application. Must not exceed 30 characters. repository: The URL to the GitHub repo for the application. Must not exceed 1000 characters. details: Describes the purpose of the application and how to use it. Information must not exceed 1000. Use carriage returns for formatting. Do not include any markdown or HTML. support: An object that contains: issues: A valid URL to the GitHub repository's issues list, generally the GitHub Issues tab for the repo. email: A valid email address for the team supporting the application. community: URL to a support thread, forum, or website for troubleshooting and usage support. whatsNew: A bulleted list of changes in this version. Must not exceed 500 characters. Use carriage returns for formatting. Do not include markdown or HTML. Example: { \"tagline\": \"Map your workloads & entities\", \"repository\": \"https://github.com/newrelic/nr1-workload-geoops.git\", \"details\": \"Describe, consume, and manage Workloads and Entities in a geographic model that supports location-specific KPI's, custom metadata, drill-down navigation into Entities and Workloads, real-time configuration, and configuration via automation using the newrelic-cli.\", \"support\": { \"issues\": { \"url\": \"https://github.com/newrelic/nr1-workload-geoops/issues\" }, \"email\": { \"address\": \"opensource+nr1-workload-geoops@newrelic.com\" }, \"community\": { \"url\": \"https://discuss.newrelic.com/t/workload-geoops-nerdpack/99478\" } }, \"whatsNew\": \"\\n-Feat: Geographic mapping of Workloads and Entities\\n-Feat: Programmatic alerting rollup of underlying Entities\\n-Feat: Custom KPI measurement per location\\n-Feat: Empty-state edit workflow\\n-Feat: JSON file upload format\\n-Feat: Published (in open source docs) guide to automating configuration using the newrelic-cli\" } Copy Step 3 of 3 Save the metadata and screenshots to the catalog. This validates the information you added to the catalog directory against the criteria described in the previous step, and saves it to the catalog. nr1 catalog:submit Copy Publish your app Publishing places your Nerdpack in New Relic One. To publish or deploy, you must be a Nerdpack manager. Step 1 of 1 To publish your Nerdpack, run nr1 nerdpack:publish. Deploy your app Deploying is applying a Nerdpack version to a specific channel (for example, BETA, or STABLE). A channel can only have one Nerdpack version deployed to it at one time. If a channel has an existing Nerdpack associated with it, deploying a new Nerdpack version to that channel will undeploy the previous one. Channels are meant to be an easier way to control application version access than having to be concerned with specific version numbers. Step 1 of 1 To deploy an application, run nr1 nerdpack:deploy. Subscribe or unsubsribe apps Whether you want to subscribe accounts to an app you've created or to apps already available in the catalog, the process is the same. Note that if you subscribe to an app in the catalog, you'll automatically get any updates that are added to the app. To learn about the appropriate permissions for subscribing, see Permissions for managing applications. Step 1 of 2 Subscribe accounts to an application. Select an application you want to add to your New Relic account. Click Add this app. Note that this button says Manage access if the app has already been subscribed to an account you manage. On the Account access page listing the accounts you can subscribe to an application: Select the accounts you want to subscribe the app to. Choose the channel you want to subscribe the app to, Stable or Dev. This can only be Stable for the public apps created by New Relic. Click the update button. Now you and members of the accounts you have subscribed to the app can launch it from New Relic One. Step 2 of 2 Unsubsribe from an application. On the Apps page, open the app you want to unsubscribe. Click Manage access. Clear the check box for any accounts you want to unsubscribe, and then click the update button. The application is no longer listed in the Other apps section of the Apps page, and you have unsubscribed. Handle duplicate applications You might end up with duplicate applications on your New Relic One Apps page. This can happen when you subscribe to the same app using both the CLI and the catalog. Or if you clone an app, modify, and deploy it, but keep the original name. You can manage duplicates with the catalog. Good to know before you start: You need a user role with the ability to manage Nerdpacks for accounts that you want to unsubscribe and undeploy from applications. You can't remove the public apps. When a duplicate application has no accounts subscribed to it, you undeploy it. For applications that have accounts subscribed to them, you unscubscribe and undeploy. The unsubscribe and undeploy process happens in a batch. To remove an account from an application, but ensure that other accounts continue to be subscribed, select the checkbox, Resubscribe these accounts to the new application. Step 1 of 1 Remove duplicates. In the New Relic One catalog, click a public application that has one or more duplicates. (You can only manage duplicates from the public version of the application.) On the application information page, select Clean up applications. Review the information about the application that's open, as well as any duplicates. Click Manage app for duplicates you want to remove. If needed, select Resubscribe these accounts to the new application. Click Unsubscribe and undeploy, and agree to the terms and conditions.",
"_index": "520d1d5d14cc8a32e600034b",
"_type": "520d1d5d14cc8a32e600034c",
- "_score": 257.7234,
+ "_score": 137.07071,
"_version": null,
"_explanation": null,
"sort": null,
"highlight": {
- "title": "Serve, publish, and deploy your NewRelicOne app",
- "sections": "Serve, publish, and deploy your NewRelicOne app",
- "info": "Start sharing and using the custom NewRelicOne apps you build",
- "body": " a matter of kicking off a catalogcommand that validates the information and saves it to the catalog. Step 1 of 3 Update the NewRelicOneCLI to ensure you're working with the latest version. nr1 update Copy Step 2 of 3 Add catalog metadata and screenshots. Run nr1 create and then select catalog"
+ "title": "Serve, publish, and deploy your New Relic One app",
+ "sections": "Add images and metadata to your apps",
+ "info": "Start sharing and using the custom New Relic One apps you build",
+ "tags": "publish apps",
+ "body": " to the app Handle duplicate applications Before you begin This guide requires the following: A New Relic One app or Nerdpack New Relic One CLI A Nerdpackmanager role for publishing, deploying, and subscribing apps. Serve your app locally You can locally serve the app you create to New Relic One to test"
},
"id": "5efa999de7b9d283e67bab8f"
},
{
- "image": "",
- "url": "https://developer.newrelic.com/explore-docs/nr1-common/",
+ "category_2": "Original users and roles",
+ "nodeid": 1101,
"sections": [
- "New Relic One CLI common commands",
- "Command details",
- "nr1 help",
- "See commands and get details",
- "Usage",
- "Arguments",
- "Examples",
- "nr1 update",
- "Update your CLI",
- "nr1 create",
- "Create a new component",
- "Options",
- "nr1 profiles",
- "Manage your profiles keychain",
- "Commands",
- "nr1 autocomplete",
- "See autocomplete installation instructions",
- "nr1 nrql",
- "Query using NRQL"
+ "Original accounts and billing",
+ "Original product-based pricing",
+ "Original users and roles",
+ "Original data retention",
+ "Original pricing plan usage",
+ "Users and roles (original user model)",
+ "View and manage users",
+ "User types: basic user and full user",
+ "Account roles",
+ "Add-on roles",
+ "Account permissions",
+ "Alert permissions",
+ "APM permissions",
+ "Browser permissions",
+ "Infrastructure permissions",
+ "Insights permissions",
+ "Mobile permissions",
+ "Synthetics permissions",
+ "Workloads",
+ "For more help"
],
- "published_at": "2020-08-28T01:50:39Z",
- "title": "New Relic One CLI common commands",
- "updated_at": "2020-08-14T01:48:10Z",
- "type": "developer",
- "external_id": "503e515e1095418f8d19329517344ab209d143a4",
+ "title": "Users and roles (original user model)",
+ "category_0": "New Relic accounts",
+ "type": "docs",
+ "category_1": "Original accounts and billing",
+ "external_id": "39c7440fe944f68b4de943d2c9619cbcc85408d2",
+ "image": "",
+ "url": "https://docs.newrelic.com/docs/accounts/original-accounts-billing/original-users-roles/users-roles-original-user-model",
+ "published_at": "2020-08-25T20:12:09Z",
+ "updated_at": "2020-08-21T07:22:46Z",
+ "breadcrumb": "Contents / New Relic accounts / Original accounts and billing / Original users and roles",
"document_type": "page",
"popularity": 1,
- "info": "An overview of common commands you can use with the New Relic One CLI.",
- "body": "New Relic One CLI common commands Here's a list of common commands to get you started with the New Relic One CLI. You can click any command to see its usage options and additional details about the command. Command Description nr1 help Shows all nr1 commands or details about each command. nr1 update Updates to the latest version of the CLI. nr1 create Creates a new component from a template (Nerdpack, Nerdlet, launcher, or catalog). nr1 profiles Manages the profiles you use to run CLI commands. nr1 autocomplete Displays autocomplete installation instructions. nr1 nrql Fetches data using NRQL (New Relic query language). See our other New Relic One CLI docs for commands specific to Nerdpack set-up, Nerdpack subscriptions, CLI configuration, plugins, or catalogs. Command details nr1 help See commands and get details Shows all nr1 commands by default. To get details about a specific command, run nr1 help COMMAND_NAME. Usage $ nr1 help Arguments COMMAND_NAME The name of a particular command. Examples $ nr1 help $ nr1 help nerdpack $ nr1 help nerdpack:deploy nr1 update Update your CLI Updates to latest version of the CLI. You can specify which channel to update if you'd like. Usage $ nr1 update Arguments CHANNEL The name of a particular channel. Examples $ nr1 update $ nr1 update somechannel nr1 create Create a new component Creates a new component from our template (either a Nerdpack, Nerdlet, launcher, or catalog). The CLI will walk you through this process. To learn more about Nerdpacks and their file structure, see Nerdpack file structure. For more on how to set up your Nerdpacks, see our Nerdpack CLI commands. Usage $ nr1 create Options -f, --force If present, overrides existing files without asking. -n, --name=NAME Names the component. -t, --type=TYPE Specifies the component type. --path=PATH The route to the component. --profile=PROFILE The authentication profile you want to use. --verbose Adds extra information to the output. nr1 profiles Manage your profiles keychain Displays a list of commands you can use to manage your profiles. Run nr1 help profiles:COMMAND for more on their specific usages. You can have more than one profile, which is helpful for executing commands on multiple New Relic accounts. To learn more about setting up profiles, see our Github workshop. Usage $ nr1 profiles:COMMAND Commands profiles:add Adds a new profile to your profiles keychain. profiles:default Chooses which profile should be default. profiles:list Lists the profiles on your keychain. profiles:remove Removes a profile from your keychain. nr1 autocomplete See autocomplete installation instructions Displays the autocomplete installation instructions. By default, the command displays the autocomplete instructions for zsh. If you want instructions for bash, run nr1 autocomplete bash. Usage $ nr1 autocomplete Arguments SHELL The shell type you want instructions for. Options -r, --refresh-cache Refreshes cache (ignores displaying instructions). Examples $ nr1 autocomplete $ nr1 autocomplete zsh $ nr1 autocomplete bash $ nr1 autocomplete --refresh-cache nr1 nrql Query using NRQL Fetches data from databases using a NRQL query. To learn more about NRQL and how to use it, see our NRQL docs. Usage $ nr1 nrql OPTION ... Options -a, --account=ACCOUNT The user account ID. required -q, --query=QUERY The NRQL query to run. required -u, --ugly Displays the content without tabs or spaces. --profile=PROFILE The authentication profile you want to use. --verbose Adds extra information to the output.",
+ "info": "For New Relic original user model: explanation of how to manage users, and how user roles work. ",
+ "body": "Original user model This doc contains information about how to manage users on our original user model. Not sure which pricing plan or user model you're on? See Overview of pricing plan and user models. View and manage users To see the users on your New Relic account and their current roles: select the account dropdown, select Account settings, and select Users and roles. Some features in the UI are visible only to account Owners and Admins. User types: basic user and full user On the Users and roles UI page, users are categorized as either full users or basic users. This only affects your account if you've switched to the New Relic One pricing plan, released July 2020. Once you've changed your pricing plan, the number of full users is a factor in your billing. To learn more, see Transition to new pricing. Account roles A New Relic account can have only one Owner. To share an account with other users in your organization, create Admins, Users, or Restricted Users. Account role Description Owner The person who initially creates the New Relic account and receives all billing queries. The Owner has complete access to all of the account information. The Owner can also install and configure the New Relic agent, and they can enable or set up features. Admins One or more individuals who can add, edit, and delete account users. Admins can also install and configure the New Relic agent, and they can enable or set up features. Users One or more individuals who use (and optionally set up) the available New Relic features. In general, Admins take responsibility for setting up features, and Users and Restricted Users can use them. Restricted Users One or more individuals who can view (but not set up or change) any New Relic features. The Restricted User role is useful, for example, for demos. You can change your New Relic session settings so that Restricted User logins do not time out, and then set the user interface to Kiosk mode. Add-on roles With add-on roles, you can grant variable levels of access to all users in your account, across the entire platform of New Relic products. This allows you to tailor your account permissions levels to suit the needs of Users and Restricted Users within your account. Giving a User or Restricted User add-on manager access to a product grants them the equivalent of Admin capabilities within the product. They will continue to have User or Restricted User capabilities for all other New Relic products. For example, you could make a software engineer in your company a User in most products, but assign Admin-level access to APM. For another example, you might assign the Nerdpack manager role to a user, and that gives them the ability to subscribe and unsubscribe New Relic One applications to an account. There are two types of add-on roles: Add-on Manager roles are available to grant permissions on a per-product basis. Giving a User or Restricted User managed add-on access to a product grants them the equivalent of Admin capabilities within the product. Custom add-on roles can grant feature-specific permissions across different New Relic products. For example, a group of Users could have the ability to acknowledge incidents and close violations in New Relic Alerts, but not have the ability to modify your existing alert preferences. Individuals on a master account that has sub-accounts automatically have the same level of access for all sub-accounts. Below are options for managing both managed add-on roles and custom add-on roles: View roles To view the list of individuals assigned to your account and their current roles: Go to account dropdown > Account settings > Users and roles. Assign a managed role Owner and Admins Managed add-on roles are available by default for each New Relic product. Adding a managed role for a user grants them Admin-level permissions for the assigned product. They cannot be edited or deleted. To assign a managed add-on role for a User or Restricted User in your account: Go to account dropdown > Account settings > Users and roles. From the list of users associated with your account, select their name. Under Add-on roles, select the type of manager role for the user. To understand which capabilities may be added, use the Capabilities preview chart. Features in the Capabilities preview chart may not exactly match what features are available for your subscription level. You can also add, update, or delete users in bulk by using a CSV file. Create a custom role To create a custom add-on role for your account: Go to account dropdown > Account settings > Users and roles > Roles. Select plus-circle New custom add-on role. Select the capabilities necessary for the new custom role, then Create role. Assign a custom role Owners and Admins You must create a custom role before assigning it to a user. To assign a custom add-on role for a User or Restricted User in your account: Go to account dropdown > Account settings > Users and roles > Users. From the list of users associated with your account, select their name ]. Under Add-on roles, select a custom role for the user. Click Update user. Edit or delete a custom role Owners and Admins You cannot edit or delete New Relic's default roles. However, you can edit or delete custom add-on roles for your account: Go to account dropdown > Account settings > Users and roles > Roles. From the Add-on roles list, select the custom add-on role, then select pencil Edit role or trash-o Delete role as appropriate. Account permissions Here is a summary of basic user rights for your New Relic account. Individuals on a master account with sub-accounts automatically have the same level of access for all sub-accounts. However, they will not receive email notifications for alerts or weekly reports for sub-accounts unless they are explicitly granted permission on these sub-accounts. Function Owner Admin User Restricted Maintain billing information. fa-check Change the account Owner. fa-check Add, update, and delete account Admins, Users, and Restricted Users. When the account Owner and Admins add individuals to the account, New Relic automatically sends them an email message. fa-check fa-check Update users' job titles and roles from Account settings in the New Relic UI. fa-check fa-check Create, modify and delete sub-accounts from Account settings in the New Relic UI. fa-check fa-check Update your own account information (name, password change or password reset request, default account, email preferences, etc.) from User preferences in the New Relic UI. fa-check fa-check fa-check fa-check Change someone else's password. You cannot reset passwords for anyone else on the account, even if you are an Owner or Admin. Instead, follow standard procedures to request a password reset from New Relic. View the list of individuals on the account from (account dropdown) > Account settings > Account > Summary in the New Relic UI. fa-check fa-check fa-check fa-check Manage flexible data retention. fa-check Subscribe and unsubscribe applications to New Relic One fa-check fa-check Alert permissions Here is a summary of Admin and Add-on manager capabilities with New Relic Alerts. To allow a User or Restricted User to execute any of these functions in New Relic Alerts, assign an Alerts add-on manager role. Admin and manager capabilities for Alerts include: Create or name alert policies. Specify incident preferences. Disable or define alert conditions. Provide runbook instructions. Select product targets. Alter alert condition thresholds. Create, modify, or delete notification channels. APM permissions Here is a summary of Admin and Add-on manager capabilities with New Relic APM. To allow a User or Restricted User to execute any of these functions in New Relic APM, assign an APM add-on manager role. Admin and manager capabilities for APM include: Remove applications from the New Relic UI. Delete app traces and error traces. Browser permissions Here is a summary of Admin and Add-on manager capabilities with New Relic Browser. To allow a User or Restricted User to execute any of these functions in New Relic Browser, assign a Browser add-on manager role. Admin and manager capabilities for Browser include: Add, rename, or delete applications. Manage whitelists. Manage domain conditions. Infrastructure permissions Here is a summary of Admin and Add-on manager capabilities with New Relic Infrastructure. To allow a User or Restricted User to execute any of these functions in New Relic Infrastructure, assign an Infrastructure manager role. Admin and manager capabilities for Infrastructure include: Create alert conditions in New Relic Infrastructure, including conditions for host not reporting. Add or modify integrations. Insights permissions Here is a summary of Admin and Add-on manager capabilities with New Relic Insights. To allow a User or Restricted User to execute any of these functions in New Relic Insights, assign an Insights manager role. These functions include: Create, view, modify, or delete Query API keys or Insert API keys. New Relic Insights includes permission levels to share your Insights dashboards with others. Mobile permissions Here is a summary of Admin and Add-on manager capabilities with New Relic Mobile. To allow a User or Restricted User to execute any of these functions in New Relic Mobile, assign a Mobile manager role. Admin and manager capabilities for Mobile include: Delete a mobile application from New Relic. Install New Relic Mobile for Android or iOS. Synthetics permissions Here is a summary of Admin and Add-on manager capabilities with New Relic Synthetics. To allow a User or Restricted User to execute any of these functions in New Relic Synthetics, assign a Synthetics add-on manager role. Admin and manager capabilities for Synthetics include: Create, edit, or delete monitors. Edit monitor scripts. Create, edit, or delete private locations. Create, edit, or delete monitor downtimes. Create, view, edit, or delete secure credentials. For more information, see User roles in Synthetics. Workloads Here's a summary of Admin and Add-on manager capabilities with New Relic One workloads: Create, duplicate, modify, or delete workloads. Link dashboards to workloads and save filters. To allow a User or Restricted User to execute these functions, assign the workloads manager add-on role. For more help If you need more help, check out these support and learning resources: Browse the Explorers Hub to get help from the community and join in discussions. Find answers on our sites and learn how to use our support portal. Run New Relic Diagnostics, our troubleshooting tool for Linux, Windows, and macOS. Review New Relic's data security and licenses documentation.",
"_index": "520d1d5d14cc8a32e600034b",
"_type": "520d1d5d14cc8a32e600034c",
- "_score": 229.90652,
+ "_score": 119.42059,
"_version": null,
"_explanation": null,
"sort": null,
"highlight": {
- "title": "NewRelicOneCLI common commands",
- "sections": "NewRelicOneCLI common commands",
- "info": "An overview of common commands you can use with the NewRelicOneCLI.",
- "body": "NewRelicOneCLI common commands Here's a list of common commands to get you started with the NewRelicOneCLI. You can click any command to see its usage options and additional details about the command. Command Description nr1 help Shows all nr1 commands or details about each command. nr1"
+ "sections": "Account permissions",
+ "info": "For New Relic original user model: explanation of how to manage users, and how user roles work. ",
+ "body": " and manager capabilities for APM include: Remove applications from the New Relic UI. Delete app traces and error traces. Browser permissions Here is a summary of Admin and Add-on manager capabilities with New Relic Browser. To allow a User or Restricted User to execute any of these functions in New Relic"
},
- "id": "5f28bd6ae7b9d267996ade94"
+ "id": "5f3e194028ccbc18c7f56de3"
},
{
+ "image": "https://cc.sj-cdn.net/instructor/1h7ahmdd447dx-new-relic/courses/2g790g7la1iot/promo-image.1573253956.png",
+ "url": "https://learn.newrelic.com/live-learncast-new-relic-one-programmability",
"sections": [
- "Create a \"Hello, World!\" application",
- "Before you begin",
- "Tip",
- "Create a local version of the \"Hello, World!\" application",
- "Publish your application to New Relic",
- "Add details to describe your project",
- "Subscribe accounts to your application",
- "Summary",
- "Related information"
- ],
- "title": "Create a \"Hello, World!\" application",
- "type": "developer",
- "tags": [
- "nr1 cli",
- "Nerdpack file structure",
- "NR One Catalog",
- "Subscribe applications"
+ "Join us for this exclusive 90-minute introduction to the fundamentals of New Relic One Programmability. This training will introduce you to the key concepts and walk you through developing New Relic Applications.",
+ "About this Learncast",
+ "Prerequisites",
+ "Virtual Training Session List"
],
- "external_id": "aa427030169067481fb69a3560798265b6b52b7c",
- "image": "https://developer.newrelic.com/static/cb65a35ad6fa52f5245359ecd24158ff/9466d/hello-world-output-local.png",
- "url": "https://developer.newrelic.com/build-apps/build-hello-world-app/",
- "published_at": "2020-08-28T01:46:14Z",
- "updated_at": "2020-08-21T01:45:19Z",
- "document_type": "page",
+ "published_at": "2020-08-29T01:41:00Z",
+ "title": "Live Learncast: New Relic One Programmability",
+ "updated_at": "2020-07-31T01:40:49Z",
+ "type": "",
+ "external_id": "053510b559767dbde34e3f1ee9a73bbf813a5a83",
"popularity": 1,
- "info": "Build a \"Hello, World!\" app and publish it to New Relic One",
- "body": "Create a \"Hello, World!\" application 15 min Here's how you can quickly build a \"Hello, World!\" application in New Relic One. In these steps, you create a local version of the New Relic One site where you can prototype your application. Then, when you're ready to share the application with others, you can publish it to New Relic One. See the video, which demonstrates the steps in this guide in five minutes. Before you begin To get started, make sure you have accounts in GitHub and New Relic. To develop projects, you need the New Relic One CLI (command line interface). If you haven't already installed it, do the following: Install Node.js. Complete all the steps in the CLI quick start. For additional details about setting up your environment, see Set up your development environment. Tip Use the NR1 VS Code extension to build your apps. Create a local version of the \"Hello, World!\" application The CLI allows you to run a local version of New Relic One. You can develop your application locally before you publish it in New Relic One. If you followed all the steps in the CLI quick start, you now have files under a new directory named after your nerdpack project. Here's how you edit those files to create a \"Hello, World!\" project: Step 1 of 9 Open a code editor and point it to the new directory named after your nerdpack project (for example, my-awesome-nerdpack). Your code editor displays two artifacts: launchers containing the homepage tile nerdlets containing your application code Step 2 of 9 Expand nerdlets in your code editor, and open index.js. Step 3 of 9 Change the default return message to \"Hello, World!\": import React from 'react'; // https://docs.newrelic.com/docs/new-relic-programmable-platform-introduction export default class MyAwesomeNerdpackNerdletNerdlet extends React.Component { render() { return
; Copy with this export code: export default class PageViewApp extends React.Component { render() { return (
); } } Copy Step 7 of 8 Customize the look of your table (optional) You can use standard CSS to customize the look of your components. In the styles.scss file, add this CSS. Feel free to customize this CSS to your taste. .container { width: 100%; height: 99vh; display: flex; flex-direction: column; .row { margin: 10px; display: flex; flex-direction: row; } .chart { height: 250px; } } Copy Step 8 of 8 Get your data into that table Now that you've got a table, you can drop a TableChart populated with data from the NRQL query you wrote at the very beginning of this guide. Put this code into the row div. ; Copy Go to New Relic One and click your app to see your data in the table. (You might need to serve your app to New Relic again.) Congratulations! You made your app! Continue on to make it interactive and show your data on a map. Make your app interactive with a text field Once you confirm that data is getting to New Relic from your app, you can start customizing it and making it interactive. To do this, you add a text field to filter your data. Later, you use a third-party library called Leaflet to show that data on a world map. Step 1 of 3 Import the TextField component Like you did with the TableChart component, you need to import a TextField component from New Relic One. import { TextField } from 'nr1'; Copy Step 2 of 3 Add a row for your text field To add a text field filter above the table, put this code above the TableChart div. The text field will have a default value of \"US\".
; Copy Step 3 of 3 Build the text field object Above the render() function, add a constructor to build the text field object. constructor(props) { super(props); this.state = { countryCode: null } } Copy Then, add a constructor to your render() function. Above return, add: const { countryCode } = this.state; Copy Now add countryCode to your table chart query. ; Copy Reload your app to try out the text field. Get your data on a map To create the map, you use npm to install Leaflet. Step 1 of 9 Install Leaflet In your terminal, type: npm install --save leaflet react-leaflet Copy In your nerdlets styles.scss file, import the Leaflet CSS: @import `~leaflet/dist/leaflet.css`; Copy While you're in styles.scss, fix the width and height of your map: .containerMap { width: 100%; z-index: 0; height: 70vh; } Copy Step 2 of 9 Add a webpack config file for Leaflet Add a webpack configuration file .extended-webpackrc.js to the top-level folder in your nerdpack. This supports your use of map tiling information data from Leaflet. module.exports = { module: { rules: [ { test: /\\.(png|jpe?g|gif)$/, use: [ { loader: 'file-loader', options: {}, }, { loader: 'url-loader', options: { limit: 25000 }, }, ], }, ], }, }; Copy Step 3 of 9 Import modules from Leaflet In index.js, import modules from Leaflet. import { Map, CircleMarker, TileLayer } from 'react-leaflet'; Copy Step 4 of 9 Import additional modules from New Relic One You need several more modules from New Relic One to make the Leaflet map work well. Import them with this code: import { NerdGraphQuery, Spinner, Button, BlockText } from 'nr1'; Copy NerdGraphQuery lets you make multiple NRQL queries at once and is what will populate the map with data. Spinner adds a loading spinner. Button gives you button components. BlockText give you block text components. Step 5 of 9 Get data for the map Using latitude and longitude with country codes, you can put New Relic data on a map. mapData() { const { countryCode } = this.state; const query = `{ actor { account(id: 1606862) { mapData: nrql(query: \"SELECT count(*) as x, average(duration) as y, sum(asnLatitude)/count(*) as lat, sum(asnLongitude)/count(*) as lng FROM PageView FACET regionCode, countryCode WHERE appName = 'WebPortal' ${countryCode ? ` WHERE countryCode like '%${countryCode}%' ` : ''} LIMIT 1000 \") { results nrql } } } }`; return query; }; Copy Step 6 of 9 Customize the map marker colors Above the mapData function, add this code to customize the map marker colors. getMarkerColor(measure, apdexTarget = 1.7) { if (measure <= apdexTarget) { return '#11A600'; } else if (measure >= apdexTarget && measure <= apdexTarget * 4) { return '#FFD966'; } else { return '#BF0016'; } }; Copy Feel free to change the HTML color code values to your taste. In this example, #11A600 is green, #FFD966 is sort of yellow, and #BF0016 is red. Step 7 of 9 Set your map's default center point Set a default center point for your map using latitude and longitude. const defaultMapCenter = [10.5731, -7.5898]; Copy Step 8 of 9 Add a row for your map Between the text field row and the table chart row, insert a new row for the map content using NerdGraphQuery.
{({ loading, error, data }) => { if (loading) { return ; } if (error) { return 'Error'; } const { results } = data.actor.account.mapData; console.debug(results); return 'Hello'; }}
; Copy Reload your application in New Relic One to test that it works. Step 9 of 9 Replace \"Hello\" with the Leaflet code Replace return \"Hello\"; with: return ( ); Copy This code creates a world map centered on the latitude and longitude you chose using OpenStreetMap data and your marker colors. Reload your app to see the pageview data on the map!",
"_index": "520d1d5d14cc8a32e600034b",
"_type": "520d1d5d14cc8a32e600034c",
- "_score": 396.04016,
+ "_score": 384.97217,
"_version": null,
"_explanation": null,
"sort": null,
@@ -6632,7 +6844,7 @@
"external_id": "df1f04edc2336c69769d946edbaf263a5339bc92",
"image": "https://developer.newrelic.com/static/0ce8c387a290d7fbd6be155322be9bce/bc8d6/create-account.png",
"url": "https://developer.newrelic.com/collect-data/get-started-nerdgraph-api-explorer/",
- "published_at": "2020-08-28T01:46:14Z",
+ "published_at": "2020-08-29T01:50:40Z",
"updated_at": "2020-08-21T01:47:54Z",
"document_type": "page",
"popularity": 1,
@@ -6640,7 +6852,7 @@
"body": "Explore NerdGraph using the API Explorer 25 min NerdGraph is New Relic's GraphQL API. It allows you to get all the information you need in a single request. With NerdGraph API Explorer you don't need to know the query format: using the Query Builder you can browse our entire graph and compose queries just by selecting the items you want and filling out their required values. Before you begin Go to api.newrelic.com/graphiql and log in using your New Relic user ID and password: the NerdGraph API Explorer loads up. Make sure you have a valid New Relic API key. You can create one directly from the NerdGraph API Explorer. Step 1 of 5 Build a query to retrieve your name Time for your first NerdGraph query. Search for your name in the New Relic database: Erase everything in the query editor. Select the following fields in the query explorer in this order: actor, user, name. This GraphQL snippet appears in the editor. { actor { user { name } } } Copy Step 2 of 5 Click the play button to see the result With this query, you're telling NerdGraph to retrieve your name. You're asking for the name field, which is nested within the user field. This refers to the user who owns the API key, which in turn is nested within actor. Click the play button to see the result: It has almost the same shape as the request. All the fields in the Query Builder make up what's called the GraphQL schema, which describes all the available data types and their attributes. To learn more about each field, click the Docs button, or hover over a field in the editor. Step 3 of 5 Add more fields to your query Now you can try adding more fields to your query. The simplest way is clicking the fields in the Query Builder: The API Explorer knows where the attributes should go in the query. In the example, you add the account id and email fields. Once again, running the GraphQL query results in just the data you need, without over or under-fetching data. Notice that the id field has an argument: passing arguments is a powerful way of customizing your NerdGraph queries. Every field and object can contain arguments, so instead of running multiple queries, you just compose the one that you need. { actor { user { name email } account(id: 12345678) } } Copy Step 4 of 5 Experiment with mutations In GraphQL, mutations are a way to execute queries with side effects that can alter the data by creating, updating, or deleting objects (Commonly referred to as CRUD operations in REST APIs). Ready for your first mutation? Erase what's in the editor. Scroll down the Query Builder and expand mutation. Select the fields in the following screenshot: In this case, you're trying to add a custom tag to an entity. Notice that the editor complains if you don't select errors: mutations must have a way of telling you how the operation performed in the backend (failed requests result in null responses). Tip Unlike REST, GraphQL APIs like NerdGraph can return partial responses. For example, if you try adding tags to multiple entities, some mutations can fail and others succeed; all is logged in the GraphQL response you get. Step 5 of 5 Try your NerdGraph query in the terminal Let's say that you've built a NerdGraph query you're happy with and you want to test it elsewhere. To capture code-ready queries and mutations: Select the Tools menu. Copy the query as a curl call or as a New Relic CLI command. # curl version curl https://api.newrelic.com/graphql \\ -H 'Content-Type: application/json' \\ -H 'API-Key: API_KEY_REDACTED' \\ --data-binary '{\"query\":\"{\\n actor {\\n user {\\n name\\n email\\n }\\n account(id: 12345678)\\n }\\n}\\n\", \"variables\":\"\"}' # New Relic CLI version newrelic nerdgraph query '{ actor { user { name email } account(id: 12345678) } } ' Copy Next steps Now you know the basics of composing and testing NerdGraph queries, but how do you turn them into client or server code? Solutions such as GraphQL Code Generator can help you turn the NerdGraph queries into code for your implementation. Try creating more complex queries by clicking fields and expanding objects in the Query Builder (be careful with mutations though, since they could write data to your account). For more information on NerdGraph and explore other projects from the developer community, check out the threads on the Explorer’s Hub.",
"_index": "520d1d5d14cc8a32e600034b",
"_type": "520d1d5d14cc8a32e600034c",
- "_score": 387.66843,
+ "_score": 375.41382,
"_version": null,
"_explanation": null,
"sort": null,
@@ -6675,7 +6887,7 @@
"external_id": "3620920c26bcd66c59c810dccb1200931b23b8c2",
"image": "",
"url": "https://developer.newrelic.com/explore-docs/intro-to-sdk/",
- "published_at": "2020-08-28T01:49:25Z",
+ "published_at": "2020-08-29T01:59:19Z",
"updated_at": "2020-08-14T01:47:12Z",
"document_type": "page",
"popularity": 1,
@@ -6683,7 +6895,7 @@
"body": "Intro to New Relic One API components To help you build New Relic One applications, we provide you with the New Relic One SDK. Here we give you an introduction to the types of API calls and components in the SDK. The SDK provides everything you need to build your Nerdlets, create visualizations, and fetch New Relic or third-party data. Components of the SDK SDK components are located in the Node module package named nr1, which you get when you install the NR1 CLI. The nr1 components can be divided into several categories: UI components Chart components Query and storage components Platform APIs UI components The UI components category of the SDK contains React UI components, including: Text components: These components provide basic font and heading elements. These include HeadingText and BlockText. Layout components: These components give you control over the layout, and help you build complex layout designs without having to deal with the CSS. Layout components include: Grid and GridItem: for organizing more complex, larger scale page content in rows and columns Stack and StackItem: for organizing simpler, smaller scale page content (in column or row) Tabs and TabsItem: group various related pieces of content into separate hideable sections List and ListItem: for providing a basic skeleton of virtualized lists Card, CardHeader and CardBody : used to group similar concepts and tasks together Form components: These components provide the basic building blocks to interact with the UI. These include Button, TextField, Dropdown and DropdownItem, Checkbox, RadioGroup, Radio, and Checkbox. Feedback components: These components are used to provide feedback to users about actions they have taken. These include: Spinnerand Toast. Overlaid components: These components are used to display contextual information and options in the form of an additional child view that appears above other content on screen when an action or event is triggered. They can either require user interaction (like modals), or be augmenting (like a tooltip). These include: Modal and Tooltip. Components suffixed with Item can only operate as direct children of that name without the suffix. For example: GridItem should only be found as a child of Grid. Chart components The Charts category of the SDK contains components representing different types of charts. The ChartGroup component helps a group of related charts share data and be aligned. Some chart components can perform NRQL queries on their own; some accept a customized set of data. Query and storage components The Query components category contains components for fetching and storing New Relic data. The main way to fetch data is with NerdGraph, our GraphQL endpoint. This can be queried using NerdGraphQuery. To simplify use of NerdGraph queries, we provide some components with pre-defined queries. For more on using NerdGraph, see Queries and mutations. We also provide storage for storing small data sets, such as configuration settings data, or user-specific data. For more on this, see NerdStorage. Platform APIs The Platform API components of the SDK enable your application to interact with different parts of the New Relic One platform, by reading and writing state from and to the URL, setting the configuration, etc. They can be divided into these categories: PlatformStateContext: provides read access to the platform URL state variables. Example: timeRange in the time picker. navigation: an object that allows programmatic manipulation of the navigation in New Relic One. Example: opening a new Nerdlet. NerdletStateContext: provides read access to the Nerdlet URL state variables. Example: an entityGuid in the entity explorer. nerdlet: an object that provides write access to the Nerdlet URL state.",
"_index": "520d1d5d14cc8a32e600034b",
"_type": "520d1d5d14cc8a32e600034c",
- "_score": 330.85156,
+ "_score": 321.44214,
"_version": null,
"_explanation": null,
"sort": null,
@@ -6715,7 +6927,7 @@
"external_id": "cbbf363393edeefbc4c08f9754b43d38fd911026",
"image": "",
"url": "https://developer.newrelic.com/explore-docs/query-and-store-data/",
- "published_at": "2020-08-28T01:50:39Z",
+ "published_at": "2020-08-29T01:58:45Z",
"updated_at": "2020-08-01T01:42:02Z",
"document_type": "page",
"popularity": 1,
@@ -6723,7 +6935,7 @@
"body": "Query and store data 10 min To help you build a New Relic One application, we provide you with the New Relic One SDK. Here you can learn how to use the SDK query components, which allow you to make queries and mutations via NerdGraph, our GraphQL endpoint. Query-related React components can be identified by the Query suffix. Mutation-related components can be identified by the Mutation prefix. Components overview Our data components are based on React Apollo. The most basic component is NerdGraphQuery, which accepts any GraphQL (or GraphQL AST generated by the graphql-tag library as the query parameter, and a set of query variables passed as variables. Over this query, we have created an additional set of queries, which can be divided into four groups: User queries: These allow you to query the current user and its associated accounts. Components in this category: UserStorageQuery and AccountsQuery. Entities queries: Because New Relic One is entity-centric, we use queries to make access to your entities easier. You can count, search, list, query, and favorite them. Components in this category: EntityCountQuery, EntitySearchQuery, EntitiesByDomainTypeQuery, EntitiesByGuidsQuery, EntityByGuidQuery, EntityByNameQuery. Storage queries: New Relic One provides a simple storage mechanism that we call NerdStorage. This can be used by Nerdpack creators to store application configuration setting data, user-specific data, and other small pieces of data. Components in this category: UserStorageQuery, AccountStorageQuery, EntityStorageQuery, UserStorageMutation, AccountStorageMutation, and EntityStorageMutation. For details, see NerdStorage. NRQL queries: To be able to query your New Relic data via NRQL (New Relic Query Language), we provide a NrqlQuery component. This component can return data in different formats, so that you can use it for charting and not only for querying. Query components All query components accept a function as a children prop where the different statuses can be passed. This callback receives an object with the following properties: loading: Boolean that is set to true when data fetching is happening. Our components use the cache-and-network strategy, meaning that after the data has loaded, subsequent data reloads might be triggered first with stale data, then refreshed when the most recent data has arrived. data: Root property where the data requested is retrieved. The structure matches a root structure based on the NerdGraph schema. This is true even for highly nested data structures, which means you’ll have to traverse down to find the desired data. error: Contains an Error instance when the query fails. Set to undefined when data is loading or the fetch was successful. fetchMore: Callback function that can be called when the query is being loaded in chunks. The function will only be present when it’s feasible to do so, more data is available, and no fetchMore has already been triggered. Data is loaded in batches of 200 by default. Other components provided by the platform (like the Dropdown or the List) are capable of accepting fetchMore, meaning you can combine them easily. Mutation components Mutation components also accept a children as a function, like the query ones. The mutation can be preconfigured at the component level, and a function is passed back that you can use in your component. This is the standard React Apollo approach for performing mutations, but you might find it easier to use our static mutation method added to the component. More on this topic below. Static methods All of the described components also expose a static method so that they can be used imperatively rather than declaratively. All Query components have a static Query method, and all Mutation components have a mutation method. These static methods accept the same props as their query component, but passed as an object. For example: // Declarative way (using components). function renderAccountList() { return (