Skip to content

Commit

Permalink
Remove BACKEND_ISOLATE_ACTIVE_THREADS_PERCENT (#33627)
Browse files Browse the repository at this point in the history
GitOrigin-RevId: c1ecab904e1580ad194ee585f7290e442d485e1d
  • Loading branch information
goffrie authored and Convex, Inc. committed Jan 24, 2025
1 parent 10cd808 commit 73ae005
Show file tree
Hide file tree
Showing 2 changed files with 0 additions and 26 deletions.
13 changes: 0 additions & 13 deletions crates/application/src/application_function_runner/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,6 @@ use common::{
APPLICATION_MAX_CONCURRENT_NODE_ACTIONS,
APPLICATION_MAX_CONCURRENT_QUERIES,
APPLICATION_MAX_CONCURRENT_V8_ACTIONS,
BACKEND_ISOLATE_ACTIVE_THREADS_PERCENT,
ISOLATE_MAX_USER_HEAP_SIZE,
UDF_EXECUTOR_OCC_INITIAL_BACKOFF,
UDF_EXECUTOR_OCC_MAX_BACKOFF,
Expand Down Expand Up @@ -596,18 +595,6 @@ impl<RT: Runtime> ApplicationFunctionRunner<RT> {
system_env_vars: BTreeMap<EnvVarName, EnvVarValue>,
cache: QueryCache,
) -> Self {
// We limit the isolates to only consume fraction of the available
// cores leaving the rest for tokio. This is still over-provisioning
// in case there are multiple active backends per server.
let isolate_concurrency_limit =
*BACKEND_ISOLATE_ACTIVE_THREADS_PERCENT * num_cpus::get_physical() / 100;
tracing::info!(
"Limiting isolate concurrency to {} ({}% out of {} physical cores)",
isolate_concurrency_limit,
*BACKEND_ISOLATE_ACTIVE_THREADS_PERCENT,
num_cpus::get_physical(),
);

let isolate_functions = FunctionRouter::new(
function_runner,
runtime.clone(),
Expand Down
13 changes: 0 additions & 13 deletions crates/common/src/knobs.rs
Original file line number Diff line number Diff line change
Expand Up @@ -984,19 +984,6 @@ pub static SEARCHLIGHT_CLUSTER_NAME: LazyLock<String> = LazyLock::new(|| {
pub static FUNRUN_ISOLATE_ACTIVE_THREADS: LazyLock<usize> =
LazyLock::new(|| env_config("FUNRUN_ISOLATE_ACTIVE_THREADS", 0));

/// What percentage of the physical CPU cores can be actively used by the
/// isolate.
///
/// Give 50% of physical cores to v8. Note that we are still oversubscribing
/// the CPU since we run multiple backends per server. This is fine since we
/// are moving js execution to Funrun.
pub static BACKEND_ISOLATE_ACTIVE_THREADS_PERCENT: LazyLock<usize> = LazyLock::new(|| {
env_config(
"BACKEND_ISOLATE_ACTIVE_THREADS_PERCENT",
prod_override(100, 50),
)
});

/// How long to splay deploying AWS Lambdas due to changes in the backend. This
/// knob doesn't delay deploys that are required due to the user pushing new
/// node actions. Only affects deploys on startup triggered by changes to
Expand Down

0 comments on commit 73ae005

Please sign in to comment.