logging format improvements

Bug #1161660 reported by Ian Booth
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
juju-core
Fix Released
High
Dimiter Naydenov

Bug Description

juju log messages use a format like so:

<datetime> <severity> JUJU:<cmd> <msg text>

where, if command is a subcommand, it prints as <super cmd>:<cmd>

However, super command is always "juju" so that results in too much juju in the message.

<msg> often also contains text like "cmd/juju: blah blah", since it was logged like so:

log.Infof("cmd/juju: looking blah blah...")

Also, for the following situation:

2013/03/28 18:42:10 INFO JUJU:juju:publish charm sent; waiting for it to be published...

"publish" is the command name.. it's not the "publish charm".

We need to:

1. drop from the command name rendering the super command name

2. drop the ad hoc "cmd/juju" type text from log messages since the standard format now contains that information

3. add a separator between <cmd> and <msg> so that the command name and message are not confused.
.

Tags: logging
Revision history for this message
Dimiter Naydenov (dimitern) wrote :
Changed in juju-core:
status: Triaged → Fix Committed
assignee: nobody → Dimiter Naydenov (dimitern)
Changed in juju-core:
milestone: none → 1.9.14
Tim Penhey (thumper)
Changed in juju-core:
status: Fix Committed → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.