New Relic

Last Updated October 2014

Select Language

Pagoda Box provides detailed analytics related to your app's infrastructure. New Relic provides information about your application performance. Together, they're a treasure trove of valuable data that can be used to troubleshoot and optimize your app. This doc walks through how to use New Relic with Pagoda Box. After reading it, you should be familiar with:

  • Integrating New Relic with your app
  • Configuring New Relic for your app
  • Swimming in a pool of awesome analytic data

Using New Relic with PHP

To use New Relic with PHP on Pagoda Box, you only need two things:

  1. A New Relic Account

  2. Your New Relic License Key

Add Your New Relic License Key to Your App

Every New Relic account gets a unique License Key. The New Relic License Key documentation explains where to find it. Once you have your key, go to Dev Config > New Relic in your app dashboard. Enter your license key and save.

Configuring New Relic for PHP on Pagoda Box

New Relic has custom PHP settings that are typically handled in the php.ini. On Pagoda Box, these settings are handled in the Boxfile. Each is covered in detail below.

Overview of New Relic PHP Settings in the Boxfile YAML

  web1:
    php_newrelic_capture_params: false
    php_newrelic_ignored_params: ""
    php_newrelic_loglevel: "info"
    php_newrelic_framework: wordpress
    php_newrelic_framework_drupal_modules: true
    php_newrelic_browser_monitoring_auto_instrument: true
    php_newrelic_transaction_tracer_enabled: true
    php_newrelic_transaction_tracer_detail: 1
    php_newrelic_transaction_tracer_record_sql: "obfuscated"
    php_newrelic_transaction_tracer_threshold: "apdex_f"
    php_newrelic_transaction_tracer_stack_trace_threshold: 500
    php_newrelic_transaction_tracer_explain_threshold: 500
    php_newrelic_transaction_tracer_slow_sql: true
    php_newrelic_transaction_tracer_custom: ""
    php_newrelic_error_collector_enabled: true
    php_newrelic_error_collector_record_database_errors: true
    php_newrelic_webtransaction_name_functions: ""
    php_newrelic_webtransaction_name_files: ""
    php_newrelic_webtransaction_name_remove_trailing_path: false
    php_newrelic_synchronous_startup: false
/Boxfile

App Name and License Key

The New Relic app name and license key are not configurable in the Boxfile. The license key is configured in your dashboard and the app name is set automatically by Pagoda Box.

New Relic Capture Params

This sets the value of newrelic.capture_params. View the New Relic documentation for more details.

php_newrelic_capture_params YAML

  #default setting
  web1:
    php_newrelic_capture_params: false
/Boxfile
New Relic Ignored Params

This sets the value of newrelic.ignored_params. View the New Relic documentation for more details.

php_newrelic_ignored_params YAML

  #default setting
  web1:
    php_newrelic_ignored_params: ""
/Boxfile
New Relic LogLevel

This sets the value of newrelic.loglevel. View the New Relic documentation for more details.

php_newrelic_logleve YAML

  #default setting
  web1:
    php_newrelic_loglevel: "info"
/Boxfile
New Relic Framework

This sets the value of newrelic.framework. View the New Relic documentation for more details.

php_newrelic_framework YAML

  web1:
    php_newrelic_framework: wordpress
/Boxfile
New Relic Framework Drupal Modules

This sets the value of newrelic.framework.drupal.modules. View the New Relic documentation for more details.

php_newrelic_framework_drupal_modules YAML

  web1:
    php_newrelic_framework_drupal_modules: true
/Boxfile
New Relic Browser Monitoring Auto Instrument

This sets the value of newrelic.browser_monitoring.auto_instrument. View the New Relic documentation for more details.

php_newrelic_browser_monitoring_auto_instrument YAML

  #default setting
  web1:
    php_newrelic_browser_monitoring_auto_instrument: true
/Boxfile
New Relic Transaction Tracer Enabled

This sets the value of newrelic.transaction_tracer.enabled. View the New Relic documentation for more details.

php_newrelic_transaction_tracer_enabled YAML

  #default setting
  web1:
    php_newrelic_transaction_tracer_enabled: true
/Boxfile
New Relic Transaction Tracer Detail

This sets the value of newrelic.transaction_tracer.detail. View the New Relic documentation for more details.

php_newrelic_transaction_tracer_detail YAML

  #default setting
  web1:
    php_newrelic_transaction_tracer_detail: 1
/Boxfile
New Relic Transaction Tracer Record SQL

This sets the value of newrelic.transaction_tracer.record_sql. View the New Relic documentation for more details.

php_newrelic_transaction_tracer_record_sql YAML

  #default setting
  web1:
    php_newrelic_transaction_tracer_record_sql: "obfuscated"
/Boxfile
New Relic Transaction Tracer Threshold

This sets the value of newrelic.transaction_tracer.threshold. View the New Relic documentation for more details.

php_newrelic_transaction_tracer_threshold YAML

  #default setting
  web1:
    php_newrelic_transaction_tracer_threshold: "apdex_f"
/Boxfile
New Relic Transaction Tracer Stack Trace Threshold

This sets the value of newrelic.transaction_tracer.stack_trace_threshold. View the New Relic documentation for more details.

php_newrelic_transaction_tracer_stack_trace_threshold YAML

  #default setting
  web1:
    php_newrelic_transaction_tracer_stack_trace_threshold: 500
/Boxfile
New Relic Transaction Tracer Explain Threshold

This sets the value of newrelic.transaction_tracer.explain_threshold. View the New Relic documentation for more details.

php_newrelic_transaction_tracer_explain_threshold YAML

  #default setting
  web1:
    php_newrelic_transaction_tracer_explain_threshold: 500
/Boxfile
New Relic Transaction Tracer Slow SQL

This sets the value of newrelic.transaction_tracer.slow_sql. View the New Relic documentation for more details.

php_newrelic_transaction_tracer_slow_sql YAML

  #default setting
  web1:
    php_newrelic_transaction_tracer_slow_sql: true
/Boxfile
New Relic Transaction Tracer Custom

This sets the value of inivar-tt-slowsqlnewrelic.transaction_tracer.custom. View the New Relic documentation for more details.

php_newrelic_transaction_tracer_custom YAML

  #default setting
  web1:
    php_newrelic_transaction_tracer_custom: ""
/Boxfile
New Relic Error Collector Enabled

This sets the value of newrelic.error_collector.enabled. View the New Relic documentation for more details.

php_newrelic_error_collector_enabled YAML

  #default setting
  web1:
    php_newrelic_error_collector_enabled: true
/Boxfile
New Relic Error Collector Record Database Errors

This sets the value of newrelic.error_collector.record_database_errors. View the New Relic documentation for more details.

php_newrelic_error_collector_record_database_errors YAML

  #default setting
  web1:
    php_newrelic_error_collector_record_database_errors: true
/Boxfile
New Relic WebTransaction Name Functions

This sets the value of newrelic.webtransaction.name.functions. View the New Relic documentation for more details.

php_newrelic_webtransaction_name_functions YAML

  #default setting
  web1:
    php_newrelic_webtransaction_name_functions: ""
/Boxfile
New Relic WebTransaction Name Files

This sets the value of newrelic.webtransaction.name.files. View the New Relic documentation for more details.

php_newrelic_webtransaction_name_files YAML

  #default setting
  web1:
    php_newrelic_webtransaction_name_files: ""
/Boxfile
New Relic WebTransaction Name Remove Trailing Path

This sets the value of newrelic.webtransaction.name.remove_trailing_path. View the New Relic documentation for more details.

php_newrelic_webtransaction_name_remove_trailing_path YAML

  #default setting
  web1:
    php_newrelic_webtransaction_name_remove_trailing_path: false
/Boxfile
New Relic Synchronous Startup

This sets the value of newrelic.synchronous_startup. View the New Relic documentation for more details.

php_newrelic_synchronous_startup YAML

  #default setting
  web1:
    php_newrelic_synchronous_startup: false
/Boxfile

New Relic Only Available for Webs and Workers

Currently New Relic will only collect data from web and worker services.

If you have any questions, suggestions, or corrections, let us know.