Get the Advanced Web App Monitoring with New Relic Add-on in One Click

| January 28, 2016

New Relic is an application performance monitoring tool for Developers and Ops, focused on providing the deep insight into the project’s performance and reliability in real-time. Designed to pinpoint and diagnose the occurred issues, it can track throughput of your web transactions, analyze application exceptions, find slowness in queries or web requests and, generally, gives the great amount of useful data for the fast and comfortable troubleshooting.New-Relic-Add-on

Since New Relic is one of the most frequently used and extremely popular solutions for supervising application metrics, we have prepared a special add-on to simplify its delivery. Implemented on the base of JPS (Jelastic Packaging Standard), it gives the opportunity to install this software in a single mouse click and start tracking the most crucial application server information in a matter of minutes. 

As an addition, the provided package includes the embedded option for automatic checking of available updates - in such a way, you can be always up-to-date on the most recent cool features and possibilities the New Relic team provides.

So, to explore how to unveil the latent performance capacities of your application, you’ll need to have:

  • the already registered New Relic account, with your unique user identifier (i.e. license key)
  • at least a single environment created at any of our partners’ Platforms, with the deployed app you’d like to track

Once these conditions are fulfilled, you can go ahead to the instruction below and learn how to perform the seamless integration of New Relic APM agent to your projects, hosted at Jelastic Cloud.

Add-On Installation

With Jelastic, the New Relic add-on can be installed on the top of either Java- (handled as a Java agent) or PHP-based environment (being implemented in a view of extension). Anyway, the installation flow remains similar - we’ll use a Java environment with the Tomcat application server as an example.

Note: The currently supported Java application servers are Tomcat, TomEE, and Jetty of all versions. The ability to apply New Relic monitoring to other servers will be added in the upcoming releases.

1. To start with, click the Marketplace button at the top dashboard pane.image10
2. Switch to the Add-ons section in the opened tab, find the New Relic APM solution within the appeared list (you can use the search input above) and click on Install for it.image02
3. You’ll see the installation frame appeared:image05

Here, the following data should be specified within the appropriate fields:

  • Environment name - select the name of environment the New Relic agent should be installed to (the suitable ones are highlighted within the drop-down list)
  • Nodes - pick the instance for being monitored (i.e. an application server the chosen environment contains)
  • Application name - enter the label for this app to be shown at your New Relic dashboard, e.g. my_java_project (an environment domain is substituted by default here if switching among several ones)
  • License key - a unique identifier, that is bound to each New Relic user and can be viewed at the Account settings section of its admin panel (in such a way, you ensure that the collected data will be reported at your account so you can easily analyze it)
Note: The License key field contains the key mask by default. You can complete the installation leaving it unchanged, but, obviously, you won’t be able to explore the gathered statistics (because of the absence of the bound New Relic account).
Nevertheless, you can specify this parameter later within the New Relic add-on settings by means of the Jelastic Configuration Manager. The paths for the required file are:

  • for Java app servers:
    • TomEE, Tomcat 6, 7 - /opt/tomcat/lib/newrelic/newrelic.yml
    • Tomcat 8 - /opt/shared/lib/newrelic/newrelic.yml
    • Jetty 6 - /opt/jetty/lib/newrelic/newrelic.yml
    • Jetty 8, 9 - /opt/shared/libraries/lib/newrelic/newrelic.yml
  • for PHP app servers: the appropriate parameter can be found at the very end of the etc/php.ini file (within the [newrelic] section)

Besides, the rest of add-on parameters can be modified within these files too.

Click the Install button to confirm your entries and initiate the deployment process.

4. In several minutes, the add-on will be added to your application:image01
5. As you can observe within the above-shown pop-up, you need to obligatory Restart node(s) with the appropriate button next  to your application server for the add-on to start gathering your app’s efficiency trends.image11

Please pay attention, that restart will cause a temporary downtime of your application, thus we leave for you to decide when to perform this operation.

6. Now, you can log in to your New Relic account and look inside the collected data on your application performance metrics, keep an eye on the most crucial parameters in real time through your custom report dashboards, get the automatic notifications on the critical issues occurred and much more - see the full list of the provided features here.

As you can see, the New Relic add-on installation is really simple and will not take much time. At the same time, it’s powerful enough to help you in dealing with the arisen problems and doing away with lack of performance.

Updating New Relic Agent

In order to keep in pace with the most recently provided New Relic features, we’ve also added the inbuilt option, that checks the presence of the newly released agent versions directly at the corresponding repositories and allows to update the installed add-on in just a few clicks, without the necessity to handle this manually.

For that, simply open the Add-ons section for the required node (with the same-named button next to it) and find the ticked New Relic plank. Click on the gear icon in its top corner and select the Update Agent option at the expanded list:image04

Confirm the initiation of the available updates’ checking within the appeared dialog frame by clicking Yes and wait till Jelastic completes this.image07

As a result, the necessary files (if there are any) will be downloaded and installed.image09

After the add-on is successfully updated, you’ll see the corresponding pop-up in the top right corner of the dashboard, which recommends you to restart the instance for the changes to be applied. So, follow this tip by clicking the appropriate button next to your application server.image03

Note: The restart will cause a temporary downtime of your application.

For now, your New Relic add-on is up-to-date and ready to work. Enjoy it!

Subsequently, the current version of your agent could be checked as follows:

  • for Java servers - within the logs/newrelic_agent.log file, located in the dedicated directory with add-on files (you can see the list of paths to it depending on a server in the note above)
  • for PHP servers - via the phpinfo() output

In such a way, Jelastic provides you with a simple for integration, but rather useful and powerful monitoring solution - try it on your own and ensure that everything is just as easy as described above. And in case you still don’t have a Jelastic account for that, consider creating it at one of our hosting partners.

We hope you’ve liked this guide, so we encourage you to get to know more and evaluate other instructions from the “Jelastic how-to” series, that are available at our blog, as well as subscribe to it in order to follow the new ones.