ObjectWeb Consortium
Search ObjectWeb Mail Archive: 

Advanced Search - Powered by Google


Mail Archive Home | enhydra List | Febuary 1999 Index

<--  Date Index  --> <--  Thread Index  -->

Re: Enhydra: Phonelist Demo App


>
> In Readme, there is a note saying that the phonelist app will not run
> with a MySQL database.
>

MySQL does not support transactions. The DatabaseManager uses transactions
to roll back updates when several tables need to be updated at once and
there is a problem after the first update.

It would be easy to write a subclass of StandardDatabaseManager for the
MySQL case. It would just set a flag that turns of the use of transactions.
But then if there were an error you would be left with a corrupted database.
This defeats the whole purpose of using a database ;)

Suppose you have two users viewing a row from a database. Then they both
update the data. The first user to commit to the database will work fine.
The second one will fail, because Enhydra will notice (through hidden
version numbers) that the data has changed out from under us. If the
failure happens on the thrid table, then the first two tables are now out
of synch with the third.

This is a general problem with MySQL and all databases that do not support
transactions. I'm not a database guy, but it seems to me it would be very
hard for any program using such a database to guarantee consistancy of the
data.

Hmmmm... maybe we could lock all the tables, then update, then unlock?
It would be slow, but MySQL is free, so.....? You would have to watch
out for deadlock situations, but they can be avoided.

Andy John


-----------------------------------------------------------------------------
To unsubscribe from this mailing list, send email to majordomo@xxxxxxxxxxx
with the text "unsubscribe enhydra" in the body of the email.
If you have other questions regarding this mailing list, send email to
the list admin at owner-enhydra@xxxxxxxxxxxx




<--  Date Index  --> <--  Thread Index  -->

Reply via email to:

Powered by MHonArc.

Copyright © 1999-2005, ObjectWeb Consortium | contact | webmaster.