Logger prefixes for api/apiserver are changing
Menno Smits
menno.smits at canonical.com
Wed Sep 3 03:07:11 UTC 2014
On 3 September 2014 15:00, John Meinel <john at arbash-meinel.com> wrote:
> ...
>>
>> There were two ideas proposed:
>>
>> loggo.LoggerForPackage("juju")
>>
>> which would walk up the path until it found a path element juju, and
>> construct the string that way. The other was do use a defined prefix:
>>
>
> The only problem here is that we have:
> github.com/juju/juju/juju
> and
> github.com/juju/juju/cmd/juju
>
> Which would confuse this algorithm. Though I like its brevity.
>
Ha! I was just about to hit send on an email saying exactly the same thing
:)
Also, when we talk about package paths we really mean the source tree path
right? Every in cmd/juju is in the "main" package but uses a logger named
"juju.cmd.juju". We can really use the real package name to set the logger
name.
- Menno
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.ubuntu.com/archives/juju-dev/attachments/20140903/60a49fff/attachment.html>
More information about the Juju-dev
mailing list