1

A Logging library to capture logs from the app and push them to a service hosted with in Some Network. This code could either be used as a library or it could be merged in to the app as just another class. At any point only one instance of this logger should be available across the entire app. This api should let user specify logging level. There are multiple logging levels – “PROD”, “DEBUG” and “INFO”. If there is no logging level specified, “INFO” level should be assumed. Each log string should have this format:

[Logging Level][space][Timestamp][space][Name of the class sending the log][space][line number of the log statement][space][any message][space][space delimited argument list]

Ben10
  • 3,221
  • 2
  • 34
  • 61

1 Answers1

0

If it is only for development I wonder why you want to send it to some server? You can just log and look at the console (XCode Organzier, Device, Device Logs). Even if you do not connect you iPhone/iPad to the a Mac a bit later the logs you write with NSLog are still available.

There are logging libraries around for objective-c. You can google them. But I doubt there is one that sends the log to a server. You have to do that yourself. Though this is not very difficult. NSURLConnections can do it. But if this is an app that is marketed through the appstore I guess you have to switch off all logging and only use it during development, because I wouldn't want my app to send all sort of data over the air and internet to some server.

hol
  • 8,255
  • 5
  • 33
  • 59