Skip to content

Commit

Permalink
fmt fix
Browse files Browse the repository at this point in the history
  • Loading branch information
gurinderu committed May 17, 2024
1 parent f69b1df commit 6f8355f
Showing 1 changed file with 0 additions and 29 deletions.
29 changes: 0 additions & 29 deletions crates/core-manager/src/dummy.rs
Original file line number Diff line number Diff line change
Expand Up @@ -106,32 +106,3 @@ impl CoreManagerFunctions for DummyCoreManager {
}
}
}

#[async_trait]
impl CoreManagerFunctions for DummyCoreManager {
fn acquire_worker_core(
&self,
assign_request: AcquireRequest,
) -> Result<Assignment, AcquireError> {
let all_cores = self.all_cores();

let logical_core_ids: BTreeSet<LogicalCoreId> = BTreeSet::from_iter(
all_cores
.logical_core_ids
.into_iter()
.choose_multiple(&mut rand::thread_rng(), assign_request.unit_ids.len()),
);

Ok(Assignment {
physical_core_ids: BTreeSet::new(),
logical_core_ids,
cuid_cores: Map::with_hasher(FxBuildHasher::default()),
})
}

fn release(&self, _unit_ids: &[CUID]) {}

fn get_system_cpu_assignment(&self) -> Assignment {
self.all_cores()
}
}

0 comments on commit 6f8355f

Please sign in to comment.