[Dbix-class] Integration with Moose (DBIx-enabled Moose objects)?

Alex Peters dbix at alexpeters.net
Sat Aug 23 05:22:06 BST 2008


Hi,

I'm starting a new project using Moose[1] and am wondering how
best to handle persistent storage of these Moose objects.

If I weren't using Moose, DBIx::Class would be the obvious
answer here.  However, in a way Moose and DBIx::Class seem to
overlap in terms of the functionality that they provide (auto-
generated accessors/mutators, etc.).

There seems to be very little information on the internet about
using the two together, and I've scanned this year's posts to
this mailing list for any references to Moose and found almost
nothing[2] on this matter.

So: has anyone here written Moose classes that feature DBIx::
Class functionality?  What approaches have been tried and how
do they rank in usability and maintainability?

Perhaps there's a (very well hidden) Moose plugin that makes
the whole process trivial?

I'm not even sure if this is the right place to ask.  I'm kinda
surprised that it hasn't really been asked yet--like the answer
should be blatantly obvious, but I've stared at the problem for
too long.

Regards,
Alex

[1] Moose - A postmodern object system for Perl 5
    http://www.iinteractive.com/moose/

[2] Column constraints
    http://lists.scsys.co.uk/pipermail/dbix-class/2008-April/006177.html



More information about the DBIx-Class mailing list