Next time someone considers rewriting an app into (insert currently fashionable language here), ask yourself whether a three year long timeout will serve anyone's interests.
— James Robertson, The Wages of Pointless Rewrites
Three years to migrate a working application from mod_perl to PHP and (reportedly) Erlang? I could write my own virtual machine from scratch if funded full-time for three years. (Yes, I'm aware of certain ironies about rewriting a virtual machine over the period of seven years and counting, but I can count our paying customers on zero hands.)
However, rumor has it people (internally) have tried and failed to replace it in the past. Also, it's an internal facing app, so perhaps there's more slack there.
Hi, chromatic. I work on Delicious, and I've been with the site since before Yahoo! bought it.
Delicious was not merely migrated. It was redesigned and rewritten from the database up. Several months of development were spent in design and QA (we were in limited beta since September). The additional forethought and care were warranted since a lot of people rely on us every day.
Delicious was originally designed for a relatively small number of people. It has been extended, patched, optimized, sharded and cached over time to serve five million users and hundreds of millions of bookmarks. It was always just barely ahead of the growth curve. In the end, it was too tightly coupled to its small-scale roots to keep up with our accelerating growth.
The languages we chose are the right tools for their respective jobs. For example, the back end is mainly C++ (which might actually be fashionable compared to Smalltalk). There's even a fair amount of Perl to keep the CPUs and language advocates warm.
It's a longer story that that, of course. We'll be posting more detail to our blog soon.
Re:FSVO "Right"
jrockway on 2008-08-06T20:49:32
Why did you throw away everything, though? You could have fixed the architecture without changing languages.Re:FSVO "Right"
dngor on 2008-08-07T07:30:57
Why did you throw away everything, though? You could have fixed the architecture without changing languages.
Oh, sure. Everything is just a Simple Matter Of Programming.
:) PHP on the front end was an administrative requirement. Switching the front end to PHP did not unduly extend our development time. I'm free to tell you this because our founder has already said as much in the surprisingly balanced reddit thread in response to James' article.
We considered simply bolting a PHP front end onto the original site, but it was not practical. The original user interface was tightly coupled to the site's business logic, and we estimated that the effort to extricate them would be on par with redesigning them. Also, putting new lipstick on the same old pig would not have improved scalability. We still would have needed to rewrite the back end.
Among other reasons, we chose C++ for the new back end because runtime performance was an overwhelming design goal. Perhaps a really good Perl implementation of the site could have changed people's minds, but we didn't have one to point at.
Unfortunately I need to be writing this up for our blog rather than in bits and pieces around the web. Any further answers will have to wait, but questions are certainly welcome.
Re:FSVO "Right"
chromatic on 2008-08-06T21:56:30
The languages we chose are the right tools for their respective jobs.
I don't know your particular constraints, and I'm happy to accept that, but a three year rewrite with an eleven month beta period seems troubled -- unless that was the schedule from the beginning. I very much look forward to a retrospective.