[Dbix-class] DBIx::Class::Schema::_find_all_mod

Andrew Tkachenko atk at adriver.ru
Thu Jan 14 14:44:08 GMT 2010


Hello.

I'm new here, so please forgive me if I accidentally break some posting 
rule(s).

I have a case when I need to compose schema on-the fly and 'load_namespaces' 
functionality isn't enough for me, since some result classes have been 
generated on-the-fly too (I use Moose ).
As I see, DBIx::Class::Schema::_find_all_mod uses Module::Find to find all 
modules under the given namespace. I have tried to override the method in my 
schema class, so now it can discover modules existing in the given namespace 
even if they aren't presented as a files (I use Module::Pluggable::Object).
It works for me, but I wonder if this hack could lead to some ugly side 
effects ?.  Also, may be this would be possible to add ability to choose the 
way to discover result sources - either via Module::Find or some other way as 
a feature into the DBIC distribution ?

Thanks in advance



More information about the DBIx-Class mailing list