FAQ
Hello,


I am trying to figure out which logger to use for one of the project I am
working on and am getting lost in the forest of logging packages out there.
I definitely do not want to write my own!

Here are my main criterias for selecting one:
- fast (!) i.e fancy coloring and things not important
- log rotation
- log compression is a plus but not required
- levelled
- support non evaluation of log parameters ala glog
- support linux and windows

I find glog almost right but it does not support log rotation. Some forks
of it meet my needs except for the last one (at least for the ones I have
checked).

Anyone been through this before and have found something interesting?


Thank you,

Pierre

--
You received this message because you are subscribed to the Google Groups "golang-nuts" group.
To unsubscribe from this group and stop receiving emails from it, send an email to golang-nuts+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Search Discussions

  • Jan Mercl at Jun 24, 2015 at 9:17 am

    On Wed, Jun 24, 2015 at 11:11 AM wrote:

    I find glog almost right but it does not support log rotation.
    https://github.com/golang/glog/blob/44145f04b68cf362d9c4df2182967c2275eaefed/glog.go#L812

    -j
    --

    -j

    --
    You received this message because you are subscribed to the Google Groups "golang-nuts" group.
    To unsubscribe from this group and stop receiving emails from it, send an email to golang-nuts+unsubscribe@googlegroups.com.
    For more options, visit https://groups.google.com/d/optout.
  • Pierre Curto at Jun 24, 2015 at 10:52 am
    Ah great, thanks Jan.

    Le mercredi 24 juin 2015 11:17:16 UTC+2, Jan Mercl a écrit :
    On Wed, Jun 24, 2015 at 11:11 AM <pierre...@gmail.com <javascript:>>
    wrote:
    I find glog almost right but it does not support log rotation.

    https://github.com/golang/glog/blob/44145f04b68cf362d9c4df2182967c2275eaefed/glog.go#L812

    -j
    --

    -j
    --
    You received this message because you are subscribed to the Google Groups "golang-nuts" group.
    To unsubscribe from this group and stop receiving emails from it, send an email to golang-nuts+unsubscribe@googlegroups.com.
    For more options, visit https://groups.google.com/d/optout.
  • Kiki Sugiaman at Jun 24, 2015 at 12:02 pm

    On 24/06/15 19:11, pierre.curto@gmail.com wrote:
    Hello,


    I am trying to figure out which logger to use for one of the project I
    am working on and am getting lost in the forest of logging packages
    out there. I definitely do not want to write my own!

    Here are my main criterias for selecting one:
    - fast (!) i.e fancy coloring and things not important
    - log rotation
    Lumberjack supports log rotation:
    https://github.com/natefinch/lumberjack

    - log compression is a plus but not required
    I prefer doing compression on the sysadmin side, but it's not hard to
    gzip your log programmatically (sp?).
    In essence:
    lumberjack.Logger | gzip.NewWriter() | log.SetOutput()

    I don't know about your other requirements.

    - levelled
    - support non evaluation of log parameters ala glog
    - support linux and windows

    I find glog almost right but it does not support log rotation. Some
    forks of it meet my needs except for the last one (at least for the
    ones I have checked).

    Anyone been through this before and have found something interesting?


    Thank you,

    Pierre
    --
    You received this message because you are subscribed to the Google
    Groups "golang-nuts" group.
    To unsubscribe from this group and stop receiving emails from it, send
    an email to golang-nuts+unsubscribe@googlegroups.com
    For more options, visit https://groups.google.com/d/optout.
    --
    You received this message because you are subscribed to the Google Groups "golang-nuts" group.
    To unsubscribe from this group and stop receiving emails from it, send an email to golang-nuts+unsubscribe@googlegroups.com.
    For more options, visit https://groups.google.com/d/optout.
  • Kiki Sugiaman at Jun 24, 2015 at 12:27 pm
    Small caveat to my previous reply, the gzip.Writer.Write() does not
    necessarily flush until closed. So it may cause problem with crashes if
    you don't provision for it.
    I think with some compression algo, it just comes with the territory.

    --
    You received this message because you are subscribed to the Google Groups "golang-nuts" group.
    To unsubscribe from this group and stop receiving emails from it, send an email to golang-nuts+unsubscribe@googlegroups.com.
    For more options, visit https://groups.google.com/d/optout.

Related Discussions

Discussion Navigation
viewthread | post
Discussion Overview
groupgolang-nuts @
categoriesgo
postedJun 24, '15 at 9:11a
activeJun 24, '15 at 12:27p
posts5
users3
websitegolang.org

People

Translate

site design / logo © 2021 Grokbase