Refactoring Everything, Retrospective

by chromatic

This 30-day project explores the refactoring of a legacy system. The Everything Engine is an aging software project that powers Perl Monks, Everything 2, and a few other websites. It suffers from poor design and maintainability.

Here's what I learned about programming, refactoring, and 30-day projects during this series.


2006-06-23 13:38:31
Well we ever get access to svn repository with your changes?
2006-06-23 13:47:54
Hm, I thought I'd published the link earlier. It's at SourceForge, under the name "everydevel":
2006-06-23 15:13:02
As a closet fan of eCore it's really cool seeing the ol' lamp get some attention. I'm glad you enjoyed it too and hopefully this will lead some more contruibutions/authors to ecore.

I admit as a noncoder, I pretty much skimmed the Greek sections of your posts and was just content seeing that it's being worked on. A month ago I publically wondered "is anyone really using this thing still", good to see people are!

jeffm on everydevel

Aristotle Pagaltzis
2006-06-23 22:06:11
Thanks for publishing. :)

I was hoping there'd be more focus on the system itself and was a bit disappointed that the tests took up so much time. It's not just a matter of tedium and boredom, it's that any rearrangements in the main code were buried under a sandpile of test suite changes. Maybe that would have been OK if the rearrangements had been meatier; though if they could have been, then the system would have been in a better shape to begin with.

2006-06-23 23:32:58
You're right, Aristotle. It would have been nice if I could have cleaned up the tests first, but I didn't remember how much work they needed. It was also difficult to justify working on the system without either needing to use it myself (I don't, at the moment) or writing about it... so it may not be a good example of what a 30 Day Project could be.
2006-06-24 06:23:12
Just wanted to thanks for an interesting set of posts, I've dipped in and out of the series over the last month or so and found it an intriguing exercise. I think you're right when you said it bogged down when documenting the refactoring of the test cases although it had to be done to be true to your original goals. I've learned some interesting tips with regards to Test::MockObject and as a result this should encourage the use of a more test driven development approach in the future. I'm not sure what other large, well-known open source Perl systems there are out there but I'd be interested to see a similar exercise on something which most people would recognise regardless of whether they were a Perl developer or not - any ideas ?
Jim Keenan
2006-07-03 06:51:14
I remember stumbling across early installments in this series in April. But, notwithstanding seeing you and hearing you speak at YAPC::NA in Chicago, I forgot about the series until I stumbled across the Retrospective entry yesterday. Why? Because the blog format meant that you couldn't include hyperlinks to entries yet to be written and it didn't include links to entries already written. Even fiddling around the location bar didn't easily work because O'Reilly primarily organizes its blogs by year and month -- and only thereafter by entry number.

So, would it be possible to refactor the blog pages so that if I now go to entry #2, it includes a link back to entry #1 and a link forward to #3? This would make the series more accessible and useful going forward.

Notwithstanding these technical problems, I think the approach is a good one and was struck by its similarity to the approach I took in my own talk at YAPC on taking over maintenance of CPAN modules.

2006-08-08 19:41:35
My biggest success overall was discovering a new technique that combines Test::MockObject::Extends with Test::Class. I find it so useful that I do it by default now.

Can you provide a link to read more about this?

2006-08-09 11:13:34

Perrin, see Mocks in Your Test Fixtures.