← Back to team overview

openerp-expert-framework team mailing list archive

Re: soft coded constraints

 

Am Mittwoch 28 April 2010 10:33:02 schrieb P. Christeas:
> On Wednesday 28 April 2010, Ferdinand Gassauer wrote:
> > https://blueprints.launchpad.net/openobject-server/+spec/constraints-exte
> > ns ion
> > 
> > any comments on this ?
> 
> That's interesting. I would only cross-check that this mechanism will not
> add any significant overhead.
> 
> On another note, it may just be that Postgres constraints can also be seen
> through a table/view, so that this module can access them. If done so (with
> some postgres magic), we could expose those fast constraints to the UI and
> thus configuration.
> 
> On a sidenote, shouldn't constraint failures result in a custom Exception,
> like 'osv_constraint_fail', so that we can handle them better at higher
> level?
Everything is possible - we just did it this way as it was apparently 
comfortable for us.
I am not so familiar with this
I believe  that we need "soft failure" to get a list of failing constraints at 
once if we check these conditions for all resources

see code. (which has to be renamed obviously)
-- 
Best Regards

ChriCar Beteiligungs- und Beratungs- GmbH
http://www.chricar.at/ChriCar/index.html
Dr. Ferdinand Gassauer
Official Tiny Partner

Attachment: dimu_constraint.zip
Description: Zip archive


References