File tree Expand file tree Collapse file tree 1 file changed +8
-4
lines changed Expand file tree Collapse file tree 1 file changed +8
-4
lines changed Original file line number Diff line number Diff line change 1
1
#![ doc = include_str ! ( "../README.md" ) ]
2
2
3
3
use clap:: Parser ;
4
- use mithril_aggregator:: { CommandType , MainOpts } ;
5
- use mithril_common:: StdResult ;
6
4
use slog:: { Drain , Fuse , Level , Logger } ;
7
5
use slog_async:: Async ;
8
6
use std:: sync:: Arc ;
9
7
8
+ use mithril_aggregator:: { CommandType , MainOpts } ;
9
+ use mithril_common:: StdResult ;
10
+
10
11
fn build_io_logger < W : std:: io:: Write + Send + ' static > ( log_level : Level , io : W ) -> Fuse < Async > {
11
- let drain = slog_bunyan:: new ( io) . set_pretty ( false ) . build ( ) . fuse ( ) ;
12
+ let drain = slog_bunyan:: with_name ( "mithril-aggregator" , io)
13
+ . set_pretty ( false )
14
+ . build ( )
15
+ . fuse ( ) ;
12
16
let drain = slog:: LevelFilter :: new ( drain, log_level) . fuse ( ) ;
13
17
14
- slog_async :: Async :: new ( drain) . build ( ) . fuse ( )
18
+ Async :: new ( drain) . build ( ) . fuse ( )
15
19
}
16
20
17
21
/// Build a logger from args.
You can’t perform that action at this time.
0 commit comments