iOS - Application logging test and production code
- by Peter Warbo
I am doing a bunch of logging when I'm testing my application which is useful for getting information about variable state and such.
However I have read that you should use logging sparsely in production code (because it can potentially slow down your application). But my question is now: if my app is in production and people are using it, whenever a crash (god forbid) occurs, how will I be able to interpret the crash information if I have removed the logging statements? Then I suppose I will only have a stacktrace for me to interpret?
Does this mean I should leave logging in production code only WHERE it's really essential for me to interpret what has happened?
Also how will the logging statements relate to the crash reports? Will they be combined? I'm thinking of using Flurry as analytics and crash reports...