Originally legacy code meant code 'inherited' from authors or from a previous program/system version. Since Michael Feathers published his "Working Effectively with Legacy Code" book, new definition came to be, where code without tests is legacy code.

learn more… | top users | synonyms

1
vote
1answer
101 views

Help Improve DB model/strategy, for use in refactoring SQL-ridden legacy code

Question: Which design pattern do I use to help me refactor legacy SQL code into separate classes? Goal Bring in concepts of data separation and database separation and also latest modern ...
2
votes
3answers
166 views

Refactoring web pages with user controls

Is it good design to use many user controls to help refactor a web application? In my case, it's a VB.NET Webforms ASP.NET website. All our pages are organized into sections that, while related and ...
2
votes
4answers
217 views

How to refactor a myriad of similar classes

I'm faced with similar classes A1, A2, ..., A100. Believe it or not but yeah, there are roughly hundred classes that almost look the same. None of these classes are unit tested (of course ;-) ). Each ...
1
vote
3answers
122 views

Can I refactor “safely” without specs? [duplicate]

I have inherited a legacy web application many years which: Does not make use of Object Oriented principles, even though the language would permit it Has no unit tests, nor any sort of test suite, ...
27
votes
4answers
3k views

What is the origin of the negative term “legacy code”

Everyone talks about legacy code in software development and I have heard the term over the last ten years used to paint any codebase as being bad. Where did this term, which has such powerful ...
4
votes
4answers
354 views

How to avoid excessive method overloading?

We have quite a lot of places in the source code of our application , where one class has many methods with same names and different parameters. Those methods always have all the parameters of a ...
8
votes
5answers
832 views

Why write tests for code that I will refactor?

I am refactoring a huge legacy code class. Refactoring (I presume) advocates this: write tests for the legacy class refactor the heck out of the class Problem: once I refactor the class, my ...
23
votes
2answers
1k views

Is there an anti pattern for historically grown software? [closed]

Is there an anti pattern that describes a historically grown software system where multiple developers just added new features to the system but no one really kept an eye on the overall architecture ...
62
votes
10answers
4k views

Does it make sense to write tests for legacy code when there is no time for a complete refactoring?

I usually try to follow the advice of the book Working Effectively with Legacy Code. I break dependencies, move parts of the code to @VisibleForTesting public static methods and to new classes to make ...
0
votes
0answers
386 views

How to integrate unit testing process into legacy software development process? [duplicate]

I'd like you to share your insights of how have you successfully turned the direction of rotting legacy code base to modular application design where it's easy and useful to add unit tests? What I'm ...
3
votes
3answers
453 views

Effective way to estimate dead code removal?

I've been working in an application with about 100k LOCs and basically We have been reworking features to comply with a new architecture based on a new technology stack. This work is almost finished ...
2
votes
1answer
249 views

How to find classes that use certain DB tables

Problem: I'm asked to prepare a document where all our DB tables are listed and I'm supposed to list all Controllers that uses these DB tables for read and another list for Controllers that do write ...
13
votes
5answers
952 views

Does dealing with legacy code help one evolve as a programmer?

I'm a Java developer with a bit more than a year of experience which places me somewhere above a junior, but not among mid-level developers yet. Recently I was offered a long-term project which is ...
6
votes
4answers
551 views

I have 200k lines of poorly designed code, will units tests or integration tests be more valuable? [duplicate]

I've inherited a lot of poorly designed code; the code has no tests. I am putting tests in place before I attempt a major refactor, but I have run into a problem with my unit tests. The problem is, I ...
6
votes
6answers
567 views

Painfully Stupid Method Names in Legacy Code: Fix or Leave as Warning? [duplicate]

For this case let's assume something like... "removedNonPriceChangingConfermations" that is in no way relating to things that happened in the past tense, nor does it return a list of removed items ...
2
votes
0answers
42 views

How to document legacy code (shell scripts)? [duplicate]

I got involved into a project where we are taking over a bunch of legacy code. Code is basically shell scripts and PL/SQL packages/procedures/functions. There is no documentation how the code works ...
1
vote
4answers
195 views

How Much Of A (Broken) Legacy Framework To Keep [duplicate]

I've inherited a hosted system (system "A") which can be used to manage products, inventory, and orders, and can send those products to various third-parties. Quite simply, system "A" doesn't work. ...
13
votes
5answers
992 views

What to do as a Dev when for years their team has lacked product innovation, not used project mgmt methodologies, and kept bad Software Dev practices? [closed]

I am interested in knowing how to deal with a current software development process that has not been changed for years and will eventually lead to product and team failure. Yes, probably the easier ...
2
votes
1answer
632 views

How much poor quality code should a junior put up with? [duplicate]

I am a junior developer who has been working at a new job for a few weeks. I am working with a large framework for scientific desktop software, adding pieces of functionality. While there are general ...
276
votes
20answers
64k views

How should I behave as a developer in a project that's headed for failure?

I am a developer in a 5-member team and I believe our project is headed for disaster. I'll describe why in a moment, but my question is: how should I behave? The deadline is in 1.5 months, and I ...
4
votes
4answers
808 views

What can I do to maintain respect for a poorly written codebase? [duplicate]

In my job I have to maintain a poorly written codebase which is both hard to understand, has tons of comments that are just plain wrong, has a bunch of weird decisionmaking going on in it and a whole ...
4
votes
5answers
402 views

Keep coding the wrong way to remain consistent? [duplicate]

Possible Duplicate: Code maintenance: keeping a bad pattern when extending new code for being consistent, or not? To keep things simple let's say I am responsible for maintaining two ...
5
votes
4answers
257 views

Version control implementation advice on legacy websites?

Assuming no experience with version control systems, just local to live web development. I've been dropped in on a few legacy website projects, and want an easier and more robust way to be able to ...
15
votes
11answers
5k views

How to make Classic ASP interesting if you are stuck with it?

I used to work on a really small outsourcing company (4 programmers and the boss), then when the stress and the frequent long shifts made the situation unbearable I made the switch to a better paid ...