how can I send log information from my Android app to my server?

rmeador picture rmeador · Aug 7, 2014 · Viewed 13.1k times · Source

I'm developing an Android app that is currently in the Play Store. I've been getting reports of a crash on certain devices that I can't reproduce, and the Play Store's built in crash diagnostics don't contain enough information. What I really need is the Logcat information from these devices, but it seems that Android 4.1 and above don't allow the use of those "Log Collector" apps that used to be so popular for this purpose due to security concerns. Is there a library that I can add to my app that will allow it to log to a remote server on demand? I know enough about this crash that I could put a call to some mythical sendLogcatNow() function in the appropriate spot in the code, if I had such a function. Since the information I seek is not actually part of the crash (the crash occurs later), normal crash reporting tools such as Crashlytics don't seem like they will do what I need, but perhaps they have this feature and it's just not prominent in the documentation. Thanks!

Answer

AnkitSomani picture AnkitSomani · Aug 7, 2014

There are few version for crash reporting..

  1. Hockey App
  2. Acra
  3. BugSense
  4. Android Remote stack trace
  5. Since your app can always read logs for it's own process, you can also implement something of your own.

Out of all these, I personally prefer Acra. as it is most efficient and give many options to app developers.