[
https://issues.apache.org/jira/browse/CB-611?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13266121#comment-13266121
]
Chris Brody commented on CB-611:
--------------------------------
> Can you be more precise with "keep the console logging in one place"?
>
> I assume you mean, "keep all the console-related methods in a single object -
> the {{console}} object".
>
> Meaning, bolt on new methods to a pre-existing object that we don't
> necessarily have control over.
The original console logging functionality, as accessed via console.log(),
works pretty well but has proven not to be perfect. I think we all understand
that the idea of logging is to very quickly understand important events that
are going on and also what event may cause or indicate a form of
malfunctioning. I suspect the original authors decided not to spent valuable
development time dealing with multiple logging levels.
It has been proven necessary to have multiple logging levels. Of course this is
not new; log4j has been doing this for years, UNIX and VMS have been doing this
for decades.
So we have a console logging facility that is pretty good but of course not
perfect, and we have clearly identified a need to add multiple logging levels.
IMHO the cleanest way forward is to add the missing functionality to the
existing class and go forward. The default behavior for the old, existing
function should be to continue to act the same, unless changed by configuration.
If we have to add a new class every time something is missing, we will start a
path that has more and more plugins and source files. This is not a good way
forward either, since constantly adding classes will add complexity and more
than one way of doing each thing.
> Logging levels
> --------------
>
> Key: CB-611
> URL: https://issues.apache.org/jira/browse/CB-611
> Project: Apache Callback
> Issue Type: Improvement
> Components: iOS
> Affects Versions: Master
> Environment: Run Cordova/PhoneGap with Cordova-SQLitePlugin and some
> other plugins
> Reporter: Chris Brody
> Assignee: Shazron Abdullah
> Fix For: Master
>
> Original Estimate: 48h
> Remaining Estimate: 48h
>
> I got a pull request on my Cordova-SQLitePlugin with a special logging
> function that is only logging when built as a debug version. I believe this
> issue should be solved in the core with a log function that is only logging
> when built as a debug version. Ideally a logging facility with multiple log
> levels. Please forgive me if this has already been done somewhere.
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators:
https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira