New Relic for Mobile - iOS Titanium Module

Installing the New Relic for Mobile iOS Titanium Module

Copy and unzip the ti.newrelic-iphone-0.1.zip zipfile into your Titanium SDK directory. Typically this will be ~/Library/Application Support/Titanium or /Library/Application Support/Titanium.

Registering the module in your app

Register the module with your application by editing tiapp.xml and adding the module.

ti.newrelic

Starting New Relic

To start using New Relic, simply require the ti.newrelic module and call start with your app token:

require('ti.newrelic').start("YOUR_APP_TOKEN");

In a Titanium Alloy app, alloy.js is a perfect place to add this line of code.

In a Titanium Classic app, just add it to your app.js or wherever your app initialization happens.

Start monitoring your code!