A simple agent that polls health information from Oracle Commerce servers and submits to NewRelic platform.
This plugin has been tested to work with the following application stack:
- Oracle Commerce 10.x, 11.x
- Java Runtime (JRE) environment Version 1.6 or later.
- Oracle Commerce NewRelic Plugin Module
- A New Relic account. Sign up for a free account here.
The configuration file uses YAML as its format. Please make sure you are properly formatting your configuration file prior to submitting a ticket. YAML is a whitespace dependent markup format. More information on writing proper YAML can be found at http://yaml.org.
This plugin collects metrics from the configured server instances in the form of JSON. This JSON format looks as follows:
{
"success": "true|false",
"status": "status code"
"message": "error|success message",
"components": [
{ "name": "component-name",
"description": "component-description",
"metrics": [{"name": "metric-name", "unit": "metric-unit", "value": "value"}]
}
]
}
{
"success": "true",
"status": 200
"message": "OK",
"components": [
{ "name": "/atg/commerce/catalog/Test",
"description": "Test component",
"metrics": [{"name": "testCount", "unit": "count", "value": 300}]
}
]
}
The latest version of the plugin can be downloaded here. Once the plugin is on your box, extract it to a location.
Note - This plugin is distributed in tar.gz format and can be extracted with the following command on Unix-based systems.
tar -xvzf newrelic_oracle_atg_plugin-1.0.0.tar.gz
Check out the configuration information section for details on configuring your plugin.
To start the agent, execute the startPlugin.sh shell script in terminal:
$ ./startPlugin.sh
To terminate the plugin, execute the stopPlugin.sh shell script in terminal:
$ ./stopPlugin.sh
The plugin requries two files to be present during startup:
- The first (
newrelic.json
) contains configurations used by all Platform plugins (e.g. license key, logging information, proxy settings) and can be shared across your plugins. - The second (
plugin.json
) contains data specific to each plugin such as a list of hosts and port combination for what you are monitoring.
The newrelic.json
file also has a provided template in the config
directory named newrelic.template.json
. If you are installing manually, make a copy of this template file and rename it to newrelic.json
.
The newrelic.json
is a standardized file containing configuration information that applies to any plugin (e.g. license key, logging, etc.), so going forward you will be able to copy a single newrelic.json
file from one plugin to another. Below is a list of the configuration fields that can be managed through this file:
Your New Relic license key is the only required field in the newrelic.json
file as it is used to determine what account you are reporting to. If you do not know what your license key is, you can learn about it here.
Example:
{
"license_key": "YOUR_LICENSE_KEY_HERE"
}
The plugin.json
file has a provided template in the config
directory named plugin.template.json
. If you are installing manually, make a copy of this template file and rename it to plugin.json
(the New Relic Platform Installer will automatically handle creation of configuration files for you).
Below is an example of the plugin.json
file's contents, you can add multiple objects to the "agents" array to monitor different instances:
{
"agents": [
{
"name" : "Estore-PRD-1",
"host" : "estore-host-name-1"
"port" : estore-port-1
},
{
"name" : "Estore-PRD-2",
"host" : "estore-prd-url"
},
{
"name" : "BCC-PRD",
"host" : "bcc-prd-host-name"
"port" : bcc-prd-port
},
.........
.........
.........
]
}
note - The "name" attribute is used to identify specific instances in the New Relic UI.
By default Platform plugins will have their logging turned on; however, you can manage these settings with the following configurations:
log_level
- The log level. Valid values: [debug
, info
, warn
, error
, fatal
]. Defaults to info
.
log_file_name
- The log file name. Defaults to newrelic_plugin.log
.
log_file_path
- The log file path. Defaults to logs
.
log_limit_in_kbytes
- The log file limit in kilobytes. Defaults to 25600
(25 MB). If limit is set to 0
, the log file size would not be limited.
Example:
{
"license_key": "YOUR_LICENSE_KEY_HERE"
"log_level": "debug",
"log_file_path": "/var/logs/newrelic"
}