> app_objects = managers.PolymorphicManager(Place, Restaurant,
> ItalianRestaurant)
> ``
> 
> This also makes it explicit which classes are participating in a join,
> rather than potentially joining a large number of installed model classes.
> 

Thus making it completely unnatural to inherit from a class that you
didn't write your self - ie you must monkey patch in the manager, and
then what kind of trouble do you get in when two apps by different users
want to extend the same core class.

Horrific. Coupling supertypes to subtypes is madness....

I think all that is needed here is education - it needs to be pointed
out what the costs of subtyping are.

One option would be to provide a method on managers to provide a "faster
but broken" manager, ie joinless. It needs to have a name to suggest
that it is not really recommended though, and should only be used if it
actually has a beneficial performance impact...

Reply via email to