Kartik Rajput·Nov 6The Header Injection Vulnerability Hiding in Most Go Email CodeSomewhere in most Go services that send email, there’s a line that looks like this:
Kartik Rajput·Nov 6Why Your Concurrent Go Mailer Needs to Deep-Copy Every EmailHere’s a bug that passes every single-threaded test you’ll write and shows up only under real concurrent load:
Kartik Rajput·Oct 16Why I Built Another WebSocket Library for Go (and Why It Might Be the Last One You Need)“Another WebSocket library” is a fair thing to be skeptical of. Go already has several good ones, some of them excellent at exactly what…
Kartik Rajput·Sep 11Building Backpressure into a Go WebSocket ServerEvery WebSocket server eventually gets a slow client — bad wifi, a suspended mobile app, a browser tab that stopped running its event loop…
Kartik Rajput·Sep 11How to Handle 10,000 WebSocket Connections in Go“Can it handle 10,000 connections?” gets asked about every realtime service, usually as a stand-in for “is this production-grade.” It’s the…
Kartik Rajput·Sep 11Scaling WebSockets Across Multiple Go Servers with RedisA stateless HTTP handler scales the boring way: put a load balancer in front, add replicas, done — any instance can answer any request…
Kartik Rajput·Sep 11Graceful WebSocket Shutdown in GoArticle one in this series showed the two-phase pattern — Drain then Shutdown - as the answer to "what happens to 8,000 open connections…
Kartik Rajput·Sep 11Building a Production-Grade WebSocket Server in GoEvery Go WebSocket server starts the same way. You pull in gorilla/websocket or nhooyr.io/websocket, write an Upgrade call, spin up a…