Skip to content

use clog, our fork of glog - #963

Merged
tbg merged 2 commits into
cockroachdb:masterfrom
tbg:clog
May 8, 2015
Merged

tbg merged 2 commits into
cockroachdb:masterfrom
tbg:clog

Conversation

@tbg

@tbg tbg commented May 8, 2015

Copy link
Copy Markdown
Contributor

Currently this should behave identically to glog but we can now use our own version of V(.).
The plan is:

  • add switch to glog that omits the header (so it prints only your log message)
  • add functions log.Infoc(ctx context.Context, msg) which will wrap around clog.Print(f?)
  • clean up the other formatted loggers. We shouldn't be logging much unstructured data at all, so it may be a good idea to remove all log functions log\.\w+f.
  • switch away from flag handling, or at least switch to pflags.

Partakers of this PR should also check out the relevant commit https://github.com/cockroachdb/clog/commit/d2542376307a54ad0ff768be384c3c589ffacca1 on clog. From now on I'll do PRs there as well.

@tbg tbg added the PTAL label May 8, 2015
@tbg

tbg commented May 8, 2015

Copy link
Copy Markdown
Contributor Author

I'll move the TODO list into issues once I'm done here, btw.

Comment thread util/sampling.go Outdated

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should this be using cockroachdb/cockroach/util/log?

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

yes. I'll fix it. And by "fix" I mean I will delete the file since we're not using it anyways.

@petermattis

Copy link
Copy Markdown
Contributor

LGTM

tbg added a commit that referenced this pull request May 8, 2015
use clog, our fork of glog
@tbg
tbg merged commit 80a5c3f into cockroachdb:master May 8, 2015
@tbg
tbg deleted the clog branch May 8, 2015 01:23
@tbg tbg removed the PTAL label May 8, 2015
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants