mirror of
https://github.com/neondatabase/neon.git
synced 2026-05-24 00:20:37 +00:00
add tokio-console
This commit is contained in:
@@ -85,7 +85,7 @@ tokio-postgres.workspace = true
|
||||
tokio-postgres-rustls.workspace = true
|
||||
tokio-rustls.workspace = true
|
||||
tokio-util.workspace = true
|
||||
tokio = { workspace = true, features = ["signal"] }
|
||||
tokio = { workspace = true, features = ["signal", "tracing"] }
|
||||
tracing-opentelemetry.workspace = true
|
||||
tracing-subscriber.workspace = true
|
||||
tracing-utils.workspace = true
|
||||
@@ -99,6 +99,8 @@ x509-parser.workspace = true
|
||||
postgres-protocol.workspace = true
|
||||
redis.workspace = true
|
||||
|
||||
console-subscriber = "0.2.0"
|
||||
|
||||
workspace_hack.workspace = true
|
||||
|
||||
[dev-dependencies]
|
||||
|
||||
@@ -26,7 +26,12 @@ pub async fn init() -> anyhow::Result<LoggingGuard> {
|
||||
.await
|
||||
.map(OpenTelemetryLayer::new);
|
||||
|
||||
// spawn the console server in the background,
|
||||
// returning a `Layer`:
|
||||
let console_layer = console_subscriber::spawn();
|
||||
|
||||
tracing_subscriber::registry()
|
||||
.with(console_layer)
|
||||
.with(env_filter)
|
||||
.with(otlp_layer)
|
||||
.with(fmt_layer)
|
||||
|
||||
Reference in New Issue
Block a user