Published Sep 3, 2019

Episode 55: Refactoring Pt. 2

Delve into the complexities of software engineering with insights from Martin Fowler on large-scale refactorings, including strategies for maintaining API backward compatibility and managing database schema changes. Discover practical solutions and cultural considerations for successful implementation in ever-evolving systems.
Episode Highlights
Software Engineering Radio - the podcast for professional software developers logo

Popular Clips

Episode Highlights

  • Compatibility

    Maintaining backward compatibility while evolving APIs is a complex challenge. highlights the difficulties faced by projects like the JDK and Eclipse, where ensuring binary compatibility across versions is crucial. He explains that techniques such as using interfaces and abstract implementations can help manage these changes without breaking clients 1. However, this approach can lead to an ever-growing system, making it necessary to occasionally break compatibility to simplify and improve the API 1.

    You always think of okay, I need to be backward compatible all the time and I want to change and I want to improve my API, but I need to add API instead of changing it or instead of just making it better.

    ---

    Balancing these strategies with manageable release cycles is essential to avoid overwhelming developers and users 2.

       

    Change Management

    Managing API evolution involves careful planning, especially when unforeseen client interactions are involved. discusses the use of scripts for data migration and refactoring, which can simplify transitions between schema versions 3. He also mentions scripting refactorings within the Eclipse IDE, allowing clients to automatically adapt to changes in the API 4.

    You can script that refactoring and you can publish the script, the refactoring script together with your new version of the API.

    ---

    These strategies are particularly useful for large databases where manual migration is impractical, but they require careful implementation to avoid complicating the software further 3.

Related Episodes