embedded trasactions in postgreSQL with python?

Gerhard Häring gerhard.haering at gmx.de
Tue Dec 3 14:20:30 EST 2002


Ken McCracken wrote:
> There is some open source software our community network (Toronto
> Free-Net)  is interested in implementing... if it supports postgresql
> rather than the current oracle-only implementation. The Compiere.org team
> was working on it but got stuck at the point of supporting postgresql
> embedded transactions.

I'm not familiar with this term, but I'll assume that it means the
same as 'nested transactions'.

> I was wondering if the quote from their web page concerning this
> issue posted Dec 2, "The best choice is to convert Compiere to using
> Container Managed Persistency (CMP)"

Not without predjudices, but I doubt that switching to an EJB
technology will solve more problems than it creates.

> is really true, or if perhaps there is a more or less prefab way to
> accomplish this in python and postgresql.

Python can't make PostgreSQL support nested transactions. But as
nested transactions and safepoints are on PostgreSQL's TODO list,
maybe these folks would be better off sponsoring the implementation of
the desired features for PostgreSQL 7.4.

> [...]
> ---------------------------------------------------------------------
> http://www.compiere.org/technology/independence.html
> 
> Database Independence
> 
> There is quite some talk about database independence - it seems
> everyone wants it.
> 
> We tried to port Compiere to PostgreSQL, but got stuck at the end.
> Compiere is using embedded transactions, which are mainly supported
> by databases like DB/2 or Oracle. [...]

Well, easy solution. Rewrite your app to work without 'embedded
transactions' :-) My naive feeling is that this should be possible
with well thought-out changes to the database schema.

> The best choice is to convert Compiere to using Container Managed
> Persistency (CMP) and handle all transaction management within Java.
> This is NOT simple and we teamed up with The JBoss Group to achieve
> this. [...]

If it is really that difficult, then maybe just implementing the
lacking PostgreSQL features would be an option.

-- Gerhard



More information about the Python-list mailing list