Comment 6 for bug 1277053

Revision history for this message
Alex Yurchenko (ayurchen) wrote : Re: [Bug 1277053] Add optional causality check to autocommit UPDATE/DELETE statements

On 2014-02-06 23:38, Jay Janssen wrote:
> Hum, I thought causal_reads were literally just finding all SELECTs.
> Are you saying causal_reads are always in effect for explicit
> transactions? With or without wsrep_causal_reads=1?

wsrep_causal_reads=1 was always effective for SHOW, autocommit SELECTs,
and beginning of transaction, whether explicit or implicit.

>> wsrep_causal_wait = <mask> (1 - SELECT, SHOW, BEGIN, 2 -
>> UPDATE/DELETE,
>> 4 - INSERT)
>>
>> wsrep_causal_reads=ON would be equivalent to wsrep_causal_wait=1
>
> So was SHOW and BEGIN (and I assume START TRANSACTION) always part of
> causal_reads? Why SHOW?

Yes. SHOW because of status variables. Like wsrep_last_committed.

> Any command in autocommit=0 will start a transaction I think — would
> that be covered by wsrep_causal_wait=1? The extra masks are only for
> autocommit=1?

Yes and yes. Unless I'm missing something about trans_begin() purpose.

> Jay Janssen
> http://about.me/jay.janssen
>
> --
> You received this bug notification because you are subscribed to the
> bug
> report.
> https://bugs.launchpad.net/bugs/1277053
>
> Title:
> Add optional causality check to autocommit UPDATE/DELETE statements
>
> Status in MySQL patches by Codership:
> New
> Status in MySQL patches by Codership 5.5 series:
> New
> Status in MySQL patches by Codership 5.6 series:
> New
>
> Bug description:
> While not doing causality check on UPDATE / DELETE does not return
> outdated values, it still can break application logic in that the
> statement may go ineffective because of the missing row. Note that
> this won't return a deadlock error (Query OK, 0 rows affected) so the
> application has no hint to retry the statement.
>
> To manage notifications about this bug go to:
> https://bugs.launchpad.net/codership-mysql/+bug/1277053/+subscriptions

--
Alexey Yurchenko,
Codership Oy, www.codership.com
Skype: alexey.yurchenko, Phone: +358-400-516-011