Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
26 changes: 16 additions & 10 deletions apps/mcp-proxy-server/src/main.rs
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ use anyhow::Result;
use clap::Parser;
use rmcp::{ServiceExt, transport::stdio};
use server::mcp_proxy_client::get_mcp_client;
use tracing_subscriber::{self, EnvFilter};
// use tracing_subscriber::{self, EnvFilter};

pub mod server;

Expand All @@ -16,15 +16,21 @@ struct Args {

#[tokio::main]
async fn main() -> Result<()> {
tracing_subscriber::fmt()
.with_env_filter(EnvFilter::from_default_env().add_directive(tracing::Level::DEBUG.into()))
.with_target(false)
.with_thread_ids(true)
.with_file(true)
.with_line_number(true)
.with_writer(std::io::stderr)
.with_ansi(false)
.init();
/*
In most cases we can use this tracing subscriber using the stderr as writer
BUT
there are some apps like IntelliJ products that flag an mcp server as errored
when found any error in the logs.
*/
// tracing_subscriber::fmt()
// .with_env_filter(EnvFilter::from_default_env().add_directive(tracing::Level::DEBUG.into()))
// .with_target(false)
// .with_thread_ids(true)
// .with_file(true)
// .with_line_number(true)
// .with_writer(std::io::stderr)
// .with_ansi(false)
// .init();

tracing::info!("Starting MCP Dockmaster Proxy Server");

Expand Down
Loading