-
Notifications
You must be signed in to change notification settings - Fork 2.1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Extend the LogSink interface to be able to pass microseconds #441
Conversation
Thanks for your pull request. It looks like this may be your first contribution to a Google open source project (if not, look below for help). Before we can look at your pull request, you'll need to sign a Contributor License Agreement (CLA). 📝 Please visit https://cla.developers.google.com/ to sign. Once you've signed (or fixed any issues), please reply here (e.g. What to do if you already signed the CLAIndividual signers
Corporate signers
ℹ️ Googlers: Go here for more info. |
I signed it! |
CLAs look good, thanks! ℹ️ Googlers: Go here for more info. |
@asekretenko would it make sense for the |
Probably it makes sense. |
On the other hand, on some crazy (or "slightly buggy") platform we might get a negative value here for some corner case. Seeing ".-000001" in the microseconds would help to understand what the hell is going on much better than seeing seemingly normal values in a strange order. Been there, done that (albeit with another logging system). Probably it would be better to follow advice from Google's style guide
and leave microseconds signed. |
Extended the LogSink interface to be able to log microseconds. This makes possible to solve a problem with modules implementing custom LogSink which currently log 000000 instead of microseconds. This is a backport of this patch: google/glog#441 to glog 0.3.3 Review: https://reviews.apache.org/r/70334/
Extended the LogSink interface to be able to log microseconds. This makes possible to solve a problem with modules implementing custom LogSink which currently log 000000 instead of microseconds. This is a backport of this patch: google/glog#441 to glog 0.3.3 Review: https://reviews.apache.org/r/70334/
Extended the LogSink interface to be able to log microseconds. This makes possible to solve a problem with modules implementing custom LogSink which currently log 000000 instead of microseconds. This is a backport of this patch: google/glog#441 to glog 0.3.3 Review: https://reviews.apache.org/r/70334/
The goal of this PR is to solve the problem of passing microseconds into custom LogSink implementations that was described in #307.
I am proposing a slightly different approach, however: instead of modifying the existing send() signature I am adding the second one.
This has an advantage of not breaking all the third-party LogSink implementations immediately (including ours) ... and, unfortunately, all the disadvantages associated with this approach.