Re: Updates, ShareLocks, RowExclusiveLocks, and deadlocks

From: Ben Chobot <bench(at)silentmedia(dot)com>
To: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
Cc: pgsql-general <pgsql-general(at)postgresql(dot)org>
Subject: Re: Updates, ShareLocks, RowExclusiveLocks, and deadlocks
Date: 2012-04-25 19:43:35
Message-ID: 34867911-3DC4-48F9-BD73-975AE9748CCD@silentmedia.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general


On Apr 25, 2012, at 1:31 PM, Tom Lane wrote:

> I don't have all the details in my head, but if you deliberately provoke
> a deadlock by making two transactions update the same two rows in
> opposite orders, you'll soon find out what it looks like in the log.

Heh, duh. Looks like your first guess was correct, as usual. Conflicting updates in two transactions show up in the logs as a ShareLock deadlock.

Thanks!

In response to

Browse pgsql-general by date

  From Date Subject
Next Message Tom Lane 2012-04-25 19:45:06 Re: Updates, ShareLocks, RowExclusiveLocks, and deadlocks
Previous Message Martijn van Oosterhout 2012-04-25 19:33:49 Re: Updates, ShareLocks, RowExclusiveLocks, and deadlocks