Book Author: Michael Feathers
Before the book, Working Effectively With Legacy Code, the words “working effectively” and “legacy code” could not be more opposite from each other in my mind. It would be nothing more than a useless, unachievable statement from an armchair software developer. Everyone knows that you don’t work effectively with legacy code! You hack it, you kludge it, you desperately make whatever hackneyed improvements you can to meet the insane requirements your sales team has promised to your clients – but you certainly don’t work effectively with it, and you pray every time your cursor flashes on that IDE screen that nothing crumbles before your eyes.
Michael Feathers, however, has shown me that not only is it possible, it’s doable. Working Effectively With Legacy Code is a rare book, one that hits every single point dead on. Feathers assumes that many of the systems his readers are working on are, simply put, “legacy code”- code that is not easily tested, changed, or understood, according to him. The book purports to help software developers stuck with these sorts of clunky systems, and remake the systems into something more in line with current development practices and ease.
Simply put: Michael Feathers delivers. While I would expect a book of this scope to be boring and unimaginably theoretical, Feathers presents almost exactly the opposite: his book is entertaining and practical. A book with this amount of code should be almost unreadable, and yet Feathers didn’t lose my attention at any point in the book. He seems to understand perfectly the frustrations and obstacles that you face when working with legacy code, and he is patient and helpful throughout the entirety of the book.
In that same spirit: his code is scarily real. Often, these sorts of books use code examples that are never encountered in the wild and tailored to make the author’s point in an almost brainless way. His examples, however, made me wonder if he took them straight from legacy code he’d really worked on: from unintelligible to untestable, Feathers provides a wealth of examples that look like problems you will face (or are already facing). If you’re fretting at some of them as head-scratchers, rest easy that I did as well- Feathers will help solve your problems as efficiently as mine, I assure you!
The book is essentially a very organized, patient walkthrough that deals with how to migrate legacy code to a testable, mutable modern environment. From C to Java, Feathers provides examples of real-world scenarios in many different languages (procedural to OOP, spaghetti code plastered all over) and shows how to take baby steps to refactor them without breaking anything (including your soul). By the end of the book, you’ll be well on your way to having a code base that has broken out of the horrible cycle of debugging and maintenance that has most likely plagued it since its inception.
In closing: I cannot recommend Working Effectively With Legacy Code highly enough! Michael Feathers is a consummate pro who clearly has been through the gauntlet of refactoring legacy code before. His examples, ideas, and suggestions are extraordinarily insightful. The next time you’re sitting at an IDE screen, staring at an ugly system and softly weeping inside, head over to your bookstore and grab a copy of this; it may save a whole lot of weeping in your future!Our Rating: