[development] drupal on postgresql benchmark
larry at garfieldtech.com
Tue Nov 27 05:06:50 UTC 2007
On Monday 26 November 2007, Earnie Boyd wrote:
> >> Incidentally, there are lots of places where Drupal could use
> >> transactions when they're available. user_add and node_save would
> >> both be a lot more DB-crash-resistant, for starters.
> >> jh
> > The problem is that transaction support is not universal. In MySQL,
> > for example, if you roll back a transaction it will roll back but
> > throw a warning on any MyISAM tables that were affected, so unless
> > you're using no MyISAM tables the rollback is not actually complete
> > or atomic. If you're on shared hosting, 95% chance you're on MyISAM.
> If the choice is to use InnoDB then the port should default to InnoDB.
> Another port can be used for a MyISAM default.
I have no idea what you're talking about. :-) MySQL can be run quite happily
with some tables InnoDB, some MyISAM. You can also run a Master/slave
configuration with the Master InnoDB and the slaves MyISAM (or vice versa,
although why you'd want to I have no idea). That means sometimes a
transaction may not rollback properly, and other times it will. We can't
have "two Drupals", one that uses transactions and one that doesn't (if
that's what you mean by port, since TCP port wouldn't make any sense in this
Our choices are:
1) Don't use transactions.
2) Use transactions and silently ignore it when a rollback doesn't actually
roll back, and/or file a watchdog entry but otherwise don't do anything.
3) Allow the user to explicitly flag if a connection should use transactions,
defaulting no, and if not then starting a transaction has no effect and
neither does rolling back or committing.
4) Don't support database configurations that don't fully support
#4 is not an option, naturally. #1 seems like a waste, but it is what we do
now. That leaves #2 and #3 as alternatives. I am not entirely sure which
route is least lame at the moment. :-)
Larry Garfield AIM: LOLG42
larry at garfieldtech.com ICQ: 6817012
"If nature has made any one thing less susceptible than all others of
exclusive property, it is the action of the thinking power called an idea,
which an individual may exclusively possess as long as he keeps it to
himself; but the moment it is divulged, it forces itself into the possession
of every one, and the receiver cannot dispossess himself of it." -- Thomas
More information about the development