mirror of
https://github.com/sigp/lighthouse.git
synced 2026-03-04 01:01:41 +00:00
Integrate tracing (#6339)
Tracing Integration
- [reference](5bbf1859e9/projects/project-ideas.md (L297))
- [x] replace slog & log with tracing throughout the codebase
- [x] implement custom crit log
- [x] make relevant changes in the formatter
- [x] replace sloggers
- [x] re-write SSE logging components
cc: @macladson @eserilev
This commit is contained in:
@@ -105,7 +105,6 @@ async fn import_and_unlock(http_url: SensitiveUrl, priv_keys: &[&str], password:
|
||||
|
||||
impl<Engine: GenericExecutionEngine> TestRig<Engine> {
|
||||
pub fn new(generic_engine: Engine) -> Self {
|
||||
let log = logging::test_logger();
|
||||
let runtime = Arc::new(
|
||||
tokio::runtime::Builder::new_multi_thread()
|
||||
.enable_all()
|
||||
@@ -114,7 +113,12 @@ impl<Engine: GenericExecutionEngine> TestRig<Engine> {
|
||||
);
|
||||
let (runtime_shutdown, exit) = async_channel::bounded(1);
|
||||
let (shutdown_tx, _) = futures::channel::mpsc::channel(1);
|
||||
let executor = TaskExecutor::new(Arc::downgrade(&runtime), exit, log.clone(), shutdown_tx);
|
||||
let executor = TaskExecutor::new(
|
||||
Arc::downgrade(&runtime),
|
||||
exit,
|
||||
shutdown_tx,
|
||||
"test".to_string(),
|
||||
);
|
||||
let mut spec = TEST_FORK.make_genesis_spec(MainnetEthSpec::default_spec());
|
||||
spec.terminal_total_difficulty = Uint256::ZERO;
|
||||
|
||||
@@ -131,8 +135,7 @@ impl<Engine: GenericExecutionEngine> TestRig<Engine> {
|
||||
default_datadir: execution_engine.datadir(),
|
||||
..Default::default()
|
||||
};
|
||||
let execution_layer =
|
||||
ExecutionLayer::from_config(config, executor.clone(), log.clone()).unwrap();
|
||||
let execution_layer = ExecutionLayer::from_config(config, executor.clone()).unwrap();
|
||||
ExecutionPair {
|
||||
execution_engine,
|
||||
execution_layer,
|
||||
@@ -150,8 +153,7 @@ impl<Engine: GenericExecutionEngine> TestRig<Engine> {
|
||||
default_datadir: execution_engine.datadir(),
|
||||
..Default::default()
|
||||
};
|
||||
let execution_layer =
|
||||
ExecutionLayer::from_config(config, executor, log.clone()).unwrap();
|
||||
let execution_layer = ExecutionLayer::from_config(config, executor).unwrap();
|
||||
ExecutionPair {
|
||||
execution_engine,
|
||||
execution_layer,
|
||||
|
||||
Reference in New Issue
Block a user