[wp-trac] Re: [WordPress Trac] #9422: Make WP transaction safe
WordPress Trac
wp-trac at lists.automattic.com
Wed Apr 1 11:41:19 GMT 2009
#9422: Make WP transaction safe
-------------------------------+--------------------------------------------
Reporter: Denis-de-Bernardy | Owner: Denis-de-Bernardy
Type: enhancement | Status: new
Priority: normal | Milestone: 2.8
Component: Optimization | Version: 2.8
Severity: major | Keywords: has-patch tested dev-feedback
-------------------------------+--------------------------------------------
Comment(by Denis-de-Bernardy):
Quite honestly, I agree. I think int(11) would be large enough. Much like
text (or even smalltext) would be large enough for a user meta value. But
that is why I opened #9435. :-)
In this ticket, I'd rather focus on making sure transactions work. The DB
schema changes were necessary for the foreign keys, but it's still missing
a plugin hook here and there to toss in BEGIN and COMMIT statements where
needed.
For most things, foreign keys with on delete cascade statements are fine.
But if you've two or more blogs with a shared, custom users and usermeta
table, you need a means to make an entire transaction fail if it so
happens that things might get cascaded a bit too much.
Along the same lines, if money transactions are tied to user IDs, the last
thing you'd want are a cascade of events that ultimately delete important
rows that belong in an accounting software. (It's important to keep in
mind that triggers are *not* called in MySQL on cascade deleted rows.)
Can anyone commit 9422-ids-extra.diff and 9422-deleted-fix.diff? Once
that's done, I'll add a few clean-up diffs in #9435 against the resulting
schema.
--
Ticket URL: <http://core.trac.wordpress.org/ticket/9422#comment:15>
WordPress Trac <http://trac.wordpress.org/>
WordPress blogging software
More information about the wp-trac
mailing list