Giter Club home page Giter Club logo

Comments (11)

dpc avatar dpc commented on July 25, 2024 1

I'm closing this issue, but it's OK to keep chatting here. I even linked to it from README.

I'm quite content with what I got with slog: couple of more features, some polishing, and I'll release 1.0, and see if the project gains traction, are there any rev-dependencies, PRs etc.

I would be happy to share the project ownership, but I basically want to keep the top-level design that loggers form a hierarchy of key-value sequences, and output into a composable drains that perform all functions: multiplexing, filtering, formatting, io etc. I find it very elegant.

from slog.

dpc avatar dpc commented on July 25, 2024

Hi! I knew that I'm going to miss someones crate! I need some time evaluate blacklog. With slog, I was kind of reaching the core feature completeness, and I think everything else can be implemented as additional crates. If blacklog has some features or potential for them that slog can't get, I'd be happy to merge or switch to help you. You could do the same with slog and we can discuss approaches. Worst case, if we disagree with our assesment, there can be two awesome structured logging crates for Rust. :)

from slog.

3Hren avatar 3Hren commented on July 25, 2024

Hi! I knew that I'm going to miss someones crate!

I checked crates.io about 2 month ago and didn't find similar crate. For now I just didn't announce it, because blacklog requires nightly (temporary).

Worst case, if we disagree with our assesment, there can be two awesome structured logging crates for Rust.

Yep, that's why I created this issue, because I believe that it is better to focus on a single great library instead of two with nearly-the-same functionality. However we need a third man for quorum :).

Okay

May I tell you what I want for every language to be available as libraries in three words: logs, metrics, tracing. I believe that it is the required tools all need for developing and debugging applications/libraries.

With slog, I was kind of reaching the core feature completeness ...

Yes, functionality is ok, but the performance can be better (much). Sadly, but sometimes it requires to rewrite everything from the scratch. That's why I suggested to calm down and to reunite - two clever heads is better than one.

Thoughts?

from slog.

dpc avatar dpc commented on July 25, 2024

Did you do any performance analysis already?

from slog.

3Hren avatar 3Hren commented on July 25, 2024

No, just looked into the code. Having an experience with profiling/measuring many logging C++ libraries in the past, a brief look was enough at this moment. :)

from slog.

dpc avatar dpc commented on July 25, 2024

So what do you think is will drag the performance down?

from slog.

3Hren avatar 3Hren commented on July 25, 2024

As usual: syscalls, heap allocation, cache misses and cache synchronization. Anyway, it's not the goal of the issue.

from slog.

dpc avatar dpc commented on July 25, 2024

Please correct me if I got something wrong.

It seems in blacklog the approach is somewhat more complex. I don't fully understand everything. Eg. actors, layouts. In slog I've abstracted everything as a Drain and drains form a hierarchies, that act as filters, writers, io. Since drains are statically parametrized, compiler should be able to do a good job in merging them into once logic. Formaters are parts of respective drains (while can be reused as they implement a common trait), where slog only provides a facade for serialialization (that seems to be similar), while it looks like in blacklog there's more code for explicitly handling formatting. slog seems simpler, but maybe it's simplistic and you know some stuff that I missed.

Logging configuration from a yaml file, seems like an important issue for you, while I kind of dismissed it. I hope it can be implemented as a 3rd-party Drain (that just creates other drains according).

I really do like modularity in slog - the fact that except small core everything is in a separate crates.

As much as I can tell other other stuff seems very similar. Small difference in API (different macros), then trying to avoid clone, not block on anything much etc.

Actually I think the performance is very important and affects design and API a lot. I still do have couple of performance changes eg. reusing string, gathering log messages etc. But I hope the slog does not have any fundamental issues that would make it slow.

from slog.

nblumhardt avatar nblumhardt commented on July 25, 2024

Third effort! :-) https://github.com/emit-rs/emit

@KodrAus and I have been chipping away at this one when time permits for a little while. I think it's awesome that a few more options are appearing - in the long run the diversity will be good for the ecosystem.

While we're all exploring the design space I'm not sure there will be much shareable output, but I just wanted to drop you a line and let you both know we're out here, in case there's an opportunity to exchange ideas or collaborate down the track.

Cheers!

from slog.

dpc avatar dpc commented on July 25, 2024

Hah. So it seems we all took inspiration from different projects, in other languages, no?

from slog.

nblumhardt avatar nblumhardt commented on July 25, 2024

Apparently so! 😄

from slog.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.