lnd: remove seelog logger

The btclog package has been changed to defining its own logging
interface (rather than seelog's) and provides a default implementation
for callers to use.

There are two primary advantages to the new logger implementation.

First, all log messages are created before the call returns.  Compared
to seelog, this prevents data races when mutable variables are logged.

Second, the new logger does not implement any kind of artifical rate
limiting (what seelog refers to as "adaptive logging").  Log messages
are outputted as soon as possible and the application will appear to
perform much better when watching standard output.

Because log rotation is not a feature of the btclog logging
implementation, it is handled by the main package by importing a file
rotation package that provides an io.Reader interface for creating
output to a rotating file output.  The rotator has been configured
with the same defaults that btcd previously used in the seelog config
(10MB file limits with maximum of 3 rolls) but now compresses newly
created roll files.  Due to the high compressibility of log text, the
compressed files typically reduce to around 15-30% of the original
10MB file.
This commit is contained in:
Andrey Samokhvalov authored and Olaoluwa Osuntokun committed 2017-06-25 14:19:56 +01:00
1 parent c233b8816e
commit 8fa2b95c12
12 files changed
+115 -337

No files matched your search

+4 -5
View File
@@ -4,8 +4,7 @@ import:
version: ^1.2.1
- package: github.com/btcsuite/btclog
- package: github.com/btcsuite/go-flags
- package: github.com/btcsuite/seelog
version: ^2.1.0
- package: github.com/jrick/logrotate
- package: github.com/davecgh/go-spew
subpackages:
- spew
@@ -14,7 +13,7 @@ import:
- proto
- package: github.com/howeyc/gopass
- package: github.com/roasbeef/btcd
version: 4d38357cee3ed3843cd81a347e1573f037e0301e
version: 34fdda7d41cc47d9456550fd1147a77db89f601a
subpackages:
- blockchain
- btcec
@@ -24,7 +23,7 @@ import:
- wire
- connmgr
- package: github.com/roasbeef/btcrpcclient
version: 9a7826550df8071460e2f5dd6ed9139dcbf260b8
version: d0f4db8b4dad0ca3d569b804f21247c3dd96acbb
- package: github.com/roasbeef/btcutil
version: a259eaf2ec1b54653cdd67848a41867f280797ee
subpackages:
@@ -69,4 +68,4 @@ import:
subpackages:
- chaincfg
- package: github.com/lightninglabs/neutrino
version: 38ea335359ce38a83d51caea7a39a3a8658d30a4
version: ccfa94a1c213e5df752c08c7edc30cb0a56d4dcf