Network Fundamentals with Node.js

7 topics in this chapter

1

TCP/IP Stack and OS Networking Primitives

How bytes leave a Node process through libuv, OS sockets, addresses, ports, routing, link-layer resolution, and packet boundaries.

#nodejs#networking#tcp-ip#sockets#libuv

42 min read

2

DNS Resolution End to End

How Node turns hostnames into addresses through the OS resolver, c-ares, recursive DNS, records, TTLs, caches, and address-family ordering.

#nodejs#networking#dns#resolver#c-ares

41 min read

3

TCP Connections, Flow Control, and Failure Modes

How TCP connections move through handshake, ordered delivery, flow control, shutdown, and the error codes Node reports when the transport breaks.

#nodejs#networking#tcp#sockets#flow-control

43 min read

4

Sockets and the net Module

How Node's net.Server and net.Socket wrap OS socket state, libuv TCP handles, connection events, writes, shutdown, timeouts, and local IPC endpoints.

#nodejs#networking#tcp#sockets#net

41 min read

5

UDP and the dgram Module

How UDP datagrams move through Node's dgram API, libuv UDP handles, OS socket state, broadcast, multicast, connected UDP, and failure paths.

#nodejs#networking#udp#dgram#sockets

43 min read

6

Socket Options, Keep-Alive, Nagle, and Backlog

How Node exposes socket options for binding, keep-alive probes, Nagle behavior, buffer sizing, backlog pressure, and IPv4/IPv6 bind behavior.

#nodejs#networking#tcp#sockets#libuv

39 min read

7

Full Request Path from Client to Process

Trace a Node connection from hostname lookup through routing, TCP connect, accept queues, libuv readiness, JavaScript callbacks, and the boundary before HTTP.

#nodejs#networking#tcp#sockets#libuv

43 min read