Merge pull request #3532 from guggero/refactor-log-writer

build+lnd: refactor reusable log file rotator code into build package
This commit is contained in:
Conner Fromknecht authored and GitHub committed 2019-10-16 12:59:39 +02:00
commit c10eacaa24
6 files changed
+334 -257

No files matched your search

+5 -2
View File
@@ -4348,7 +4348,9 @@ func (r *rpcServer) DebugLevel(ctx context.Context,
// sub-systems.
if req.Show {
return &lnrpc.DebugLevelResponse{
SubSystems: strings.Join(supportedSubsystems(), " "),
SubSystems: strings.Join(
logWriter.SupportedSubsystems(), " ",
),
}, nil
}
@@ -4356,7 +4358,8 @@ func (r *rpcServer) DebugLevel(ctx context.Context,
// Otherwise, we'll attempt to set the logging level using the
// specified level spec.
if err := parseAndSetDebugLevels(req.LevelSpec); err != nil {
err := build.ParseAndSetDebugLevels(req.LevelSpec, logWriter)
if err != nil {
return nil, err
}