Glossary

Strangler Fig

The Strangler Fig migration pattern allows organizations to gradually replace legacy systems by wrapping new functionality around existing components. This approach minimizes disruption and reduces risks associated with large-scale migrations, making it ideal for teams looking to modernize their software incrementally. By focusing on a phased transition, teams can enhance user experiences while ensuring operational continuity.

Strangler Fig Migration Pattern

Definition

The Strangler Fig is a migration pattern where new functionality is developed to wrap around and gradually replace a legacy system. This approach allows organizations to incrementally migrate to new technologies while minimizing disruption to existing operations.

Etymology and Background

The term Strangler Fig is derived from a tropical tree species that grows around a host tree. Over time, the Strangler Fig will overshadow and ultimately replace the host tree, mirroring how this migration pattern works in software. The concept was popularized by Martin Fowler in his 2004 article on migration patterns, emphasizing the importance of a gradual transition to mitigate risks associated with complete system overhauls.

How This Concept Applies to Migrations

In software migrations, the Strangler Fig pattern is particularly useful for organizations looking to modernize legacy systems without the risks of a big-bang migration. Here's how it typically works:

  1. Identify a Legacy Component: Start by selecting a specific feature or module of the legacy system that requires an upgrade or replacement.
  2. Develop New Functionality: Create new functionality using modern technology that wraps around the legacy component. This new functionality handles requests and provides the same or enhanced capabilities.
  3. Gradual Transition: Gradually redirect traffic from the legacy system to the new functionality. This may involve routing specific requests to the new system while keeping others with the legacy system until all components are modernized.
  4. Complete Migration: Once all parts have been successfully transitioned, the legacy system can be fully decommissioned.

Examples in Different Migration Contexts

  • Web Applications: A company might start with a legacy monolithic application and build new microservices that replicate and enhance existing functionalities. Over time, the traffic would be routed from the monolith to the microservices until the old application is no longer in use.
  • Data Migration: In data migrations, the Strangler Fig pattern can be applied by creating new data storage solutions (e.g., moving from a traditional database to a cloud-based solution) that gradually take over data queries and storage from the legacy database.
  • SaaS Platforms: When migrating from on-premises software to a SaaS solution, organizations can create an integration layer that allows users to access features from both the legacy system and the SaaS platform concurrently, phasing out the legacy system over time.

Related Terms

  • Incremental Migration: This broader category encompasses any migration approach that takes place in stages or increments. The Strangler Fig is a specific example of incremental migration focused on wrapping and replacing functionality.
  • Legacy Modernization: A general term for the process of updating legacy systems, which may utilize the Strangler Fig pattern as one of its strategies.
  • Facade: A design pattern that provides a simplified interface to a more complex subsystem. While a facade may be used in conjunction with the Strangler Fig pattern, it does not necessarily imply the gradual replacement of the underlying system.

Common Misunderstandings to Avoid

  1. Not a Big-Bang Approach: The Strangler Fig pattern is often misinterpreted as a means for executing a big-bang migration. In reality, it promotes gradual change and risk reduction.
  2. Complete Replacement is Not Immediate: Some may think that the Strangler Fig requires immediate replacement of the legacy system. Instead, it focuses on a phased approach, allowing for continued operation during the transition.
  3. Requires New Development: The pattern involves new development, which can lead to confusion regarding its applicability for teams that may only want to upgrade existing systems without creating new features.

Practical Implications for Migration Teams

  • Risk Management: By utilizing the Strangler Fig pattern, teams can reduce the risks associated with migrations. The gradual transition allows for testing and validation of new functionality without impacting all users at once.
  • Flexibility: Teams can prioritize the most critical functionalities for migration, allowing for a more focused and efficient use of resources.
  • User Experience: Users can benefit from the new functionalities while still having access to the legacy system, easing the transition and maintaining productivity.
  • Cultural Shift: Adopting this pattern encourages a culture of continuous improvement and modernization within teams, aligning with agile methodologies and DevOps practices.

In conclusion, the Strangler Fig migration pattern is a powerful strategy that allows organizations to modernize their systems incrementally, reducing risks and improving user experiences throughout the transition process.

Category

Pattern

Related

  • incremental-migration
  • legacy-modernization
  • facade