diff options
author | Jason Gerard DeRose <jderose@redhat.com> | 2008-10-28 02:10:56 -0600 |
---|---|---|
committer | Jason Gerard DeRose <jderose@redhat.com> | 2008-10-28 02:10:56 -0600 |
commit | fbcb55bd11d17dbff8ec3c7c99cf7b3bb91d3752 (patch) | |
tree | 80b9e24f758f702d4f5bcf12f649632bf347a5c0 /ipalib | |
parent | a9f1c74a7fb7619cfcdb9f5eaf0f62745b1b551e (diff) | |
download | freeipa-fbcb55bd11d17dbff8ec3c7c99cf7b3bb91d3752.tar.gz freeipa-fbcb55bd11d17dbff8ec3c7c99cf7b3bb91d3752.tar.xz freeipa-fbcb55bd11d17dbff8ec3c7c99cf7b3bb91d3752.zip |
lite-xmlrpc.py now uses api.bootstrap() property, logs to api.logger
Diffstat (limited to 'ipalib')
-rw-r--r-- | ipalib/constants.py | 3 | ||||
-rw-r--r-- | ipalib/plugable.py | 2 | ||||
-rw-r--r-- | ipalib/util.py | 3 |
3 files changed, 4 insertions, 4 deletions
diff --git a/ipalib/constants.py b/ipalib/constants.py index 7220561f7..f4a440c65 100644 --- a/ipalib/constants.py +++ b/ipalib/constants.py @@ -89,7 +89,8 @@ DEFAULT_CONFIG = ( ) -LOGGING_CONSOLE_FORMAT = ' '.join([ +LOGGING_CONSOLE_FORMAT = ': '.join([ + '%(name)s', '%(levelname)s', '%(message)s', ]) diff --git a/ipalib/plugable.py b/ipalib/plugable.py index dd74dc08e..b0ba32b7e 100644 --- a/ipalib/plugable.py +++ b/ipalib/plugable.py @@ -744,7 +744,7 @@ class API(DictProxy): self.env.log, self.env.verbose, ) - object.__setattr__(self, 'log', 'logger') + object.__setattr__(self, 'logger', logger) def load_plugins(self): """ diff --git a/ipalib/util.py b/ipalib/util.py index 280910dc6..d577524b0 100644 --- a/ipalib/util.py +++ b/ipalib/util.py @@ -114,10 +114,10 @@ def configure_logging(log_file, verbose): level -= 10 log = logging.getLogger('ipa') + log.setLevel(level) # Configure console handler console = logging.StreamHandler() - console.setLevel(level) console.setFormatter(logging.Formatter(LOGGING_CONSOLE_FORMAT)) log.addHandler(console) @@ -130,7 +130,6 @@ def configure_logging(log_file, verbose): log.warn('Could not create log_dir %r', log_dir) return log file_handler = logging.FileHandler(log_file) - file_handler.setLevel(level) file_handler.setFormatter(logging.Formatter(LOGGING_FILE_FORMAT)) log.addHandler(file_handler) |