This is a guest post from our partner StackMob who provides an end-to-end development platform for mobile application developers. The post originally appeared on their blog as part of the SnapStack App Bootcamp series. To view the earlier posts, visit the StackMob blog.
The Case for New Relic
So you completed our SnapStack tutorial series, and released your app into the App Store. The work is over, right? Contrary to belief, the work has just begun. Even after your app has shipped out, the development process continues. No amount of testing will substitute for the experience of putting your app into the wild. Developers are constantly responding to users interacting with their app, sometimes in ways they might not have imagined.
Unfortunately, this makes the debugging process exponentially more difficult. Many developers spend large amounts of time scouring the reviews of their app, looking for reappearing bugs or issues. This leaves them firefighting issues blindly; relying on differing, incomplete accounts from user reviews. In addition to handling issues in a reactive manner, the practice comes at a price: developers often have to wait for a batch of poor reviews before they’re alerted to an issue.
New Relic solves the problem with its mobile SDK, which provides real time HTTP request and error monitoring. The mobile monitoring SDK enables developers to be proactive about identifying and fixing bugs. New Relic doesn’t stop at error logs; their dashboard presents plenty of useful and informative data about a live app, all in an easily accessible manner. The more context the better — with New Relic, app developers can make informed decisions at every turn.
Adding the New Relic SDK
1. If you don’t have one yet, sign up for a New Relic account.
2. Log in and click the Mobile tab on the left.
3. From the Mobile Dashboard, select your app (create one if you haven’t done so) and click the Settings tab.
4. From the Settings tab, click Installation.
5. Select the iOS SDK and download it. Unzip it and drag NewRelicAgent.framework into the frameworks folder of the project.
SystemConfiguration.framework to the project.
7. In the MOBAppDelegate.m file add the following import:
8. Add this line of code at the very beginning of the
Replace YOUR_NEW_RELIC_KEY with your New Relic application token:
9. Build your project and run, and you should see activity in your New Relic dashboard immediately.
We’ve reached the end of this tutorial. In it, we discussed the challenges and pitfalls that developers encounter with live app debugging. Next, we presented the solution that New Relic provides, and covered the benefits of the New Relic mobile monitoring SDK. Finally, we leveraged the partnership between StackMob and New Relic, and walked through adding it to our SnapStack project.
Are You a StackMob Customer?
Through our partnership, StackMob customers get New Relic Standard free of charge. You’ll even get a free 14 day trial of New Relic Pro. So, what are you waiting for? Sign up for your free account today!