mirror of
https://github.com/YGGverse/aquatic.git
synced 2026-03-31 17:55:36 +00:00
Move CoreAffinityConfig to aquatic_common, use in glommio http
This commit is contained in:
parent
8747f8de4e
commit
d659117ae5
7 changed files with 37 additions and 23 deletions
|
|
@ -1,6 +1,7 @@
|
|||
use std::net::SocketAddr;
|
||||
|
||||
use aquatic_common::access_list::AccessListConfig;
|
||||
use aquatic_common::cpu_pinning::CoreAffinityConfig;
|
||||
use serde::{Deserialize, Serialize};
|
||||
|
||||
use aquatic_cli_helpers::LogLevel;
|
||||
|
|
@ -109,13 +110,6 @@ pub struct PrivilegeConfig {
|
|||
pub user: String,
|
||||
}
|
||||
|
||||
#[derive(Clone, Debug, Serialize, Deserialize)]
|
||||
#[serde(default)]
|
||||
pub struct CoreAffinityConfig {
|
||||
pub set_affinities: bool,
|
||||
pub offset: usize,
|
||||
}
|
||||
|
||||
impl Default for Config {
|
||||
fn default() -> Self {
|
||||
Self {
|
||||
|
|
@ -193,12 +187,3 @@ impl Default for PrivilegeConfig {
|
|||
}
|
||||
}
|
||||
}
|
||||
|
||||
impl Default for CoreAffinityConfig {
|
||||
fn default() -> Self {
|
||||
Self {
|
||||
set_affinities: false,
|
||||
offset: 0,
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue