So Rails 3 is around the corner and I thought this would be as good a time as any to rewrite the site.
I don't plan on adding or removing any features, or changing the layout significantly. The rewrite will mainly focus on refactoring and designing the site in a more idiomatic style. But now is a good time to ask for some blue sky features, things that would require a major migration that could mean hours of downtime. I'll start by listing some stuff that has been on my wishlist for awhile.
- Switching to Ruby 1.9. The micro-benchmarks are impressive and it seems most of the tools and libraries are offering better support.
- Switching to HTML5. My hope is that I can write more semantic markup that doesn't have ugly Javascript blocks everywhere.
- Using ActiveResource/named routing extensively. I don't expect this to affect the API that much, but the URLs will change, and instead of just GET/POST the site will use GET/POST/PUT/DELETE. I also want to break up large controllers, ideally restricting them to CRUD actions only.
- More idiomatic testing, including usage of factories and stubs. The goal would be independence between test suites and eliminating fixtures.
- Refactoring stylesheets, likely breaking them up into individual files like how Javascripts are currently organized.
- Denormalization of favorites, pools, and uploader. They will now be treated like tags. I will still maintain join tables for favorites and pools for custom ordering, but you will be able to find the intersection between two favorites, exclude an uploader, find all the related tags for a pool, etc. If there's anything else you think might be a good target for denormalization let me know.
Things I'm debating over:
- Using sampling to calculate related tags. That is, loading N random posts for a tag and calculating related tags based on that sample. The goal is to eliminate the posts_tags table. Related tag by type would probably be harder. But the join table is at 7 million records now and has all sorts of indexes and triggers associated with it. It'd be nice to eliminate this table entirely.
- Switching to jQuery. jQuery is gaining mindshare over Prototype and I think it's better architected. This will involve rewriting most of the Javascripts however. But it remains to be seen how good Rails's integration with jQuery will be, and I'm not sure what switching gains me.
- Internationalization. I'm not sure how useful this would be since tags would still be in English, but it would be easy to translate the rest of the site.
- Switching to git. I'd like to host the site on github and not worry about backing up my Subversion repository all the time. I also hate merging in Subversion.
As you can see there's a lot on my plate, most of it of intangible benefit to site users. None of this will be deployed anytime soon. If you have any ideas or comments let me know.
Updated by StriderTuna