[{"data":1,"prerenderedAt":91},["ShallowReactive",2],{"term-s\u002Fstrangler-fig-pattern":3,"related-s\u002Fstrangler-fig-pattern":74},{"id":4,"title":5,"acronym":6,"body":7,"category":55,"description":56,"difficulty":57,"extension":58,"letter":59,"meta":60,"navigation":61,"path":62,"related":63,"seo":68,"sitemap":69,"stem":72,"subcategory":6,"__hash__":73},"terms\u002Fterms\u002Fs\u002Fstrangler-fig-pattern.md","Strangler Fig Pattern",null,{"type":8,"value":9,"toc":48},"minimark",[10,15,19,23,26,30,41,45],[11,12,14],"h2",{"id":13},"eli5-the-vibe-check","ELI5 — The Vibe Check",[16,17,18],"p",{},"Replacing a legacy system piece by piece instead of doing a risky big-bang rewrite. Named after the strangler fig tree that grows around another tree until it completely replaces it. Route traffic to the old system, build the new system alongside it, gradually redirect until the old one can be removed.",[11,20,22],{"id":21},"real-talk","Real Talk",[16,24,25],{},"The Strangler Fig Pattern is an incremental migration strategy where a new system is gradually built alongside a legacy system. An intermediary (usually a reverse proxy or router) directs traffic to either system based on which features have been migrated. It reduces risk compared to full rewrites.",[11,27,29],{"id":28},"show-me-the-code","Show Me The Code",[31,32,38],"pre",{"className":33,"code":35,"language":36,"meta":37},[34],"language-text","# Migration plan:\n# Phase 1: Proxy routes all traffic to legacy\n# Phase 2: \u002Fapi\u002Fusers → new service\n#          \u002Fapi\u002F* → legacy\n# Phase 3: \u002Fapi\u002Fusers, \u002Fapi\u002Forders → new\n#          \u002Fapi\u002F* → legacy\n# Phase 4: All traffic → new system\n# Phase 5: Decommission legacy 🎉\n","text","",[39,40,35],"code",{"__ignoreMap":37},[11,42,44],{"id":43},"when-youll-hear-this","When You'll Hear This",[16,46,47],{},"\"Use the strangler fig pattern — we can't afford a full rewrite.\" \u002F \"We're strangling the monolith one service at a time.\"",{"title":37,"searchDepth":49,"depth":49,"links":50},2,[51,52,53,54],{"id":13,"depth":49,"text":14},{"id":21,"depth":49,"text":22},{"id":28,"depth":49,"text":29},{"id":43,"depth":49,"text":44},"architecture","Replacing a legacy system piece by piece instead of doing a risky big-bang rewrite.","advanced","md","s",{},true,"\u002Fterms\u002Fs\u002Fstrangler-fig-pattern",[64,65,66,67],"Legacy Code","Brownfield","Microservice","Refactoring",{"title":5,"description":56},{"changefreq":70,"priority":71},"weekly",0.7,"terms\u002Fs\u002Fstrangler-fig-pattern","KdzrE3eSy_djTMoh8hI80szp7yy_dubctECNtBUY7l8",[75,80,83,88],{"title":65,"path":76,"acronym":6,"category":77,"difficulty":78,"description":79},"\u002Fterms\u002Fb\u002Fbrownfield","general","beginner","The opposite of greenfield — a project with existing code you have to work with (and work around). Most real-world development is brownfield.",{"title":64,"path":81,"acronym":6,"category":77,"difficulty":78,"description":82},"\u002Fterms\u002Fl\u002Flegacy-code","Old code that nobody wants to touch but everyone depends on.",{"title":66,"path":84,"acronym":6,"category":85,"difficulty":86,"description":87},"\u002Fterms\u002Fm\u002Fmicroservice","backend","intermediate","Microservices is an architecture where instead of one big app, you have many tiny apps that each do one thing.",{"title":67,"path":89,"acronym":6,"category":55,"difficulty":78,"description":90},"\u002Fterms\u002Fr\u002Frefactoring","Refactoring is improving the internal structure of code WITHOUT changing what it does from the outside.",1776518315759]