Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix(runtime): remove forcing tokio core count to 2 #2087

Open
wants to merge 1 commit into
base: 02-26-chore_runtime_add_otel_support_to_runtime
Choose a base branch
from
Open
Show file tree
Hide file tree
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
4 changes: 2 additions & 2 deletions packages/common/chirp/perf/src/ctx.rs
Original file line number Diff line number Diff line change
Expand Up @@ -202,7 +202,7 @@ impl PerfCtxInner {
.await
.push(PerfMark::new(base_ts, label, None, None));
}
.instrument(tracing::info_span!("perf_mark_async")),
.instrument(tracing::trace_span!("perf_mark_async")),
);
if let Err(err) = spawn_res {
tracing::error!(?err, "failed to spawn perf_mark_async task");
Expand Down Expand Up @@ -237,7 +237,7 @@ impl PerfCtxInner {
Some(req_id),
));
}
.instrument(tracing::info_span!("perf_mark_rpc_async")),
.instrument(tracing::trace_span!("perf_mark_rpc_async")),
);
if let Err(err) = spawn_res {
tracing::error!(?err, "failed to spawn perf_mark_rpc_async task");
Expand Down
8 changes: 0 additions & 8 deletions packages/common/runtime/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -38,14 +38,6 @@ fn build_tokio_runtime_builder() -> tokio::runtime::Builder {

if let Ok(worker_threads) = env::var("TOKIO_WORKER_THREADS") {
rt_builder.worker_threads(worker_threads.parse().unwrap());
} else {
// Default to 2 threads since this is likely running in a shared
// context. If we constrain this task to use 100 MHz an 8 core system,
// it will still spawn 8 threads needlessly.
//
// If a service is configured to use a dedicated core, Bolt will expose
// the correct thread count.
rt_builder.worker_threads(2);
}

if let Ok(max_blocking_threads) = env::var("TOKIO_MAX_BLOCKING_THREADS") {
Expand Down
Loading