Commit Graph

8 Commits

Author SHA1 Message Date
Brian Picciano
2e269bb6e7 mlog: refactor to use a Stringer for Message.Description 2018-11-30 18:50:08 -05:00
Brian Picciano
b5c676b5c8 mlog: complete refactor again, eliminating the go-routine, which allowed a lot of other things to fall into place nicely 2018-11-30 16:27:18 -05:00
Brian Picciano
5c85969bc7 mlog: use a Clone and Set methods instead of With methods 2018-10-28 15:09:42 -04:00
Brian Picciano
8368d0881b mlog: change how Merge/MergeInto work, so they don't evaluate the KV immediately 2018-07-19 18:43:17 +00:00
Brian Picciano
f0032a19d1 mlog: refactor tests to use massert 2018-07-19 18:19:26 +00:00
Brian Picciano
6c17eaa62f mlog: implement KVerFunc and Prefix 2018-07-18 23:01:28 +00:00
Brian Picciano
15efa4ba3a mlog: refactor to handle certain use cases better, and make KV merging more consistent
Logger is now initialized with its WriteCloser (which can never change
after initialization) and then has its properties modified via method
calls. These method calls return new copies of the Logger, all writing
to the same original WriteCloser still. This allows for doing things
like having a Logger within some entity that has its own KV, for
example.

Also I revamped the merging code a bit, and fixed a precedence
inconsitency in ErrWithKV and CtxWithKV.
2018-05-28 07:53:39 +00:00
Brian Picciano
93cfa66c4b rename some mlog files, change KVer interface slightly 2018-02-15 21:23:04 +00:00