views:

45

answers:

2

In most cases it is better to refactor than rewrite a full codebase. We have quite interesting situation. In our application business layer is pretty good. With unit tests, separation of concerns, etc. It does have some problems, but it can be refactored.

However UI layer is outdated. It is ASP.NET + some AJAX, but we want to migrate to pure AJAX application (ExtJS + REST). The application is quite large and has about 100 separate screens. What would you advise?

+1  A: 

I'm very familiar with your app Michael. I've also been in that exact situation twice in the past few years. There is ENORMOUS benefit in rewriting from scratch. You can't incrementally improve where you are. See this from Kathy Sierra.

Incremental vs Revolutionary

Bite the bullet and redesign from the ground up. You have an opportunity to blow away the competition, but it's never going to happen with incremental improvements.

Glen Lipka
Year, right. Netscape developers probably had the same drawing on their whiteboard
Konstantin Spirin
Love the graphic but I'm not sure the answer applies in every case. If the OP is using layered architecture, the UI/Presentation layer could be replaced without significant changes to the other layers.
TrueWill
No answer applies in every case. However, in my experience, a good rewrite in any SaaS application has enormous benefits and has to be done once every 2-5 years.
Glen Lipka
A: 

I don't see prospect of a truly helpful, generic, answer. Given complete freedom I'd agree with Glen and bit the bullet and go for the whole thing. However commercial realities may prevent that, if the application is big enough then the up front investment may just be too big. Then question is whether you can possibly get to where you need to be in increments.

For example, suppose that your app follows a common pattern, there are selection screens where the items to be worked on are picked by a user and they lead to data entry screens. Then, can you rework the selection screen with nice ajax stuff but retain the data entry screens. Address those on the next iteration.

djna