View Single Post

   
  #2 (permalink)  
Old 02-28-2008, 07:48 AM
Rick James
 
Posts: n/a
Default RE: 2PC on master-slave with replication

No.

Transactions involve only one machine.

Furthermore, writing to the master and then reading from a slave runs the
risk of replication delays. Granted, delays are usually sub-second, but if
something big goes thru replication, it can get behind. Your application
should understand the delay and either live with or code around it -- such
as going to the master for things (eg your transaction) that must be
consistent. Leave the bulk of reads for slaves.

> -----Original Message-----
> From: Darpan Dinker [mailto:darpandinker@gmail.com]
> Sent: Tuesday, July 10, 2007 12:37 AM
> To: mysql@lists.mysql.com; replication@lists.mysql.com
> Subject: 2PC on master-slave with replication
>
> Hi,
> Is it possible to have a transaction with an update statement
> pointed to
> the master and a select statement pointed to the slave. If
> the isolation
> level of this transaction is REPEATABLE_READ or SERIALIZABLE, will a
> commit involve 2PC?
> Thanks,
> Darpan
>
> --
> MySQL Replication Mailing List
> For list archives: http://lists.mysql.com/replication
> To unsubscribe:
> http://lists.mysql.com/replication?u...@yahoo-inc.com
>
>


Reply With Quote