[{"data":1,"prerenderedAt":81},["ShallowReactive",2],{"term-c\u002Fconnection-draining":3,"related-c\u002Fconnection-draining":60},{"id":4,"title":5,"acronym":6,"body":7,"category":40,"description":41,"difficulty":42,"extension":43,"letter":44,"meta":45,"navigation":46,"path":47,"related":48,"seo":54,"sitemap":55,"stem":58,"subcategory":6,"__hash__":59},"terms\u002Fterms\u002Fc\u002Fconnection-draining.md","Connection Draining",null,{"type":8,"value":9,"toc":33},"minimark",[10,15,19,23,26,30],[11,12,14],"h2",{"id":13},"eli5-the-vibe-check","ELI5 - The Vibe Check",[16,17,18],"p",{},"When you're taking a server out of rotation, whether for deployment or scaling down, you don't want to just yank it away mid-request and cut people off. Connection draining tells the load balancer to stop sending it new traffic while letting its existing in-flight requests finish naturally, up to a time limit. It's the difference between slamming a store's door in a customer's face and just flipping the sign to closed while finishing up whoever's already at the register.",[11,20,22],{"id":21},"real-talk","Real Talk",[16,24,25],{},"Connection draining (also called deregistration delay) is a load balancer feature that stops routing new requests to a target being removed from service while allowing existing in-flight connections to complete, up to a configured timeout, before forcibly terminating them. It's essential for zero-downtime deployments and autoscaling scale-in events, preventing dropped requests when instances are terminated, and works alongside readiness and health checks to coordinate safe traffic shifts.",[11,27,29],{"id":28},"when-youll-hear-this","When You'll Hear This",[16,31,32],{},"\"We set the draining timeout to 30 seconds so in-flight uploads have time to finish.\" \u002F \"Without connection draining, every deploy was dropping a handful of live requests.\"",{"title":34,"searchDepth":35,"depth":35,"links":36},"",2,[37,38,39],{"id":13,"depth":35,"text":14},{"id":21,"depth":35,"text":22},{"id":28,"depth":35,"text":29},"networking","When you're taking a server out of rotation, whether for deployment or scaling down, you don't want to just yank it away mid-request and cut people off.","intermediate","md","c",{},true,"\u002Fterms\u002Fc\u002Fconnection-draining",[49,50,51,52,53],"Load Balancer","Blue-Green Deployment","Circuit Breaker","Auto Scaling","Load Shedding",{"title":5,"description":41},{"changefreq":56,"priority":57},"weekly",0.7,"terms\u002Fc\u002Fconnection-draining","WUr6oeIbS1W6rcQcRvu5WW6UC4IXaeutiIl1lvWIYZ8",[61,65,69,73,76],{"title":52,"path":62,"acronym":6,"category":63,"difficulty":42,"description":64},"\u002Fterms\u002Fa\u002Fauto-scaling","cloud","Auto scaling is when the cloud automatically adds more servers when traffic spikes and removes them when it drops, so you're not paying for idle machines a...",{"title":50,"path":66,"acronym":6,"category":67,"difficulty":42,"description":68},"\u002Fterms\u002Fb\u002Fblue-green-deployment","cicd","Blue-green deployment means running two identical production environments — Blue (current) and Green (new).",{"title":51,"path":70,"acronym":6,"category":71,"difficulty":42,"description":72},"\u002Fterms\u002Fc\u002Fcircuit-breaker","architecture","Circuit Breaker is like the electrical circuit breaker in your house.",{"title":49,"path":74,"acronym":6,"category":40,"difficulty":42,"description":75},"\u002Fterms\u002Fl\u002Fload-balancer","A load balancer is like a traffic cop for servers.",{"title":53,"path":77,"acronym":6,"category":78,"difficulty":79,"description":80},"\u002Fterms\u002Fl\u002Fload-shedding","backend","advanced","Load shedding is intentionally dropping some requests when your server is overwhelmed so it can keep serving the rest.",1792528073472]