Skip to content

Commit

Permalink
wip
Browse files Browse the repository at this point in the history
  • Loading branch information
fafhrd91 committed Jan 31, 2025
1 parent fc43822 commit 1ccbc4a
Show file tree
Hide file tree
Showing 4 changed files with 16 additions and 4 deletions.
2 changes: 1 addition & 1 deletion ntex-server/src/net/builder.rs
Original file line number Diff line number Diff line change
Expand Up @@ -110,7 +110,7 @@ impl ServerBuilder {
self
}

/// Enable core affinity
/// Enable cpu affinity
///
/// By default affinity is disabled.
pub fn enable_affinity(mut self) -> Self {
Expand Down
4 changes: 4 additions & 0 deletions ntex/CHANGES.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,9 @@
# Changes

## [2.11.0] - 2025-01-31

* Cpu affinity support for server

## [2.10.0] - 2024-12-04

* Use updated Service trait
Expand Down
6 changes: 3 additions & 3 deletions ntex/Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[package]
name = "ntex"
version = "2.10.0"
version = "2.11.0"
authors = ["ntex contributors <[email protected]>"]
description = "Framework for composable network services"
readme = "README.md"
Expand Down Expand Up @@ -68,8 +68,8 @@ ntex-service = "3.4"
ntex-macros = "0.1"
ntex-util = "2.8"
ntex-bytes = "0.1.27"
ntex-server = "2.6"
ntex-h2 = "1.5"
ntex-server = "2.7"
ntex-h2 = "1.8.1"
ntex-rt = "0.4.22"
ntex-io = "2.9"
ntex-net = "2.4"
Expand Down
8 changes: 8 additions & 0 deletions ntex/src/web/server.rs
Original file line number Diff line number Diff line change
Expand Up @@ -310,6 +310,14 @@ where
self
}

/// Enable cpu affinity
///
/// By default affinity is disabled.
pub fn enable_affinity(mut self) -> Self {
self.builder = self.builder.enable_affinity();
self
}

Check warning on line 319 in ntex/src/web/server.rs

View check run for this annotation

Codecov / codecov/patch

ntex/src/web/server.rs#L316-L319

Added lines #L316 - L319 were not covered by tests

/// Set io tag for web server
pub fn tag(self, tag: &'static str) -> Self {
self.config.lock().unwrap().tag = tag;
Expand Down

0 comments on commit 1ccbc4a

Please sign in to comment.