Add API method to send custom crash

Hi everyone,
We use NewRelic Unity Plugin in our Unity3D game. When the game crashes, we see ‘unreadable’ stack trace in Mobile APM. To see correct stack trace we use demo crash with message, which contains stack trace.
It will be great, if NewRelic Unity Plugin will have method, for example NewRelicAgent.RegisterCrash(Exception e), to send custom crashes.

Thanks.

Hello @andrey.rylach,

The Unity SDK API provides a method to execute a crash:

NewRelicAgent.CrashNow("message here")

This method is intended to demo crashes, but I think it would work well for this use too.

Please let me know how it goes!

Hello @nromike,

Thank you for your reply.
I use this method in my application. However, in Mobile APM, I see only one type of error - NewRelicDemoException. If the application has a lot of crashes, I cannot see all of them, because Mobile APM provides only 25 samples. I use your service - Insights to see details of all crashes.

If Unity SDK API sent not only NewRelicDemoException, it would be more convenient.

Thank you.

Ah I see, sorry for my confusion. The CrashNow() method is really only intended to be used in testing to ensure crashes are being properly reported to New Relic.

I’d love to work on fixing the crashes giving unreadable stack traces. I believe this is because - in iOS apps - method and class names are stripped away, and replaced with machine readable memory addresses. This saves space, but makes it impossible to read, so Xcode also creates a file with debugging symbols. This debugging symbol file - called a dSYM - can be used to translate memory address back into their human readable original names. The New Relic Unity plugin cannot automatically upload dSYMs, and you’ll need to manually upload dSYMs once your iOS unity app is built for release.

We have an awesome deep dive into uploading dSYMs with more detailed steps on the process and a lot of useful information.