Reviews by rabble

cpanratings
 

RSS

Test-Unit (0.25) ****

This is the perl testing library to use if you are going to build out tests for large perl applications and libraries. I definitely recommend it. It provides a lot more control than the standard Test::Simple and Test::More libraries. Tests are more maintainable and readable.

Class-DBI (0.94) *****

Class::DBI is the first OR mapper in Perl which i've tried and actually continued to use. It's very perl like in that it makes easy things easy, and hard things possible by allowing you to drop back in to the normal DBI functions.

Converting a web app with 23,000 lines of code to using Class::DBI cut out 10,000 lines of code. I found that i was able to do the boring work of pulling data out of the database and constructing objects much faster with CDBI than what i had before which was just using DBI and Class::Accessor.

I see two major faults with CDBI. One is that it tends to hit the database a lot. It doesn't do joins, but rather separate selects. This means what was one select with a 7 way join has become 14 selects. Other times i've seen code which used to be one or two selects become dozens or hundreds. Acts which would make any DBA cringe. There has been some talk about improving the joining functionality within CDBI. Also there is some idea to add caching, which would significantly improve things.

CDBI has a good interface for overriding it's functions to improve functionality and provide customs cases. This is vital for anybody using CDBI for non-trivial projects.

The other issues is that despite the copious documentation there still isn't nearly enough. This is also something which i expect to improve with time. The gurus on the CDBI list have been very good about nicely responding to questions and reading the archives can make up for the 'missing manual'.

All in all, it's not a magic bullet. I have fears about it's scalability and performance on production applications but that's overweighed by the huge improvement in programmer efficiency.