1
0
Fork 0
mirror of https://github.com/denoland/deno.git synced 2024-11-21 15:04:11 -05:00
denoland-deno/ext/net
Gianluca Oldani 873a5ce2ed
feat(ext/net): add reuseAddress option for UDP (#13849)
This commit adds a `reuseAddress` option for UDP sockets. When this
option is enabled, one can listen on an address even though it is
already being listened on from a different process or thread. The new
socket will steal the address from the existing socket.

On Windows and Linux this uses the `SO_REUSEADDR` option, while on other
Unixes this is done with `SO_REUSEPORT`.

This behavior aligns with what libuv does.

TCP sockets still unconditionally set the `SO_REUSEADDR` flag - this
behavior matches Node.js and Go. This PR does not change this behaviour.

Co-authored-by: Luca Casonato <hello@lcas.dev>
2022-10-24 09:05:07 +00:00
..
01_net.js feat(core): add Deno.core.writeAll(rid, chunk) (#16228) 2022-10-10 10:28:35 +02:00
02_tls.js perf(ops): Monomorphic sync op calls (#15337) 2022-08-11 15:56:56 +02:00
04_net_unstable.js feat(unstable): add ref/unref to Listener (#13961) 2022-03-23 12:04:20 +09:00
Cargo.toml chore: forward v1.26.2 to main (#16331) 2022-10-17 23:11:16 +02:00
io.rs chore: fix windows-only clippy errors (#16289) 2022-10-15 13:56:54 +00:00
lib.deno_net.d.ts fix(ext/net): return an error from startTls and serveHttp if the original connection is captured elsewhere (#16242) 2022-10-18 11:28:27 +09:00
lib.rs feat: Add requesting API name to permission prompt (#15936) 2022-09-27 22:36:33 +02:00
ops.rs feat(ext/net): add reuseAddress option for UDP (#13849) 2022-10-24 09:05:07 +00:00
ops_tls.rs fix(ext/net): return an error from startTls and serveHttp if the original connection is captured elsewhere (#16242) 2022-10-18 11:28:27 +09:00
ops_unix.rs fix(ext/net): don't remove sockets on unix listen (#16394) 2022-10-24 00:45:45 +02:00
README.md feat(core): streams (#12596) 2021-11-09 19:26:17 +01:00
resolve_addr.rs chore: update copyright to 2022 (#13306) 2022-01-07 22:09:52 -05:00

deno_net

This crate implements networking APIs.

This crate depends on following extensions:

  • "deno_web"
  • "deno_fetch"

Following ops are provided:

  • "op_net_accept"
  • "op_net_connect"
  • "op_net_listen"
  • "op_dgram_recv"
  • "op_dgram_send"
  • "op_dns_resolve"
  • "op_tls_start"
  • "op_tls_connect"
  • "op_tls_listen"
  • "op_tls_accept"
  • "op_tls_handshake"