Working Effectively with Legacy Code

Working Effectively with Legacy Code

by
4.19 of 5 stars 4.19  ·  rating details  ·  565 ratings  ·  45 reviews
Get more out of your legacy systems, more performance, functionality, reliability, and manageability.Is your code easy to change? Can you get nearly instantaneous feedback when you do change it? Do you understand it? If the answer to any of these questions is no, you have legacy code, and it is draining time and money away from your development efforts.

In this book, Michae...more
Paperback, 456 pages
Published September 1st 2004 by Prentice Hall
more details... edit details

Friend Reviews

To see what your friends thought of this book, please sign up.
The  C Programming Language by Brian W. KernighanThe Pragmatic Programmer by Andrew HuntDesign Patterns by Erich GammaStructure and Interpretation of Computer Programs by Harold AbelsonRefactoring by Martin Fowler
Essential Programming Books
21st out of 86 books — 152 voters
The Pragmatic Programmer by Andrew HuntCode Complete by Steve McConnellClean Code by Robert C. MartinRefactoring by Martin FowlerWorking Effectively with Legacy Code by Michael Feathers
Software Craftsmanship
5th out of 18 books — 36 voters


More lists with this book...

Community Reviews

(showing 1-30 of 1,610)
filter  |  sort: default (?)  |  rating details
Erika RS
We wise programmers know that code should be written to minimize dependencies, inject those that are necessary, use interfaces, be tested from the start, etc. etc., and we always write our new code like that (right?), but our good habits and wisdom don’t matter when working with legacy code. You don’t have the option of going back in time and smacking some sense into the original author (who may have been your younger, more foolish self).

Given that we have to deal with legacy code, how can it be...more
Steven Grimm
I've found this book helpful in framing my thinking about testing a large code base.

It bears some similarity to "Design Patterns," both in its structure and in that for an experienced developer it's light on the "I never knew I could do that," and heavy on the, "I've made that kind of change before but until now hadn't thought of it as a distinct concept that could be reasoned about in isolation."

So for me, the value was less in teaching me new techniques and more in giving me a better way to or...more
Pascal Mestdach
Michael Feathers defines legacy code as “Code without tests”. Based on that definition, do you work on legacy code? Probably almost every programmer gets confronted with parts of code not covered by Unit Tests. Do you want better techniques to work with code that doesn’t have tests?

If you take up the challenge of reading and applying this book, you’ll learn several specific techniques that you can employ to take this code, make the absolute minimum number of modifications to get the code testabl...more
Karol Stosiek
This review has been hidden because it contains spoilers. To view it, click here.
Ash Moran
I've heard this called "genius" and it is. Legacy code is defined as untested code. Changing it involves various strategies to safely and incrementally get tests in place. The "seam" model of thinking, where you identify points you can influence behaviour without changing the code, is extremely powerful. Feathers gives several types of seam, and many techniques for exploiting them.

The main value of Working Effectively with Legacy Code is low risk ways to deal with untested code. There's a large...more
Marshall
This book should be considered a required companion book to Martin Fowler's Refactoring. Refactoring is about slowly and progressively turning ugly code into well-designed code. I'd read Refactoring, and tried its techniques, but I just couldn't figure out how to make it work for my purposes. I knew refactoring was based on having a robust suite of regression tests. Let's face it, most ugly code lacks such a suite of tests. If you want to refactor something and you don't have a test, you need to...more
Todd
This is the book that got me back to thinking seriously about improving the way I write software. I read it because I saw the title at a point in time when I was working with a lot of legacy code and feeling the pain. For me, this was the book that had me constantly nodding along and feeling like the author must have actually been someone on my project team in disguise. Maybe it doesn't read the same if you're not in the trench trying to dig out when you read it. (But, secretly, I think we're al...more
Alex Satrapa
An awesome book which every programmer (or manager responsible for programmers) should read. Michael C. Feathers covers techniques and attitudes that will help you maintain code that has been left for you by the previous incumbent. Some of this advice is presented as "recipes" ("Ch 22: I need to change a monster method and I can't write tests for it") while other advice is presented as counsel ("Ch 24: We feel overwhelmed. It isn't going to get any better."

I highly recommend reading this book in...more
David Workman
This is a must read for any person involved in development on a legacy system.

The book is quite a dense collection of interwoven refactoring patterns and techniques for improving the quality of legacy code. As the author quite clearly states at the start that he considers legacy code to be 'code without tests', most of these are actually techniques for getting untested code into automated test harnesses to allow future development to proceed with that safety net in place.

Some of the techniques a...more
Andrew
Working with legacy code on the face of it looks and feels less exciting than working on greenfield projects. The truth is that legacy is the place where you get to hone your craft and sharpen your tools.
This book contains the foremost example of tools you didn't know you would need but maybe more importantly, it shows you where and how to use the tools you already have to make the world a better place and yourself a better developer.
James Kirkbride
One of the most pertinent and useful books on programming I've ever read. Maintaining legacy code is a large part of my job and the techniques described here make it much easier and safer to make necessary changes. Getting classes into test harnesses that were previously uncovered is a rewarding experience. I highly recommend this book to anyone who has to refactor code on a regular basis.
Mark
This was the most helpful testing book I've ever read. Most books assume that you'll be starting with a greenfield project and can stay on the straight-and-narrow path of TDD all the way to glory: as most devs know, you're usually coming to a project that sorta-kinda-works-in-production and usually has inadequate or no automated testing. This is terrifying: you know change needs to happen, but you have no certainty about how to make it.

Feathers lays out a taxonomy of strategies for grappling wit...more
Steve
This book is a must read for any developer. It does not even tell you how to deal with legacy code, it also tell you how to avoid such things in the first place.

The book itself reads a little dry and I am sure I will not remember all the names of the different techniques described in it. But I think this is normal due to the dry stuff which the book is about. The author uses mainly Java or C/C++ examples, even as C# developer they are simple to understand.

When reading the book I got a moment wh...more
Matt
This book may be a little dated from the code and tools aspect, but the methods are just as valid today as they ever were. Prior to this book I had refactored plenty of code successfully, but not without challenges. I think the approaches outlined here will help me quite a bit in my future efforts.
Jess Robinson
I love this book. Every organisation has code that has evolved faster than it should have, with missing tests, odd corners and even weird constructs that appear to make no sense. This book gives you a solid set of ways to improve, understand and make testable, an existing code base
Ceasar Bautista
Intentional or not, the majority of this book is fluff, either in the form of verbose and pointless prose, or unsubstantiated advice. Software engineering ought to be scientific, not religious. Nevertheless, there is some truth to be gleaned, but overall not recommended.
Avdi
This is without question one of the essential books on my software development bookshelf. The dirty secret of software is that 80% or more if it is hacking your way through thick tangles of legacy code. This book is your survival guide in that jungle.
Stefan
I just re-read this great Michael's book after few years of working solely on a quite legacy code base.
I must admit that I still won't be able to list most of techniques applied here, all related to getting legacy code under unit tests.
However, most of refactoring techniques are more obvious to me today that after the first read.

Hence the conclusion that Michael's 'Working Effectively with Legacy Code' isn't for a junior / novice coder, but for someone who already hit enough walls to feel the pa...more
Hristo Deshev
One of the books that makes you a better programmer. I can't count the number of messes I have fixed using things I learned from this book. Thinking of it, I should probably read it again.
Jesper
Absolutely essential for everyone working with software. At some point in your life you will meet legacy code, and the knowledge from this book will help you stay, somewhat, sane.
Raghu Hudli
Must read for people working on refactoring existing code - well, who doesn't? An equally great companion book is Martin Fowler's book on
James
As someone who works with a lot of legacy code this book is indispensable. Probably one of my most used technology books.
Collin Rogowski
Great, practical advice on how to reafctor and enhance legacy code bases. Must read for every software developer.
Tom
This is a great book and an absolute must-read for all software developers. Feather's definition of legacy code is code without unit tests, and the book provides a plethora of techniques for adding tests to your code. I will definitely be referring back to this book time and time again.
Jeffswensen
Fantastic. Provides clear, specific approaches to working with old, intimidating spaghetti mess.
Michael Richardson
A must read for anything seriously thinking about working on programs longer than a page.
Chris Hulan
Excellent guide to getting a handle on code gone wild
Xavier Shay
Solid content but I can't list anything new I learned. Reinforced the notion that coupling/dependencies are evil.
Ben Rand
Great book. A must have on any programmer's shelf. I put something I read in the first 40 pages into play the very next day in my big project at work. Wish I had read this a long time ago.
« previous 1 3 4 5 6 7 8 9 53 54 next »
There are no discussion topics on this book yet. Be the first to start one »
Working Effectively with Legacy Code (Robert C. Martin Series)
Effektivnaya rabota s unasledovannym kodom

Goodreads is hiring!

If you like books and love to build cool products, we may be looking for you.
Learn more »
Beautiful Code: Leading Programmers Explain How They Think

Share This Book

Your website
“Code without tests is bad code. It doesn't matter how well written it is; it doesn't matter how pretty or object-oriented or well-encapsulated it is. With tests, we can change the behavior of our code quickly and verifiably. Without them, we really don't know if our code is getting better or worse.” 2 people liked it
“Programming is the art of doing one thing at a time” 2 people liked it
More quotes…