recall

← recall

strangler fig pattern

Instead of a big-bang rewrite, route specific endpoints/features from the legacy system to a new system, one at a time. The legacy system 'strangles' away as the new one takes over each route. Eventually the legacy is empty and can be removed. Trades calendar time for risk.

Instead of a big-bang rewrite, route specific endpoints/features from the legacy system to a new system, one at a time. The legacy system 'strangles' away as the new one takes over each route. Eventually the legacy is empty and can be removed. Trades calendar time for risk.

symptoms

  • need to replace a legacy system without a freeze period
  • big rewrite keeps slipping or failing
  • features added to legacy faster than rewrite progresses

causes

  • monolithic legacy with no clear seams
  • no traffic-routing layer to redirect piecemeal

fixes

  • put a router/proxy in front of legacy
  • new code handles one route at a time
  • measure progress as % of traffic on new system

you might say

  • strangler fig
  • strangler
  • incrementally migrate

related

aliases: strangler, strangler pattern

topics: architecture, refactoring

references: