Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1o9pje-0003q2-GP for pgsql-docs@arkaria.postgresql.org; Fri, 08 Jul 2022 15:17:38 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.92) (envelope-from ) id 1o9pjd-0004bY-15 for pgsql-docs@arkaria.postgresql.org; Fri, 08 Jul 2022 15:17:37 +0000 Received: from magus.postgresql.org ([2a02:c0:301:0:ffff::29]) by malur.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1o9pjc-0004bP-QD for pgsql-docs@lists.postgresql.org; Fri, 08 Jul 2022 15:17:36 +0000 Received: from momjian.us ([72.94.173.45]) by magus.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1o9pjZ-0004uS-Vv for pgsql-docs@lists.postgresql.org; Fri, 08 Jul 2022 15:17:36 +0000 Received: from bruce by momjian.us with local (Exim 4.94.2) (envelope-from ) id 1o9pjV-007NwG-MM; Fri, 08 Jul 2022 11:17:29 -0400 Date: Fri, 8 Jul 2022 11:17:29 -0400 From: Bruce Momjian To: Masahiko Sawada Cc: troy@frericks.us, pgsql-docs@lists.postgresql.org Subject: Re: How to reference the type of lock in the documentation. Message-ID: References: <165653551130.665.8240515669521441325@wrigleys.postgresql.org> MIME-Version: 1.0 Content-Type: multipart/mixed; boundary="LeJyhHXQo+iIV9j/" Content-Disposition: inline In-Reply-To: List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk --LeJyhHXQo+iIV9j/ Content-Type: text/plain; charset=us-ascii Content-Disposition: inline On Fri, Jul 8, 2022 at 11:12:59AM +0900, Masahiko Sawada wrote: > On Fri, Jul 8, 2022 at 10:21 AM Bruce Momjian wrote: > > > > On Wed, Jun 29, 2022 at 08:45:11PM +0000, PG Doc comments form wrote: > > > The following documentation comment has been logged on the website: > > > > > > Page: https://www.postgresql.org/docs/10/explicit-locking.html > > > Description: > > > > > > On page https://www.postgresql.org/docs/10/explicit-locking.html, I'd like > > > to suggest a search-engine-optimization improvement. Generally, but > > > especially on this page, it'd be nice to have the lock name along with the > > > user-friendly name. For example, with the first use of "SHARE UPDATE > > > EXCLUSIVE", I'd like to see the lock name with it, for example, "SHARE > > > UPDATE EXCLUSIVE (ShareUpdateExclusiveLock)". > > > > I see your point --- that the names that appear in the pg_locks view > > don't appear in our documentation. The attached patches adds the > > pg_locks names after each lock name. You can see the doc output here: > > > > https://momjian.us/tmp/pgsql/explicit-locking.html > > > > If people like this, I can apply it to all supported branches. > > +1 I wasn't happy with the '/' so I changed to using parentheses instead. Updated patch attached, same URL for updated output. -- Bruce Momjian https://momjian.us EDB https://enterprisedb.com Indecision is a decision. Inaction is an action. Mark Batterson --LeJyhHXQo+iIV9j/ Content-Type: text/x-diff; charset=us-ascii Content-Disposition: attachment; filename="lock.diff" diff --git a/doc/src/sgml/mvcc.sgml b/doc/src/sgml/mvcc.sgml index ff148bb3dc..14b51db55e 100644 --- a/doc/src/sgml/mvcc.sgml +++ b/doc/src/sgml/mvcc.sgml @@ -907,7 +907,7 @@ ERROR: could not serialize access due to read/write dependencies among transact Table-Level Lock Modes - ACCESS SHARE + ACCESS SHARE (AccessShareLock) @@ -925,7 +925,7 @@ ERROR: could not serialize access due to read/write dependencies among transact - ROW SHARE + ROW SHARE (RowShareLock) @@ -948,7 +948,7 @@ ERROR: could not serialize access due to read/write dependencies among transact - ROW EXCLUSIVE + ROW EXCLUSIVE (RowExclusiveLock) @@ -971,7 +971,7 @@ ERROR: could not serialize access due to read/write dependencies among transact - SHARE UPDATE EXCLUSIVE + SHARE UPDATE EXCLUSIVE (ShareUpdateExclusiveLock) @@ -997,7 +997,7 @@ ERROR: could not serialize access due to read/write dependencies among transact - SHARE + SHARE (ShareLock) @@ -1017,7 +1017,7 @@ ERROR: could not serialize access due to read/write dependencies among transact - SHARE ROW EXCLUSIVE + SHARE ROW EXCLUSIVE (ShareRowExclusiveLock) @@ -1039,7 +1039,7 @@ ERROR: could not serialize access due to read/write dependencies among transact - EXCLUSIVE + EXCLUSIVE (ExclusiveLock) @@ -1061,7 +1061,7 @@ ERROR: could not serialize access due to read/write dependencies among transact - ACCESS EXCLUSIVE + ACCESS EXCLUSIVE (AccessExclusiveLock) --LeJyhHXQo+iIV9j/--