Beagle SCM
JS-114: dgram._send resolves the address via getaddrinfo on every datagram
Proposed by the 2026-07-07 jab multi-agent review; confirmed by both skeptic verifiers. Every UDP packet pays a getaddrinfo/freeaddrinfo round-trip (potentially NSS/DNS) even for literal addresses — the JS default is "127.0.0.1".
Input
Context
getaddrinfo(host, port, &hints, &res) per send call, no AINUMERICHOST hint, no cache (jab net.cpp:196).
- A high-rate UDP sender (telemetry/heartbeat) turns one sendto into getaddrinfo+sendto+freeaddrinfo per packet.
- Node has the same shape for unconnected sockets — this is an improvement, not a regression.
Goals
- Try AI_NUMERICHOST first; cache the last (host,port)->sockaddr in the binding.
Constraints
- Low priority; behavior for hostnames (re-resolution) should not silently pin a stale address forever — cache literals only, or bound the cache.
WIP
TODOs