-
Notifications
You must be signed in to change notification settings - Fork 12.7k
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
std::net::bind using -1 for openbsd which in turn sets it to somaxconn. #119026
Conversation
(rustbot has picked a reviewer for you, use r? to override) |
I'm going to nominate for T-libs-api. This is changing the listen backlog size to the platform maximum (via -1 or SOMAXCONN) from 128 on most platforms. On Linux this has no effect; we previously changed from our current fallback default of 128 to -1 there in #97963. #55614 is tracking a general request to make this configurable, and has a comment that seems plausible in terms of not wanting to change the behavior here:
It's not obviously the case that this is API surface area, but I think getting an opinion from the team would be useful here. Do we want to continue to land PRs which increase the backlog size to ~maximum allowed on the system? (Perhaps finished with this PR + changes in |
We discussed this in the libs-api meeting. We have no objections to this change: it seems like it won't cause much behavior difference, and somaxconn can generally by controlled system-wide anyways. |
@bors r+ |
…lacrum std::net::bind using -1 for openbsd which in turn sets it to somaxconn. trusting platform's SOMAXCONN instead of hardcoding to 128 otherwise.
…lacrum std::net::bind using -1 for openbsd which in turn sets it to somaxconn. trusting platform's SOMAXCONN instead of hardcoding to 128 otherwise.
…mpiler-errors Rollup of 4 pull requests Successful merges: - rust-lang#119026 (std::net::bind using -1 for openbsd which in turn sets it to somaxconn.) - rust-lang#119094 (Add function ABI and type layout to StableMIR) - rust-lang#119102 (Add arm-none-eabi and armv7r-none-eabi platform-support documentation.) - rust-lang#119107 (subtype_predicate: remove unnecessary probe) Failed merges: - rust-lang#119141 (Add method to get instance instantiation arguments) r? `@ghost` `@rustbot` modify labels: rollup
This failed in a rollup: #119144 (comment) |
f5c3967
to
743eb65
Compare
@rustbot review |
@bors r+ |
…lacrum std::net::bind using -1 for openbsd which in turn sets it to somaxconn. trusting platform's SOMAXCONN instead of hardcoding to 128 otherwise.
…iaskrgr Rollup of 7 pull requests Successful merges: - rust-lang#117449 (Avoid silencing relevant follow-up errors) - rust-lang#117556 (Disallow reference to `static mut` and adding `static_mut_ref` lint) - rust-lang#118521 (Enable address sanitizer for MSVC targets using INFERASANLIBS linker flag) - rust-lang#118704 (Promote `riscv32{im|imafc}` targets to tier 2) - rust-lang#119026 (std::net::bind using -1 for openbsd which in turn sets it to somaxconn.) - rust-lang#119151 (Hide foreign `#[doc(hidden)]` paths in import suggestions) - rust-lang#119195 (Make named_asm_labels lint not trigger on unicode and trigger on format args) r? `@ghost` `@rustbot` modify labels: rollup
…lacrum std::net::bind using -1 for openbsd which in turn sets it to somaxconn. trusting platform's SOMAXCONN instead of hardcoding to 128 otherwise.
…mpiler-errors Rollup of 10 pull requests Successful merges: - rust-lang#118521 (Enable address sanitizer for MSVC targets using INFERASANLIBS linker flag) - rust-lang#119026 (std::net::bind using -1 for openbsd which in turn sets it to somaxconn.) - rust-lang#119195 (Make named_asm_labels lint not trigger on unicode and trigger on format args) - rust-lang#119204 (macro_rules: Less hacky heuristic for using `tt` metavariable spans) - rust-lang#119362 (Make `derive(Trait)` suggestion more accurate) - rust-lang#119397 (Recover parentheses in range patterns) - rust-lang#119414 (bootstrap: Move -Clto= setting from Rustc::run to rustc_cargo) - rust-lang#119417 (Uplift some miscellaneous coroutine-specific machinery into `check_closure`) - rust-lang#119540 (Don't synthesize host effect args inside trait object types) - rust-lang#119555 (Add codegen test for RVO on MaybeUninit) r? `@ghost` `@rustbot` modify labels: rollup
…mpiler-errors Rollup of 10 pull requests Successful merges: - rust-lang#118521 (Enable address sanitizer for MSVC targets using INFERASANLIBS linker flag) - rust-lang#119026 (std::net::bind using -1 for openbsd which in turn sets it to somaxconn.) - rust-lang#119195 (Make named_asm_labels lint not trigger on unicode and trigger on format args) - rust-lang#119204 (macro_rules: Less hacky heuristic for using `tt` metavariable spans) - rust-lang#119362 (Make `derive(Trait)` suggestion more accurate) - rust-lang#119397 (Recover parentheses in range patterns) - rust-lang#119414 (bootstrap: Move -Clto= setting from Rustc::run to rustc_cargo) - rust-lang#119417 (Uplift some miscellaneous coroutine-specific machinery into `check_closure`) - rust-lang#119540 (Don't synthesize host effect args inside trait object types) - rust-lang#119555 (Add codegen test for RVO on MaybeUninit) r? `@ghost` `@rustbot` modify labels: rollup
…iaskrgr Rollup of 10 pull requests Successful merges: - rust-lang#118521 (Enable address sanitizer for MSVC targets using INFERASANLIBS linker flag) - rust-lang#119026 (std::net::bind using -1 for openbsd which in turn sets it to somaxconn.) - rust-lang#119195 (Make named_asm_labels lint not trigger on unicode and trigger on format args) - rust-lang#119204 (macro_rules: Less hacky heuristic for using `tt` metavariable spans) - rust-lang#119362 (Make `derive(Trait)` suggestion more accurate) - rust-lang#119397 (Recover parentheses in range patterns) - rust-lang#119417 (Uplift some miscellaneous coroutine-specific machinery into `check_closure`) - rust-lang#119539 (Fix typos) - rust-lang#119540 (Don't synthesize host effect args inside trait object types) - rust-lang#119555 (Add codegen test for RVO on MaybeUninit) r? `@ghost` `@rustbot` modify labels: rollup
…iaskrgr Rollup of 10 pull requests Successful merges: - rust-lang#118521 (Enable address sanitizer for MSVC targets using INFERASANLIBS linker flag) - rust-lang#119026 (std::net::bind using -1 for openbsd which in turn sets it to somaxconn.) - rust-lang#119195 (Make named_asm_labels lint not trigger on unicode and trigger on format args) - rust-lang#119204 (macro_rules: Less hacky heuristic for using `tt` metavariable spans) - rust-lang#119362 (Make `derive(Trait)` suggestion more accurate) - rust-lang#119397 (Recover parentheses in range patterns) - rust-lang#119417 (Uplift some miscellaneous coroutine-specific machinery into `check_closure`) - rust-lang#119539 (Fix typos) - rust-lang#119540 (Don't synthesize host effect args inside trait object types) - rust-lang#119555 (Add codegen test for RVO on MaybeUninit) r? `@ghost` `@rustbot` modify labels: rollup
…iaskrgr Rollup of 10 pull requests Successful merges: - rust-lang#118521 (Enable address sanitizer for MSVC targets using INFERASANLIBS linker flag) - rust-lang#119026 (std::net::bind using -1 for openbsd which in turn sets it to somaxconn.) - rust-lang#119195 (Make named_asm_labels lint not trigger on unicode and trigger on format args) - rust-lang#119204 (macro_rules: Less hacky heuristic for using `tt` metavariable spans) - rust-lang#119362 (Make `derive(Trait)` suggestion more accurate) - rust-lang#119397 (Recover parentheses in range patterns) - rust-lang#119417 (Uplift some miscellaneous coroutine-specific machinery into `check_closure`) - rust-lang#119539 (Fix typos) - rust-lang#119540 (Don't synthesize host effect args inside trait object types) - rust-lang#119555 (Add codegen test for RVO on MaybeUninit) r? `@ghost` `@rustbot` modify labels: rollup
Rollup merge of rust-lang#119026 - devnexen:listener_upd, r=Mark-Simulacrum std::net::bind using -1 for openbsd which in turn sets it to somaxconn. trusting platform's SOMAXCONN instead of hardcoding to 128 otherwise.
Fix broken build for ESP IDF due to rust-lang#119026 `target_os = "espidf"` in `libc` lacks the `SOMAXCONN` constant, but that's probably irrelevant in this context, as `UnixListener` is not supported on ESP IDF - it being a single process "OS" only. The PR just re-uses the `128` constant so that the code builds. Trying to use the listener on ESP IDF will fail with `ENOSYS`, which is fine. *UPDATE* Might not fail with `ENOSYS` - need to test what error code would be returned, but that doesn`t change anything.
…iaskrgr Rollup of 8 pull requests Successful merges: - rust-lang#117744 (Add -Zuse-sync-unwind) - rust-lang#118649 (Make inductive cycles in coherence ambiguous always) - rust-lang#118979 (Use `assert_unsafe_precondition` for `char::from_u32_unchecked`) - rust-lang#119562 (Rename `pointer` field on `Pin`) - rust-lang#119619 (mir-opt and custom target fixes) - rust-lang#119632 (Fix broken build for ESP IDF due to rust-lang#119026) - rust-lang#119712 (Adding alignment to the cases to test for specific error messages.) - rust-lang#119734 (Miri subtree update) r? `@ghost` `@rustbot` modify labels: rollup
Fix broken build for ESP IDF due to rust-lang#119026 `target_os = "espidf"` in `libc` lacks the `SOMAXCONN` constant, but that's probably irrelevant in this context, as `UnixListener` is not supported on ESP IDF - it being a single process "OS" only. The PR just re-uses the `128` constant so that the code builds. Trying to use the listener on ESP IDF will fail with `ENOSYS`, which is fine. *UPDATE* Might not fail with `ENOSYS` - need to test what error code would be returned, but that doesn`t change anything.
…iaskrgr Rollup of 7 pull requests Successful merges: - rust-lang#117744 (Add -Zuse-sync-unwind) - rust-lang#118649 (Make inductive cycles in coherence ambiguous always) - rust-lang#118979 (Use `assert_unsafe_precondition` for `char::from_u32_unchecked`) - rust-lang#119619 (mir-opt and custom target fixes) - rust-lang#119632 (Fix broken build for ESP IDF due to rust-lang#119026) - rust-lang#119712 (Adding alignment to the cases to test for specific error messages.) - rust-lang#119734 (Miri subtree update) r? `@ghost` `@rustbot` modify labels: rollup
Rollup merge of rust-lang#119632 - ivmarkov:master, r=Nilstrieb,dtolnay Fix broken build for ESP IDF due to rust-lang#119026 `target_os = "espidf"` in `libc` lacks the `SOMAXCONN` constant, but that's probably irrelevant in this context, as `UnixListener` is not supported on ESP IDF - it being a single process "OS" only. The PR just re-uses the `128` constant so that the code builds. Trying to use the listener on ESP IDF will fail with `ENOSYS`, which is fine. *UPDATE* Might not fail with `ENOSYS` - need to test what error code would be returned, but that doesn`t change anything.
trusting platform's SOMAXCONN instead of hardcoding to 128 otherwise.