Page MenuHomePhabricator

Postgres installation at times reports ERROR: syntax error at or near "pg_advisory_unlock_all" at character 1
Closed, ResolvedPublicBUG REPORT

Description

Steps to replicate the issue (include links if applicable):

  • MediaWiki 1.39.4
  • Postgres

What happens?:
ERROR: syntax error at or near "pg_advisory_unlock_all" at character 1 is reported at times

According to the reporting user this is because in includes/libs/rdbms/database/DatabasePostgres.php in the function doFlushSession, the Query is incorrectly constructed. The effective query should be SELECT pg_advisory_unlock_all() but now it is pg_advisory_unlock_all()

If so, then this problem was introduced in 1.39 by @aaron in Change-ID I60532f86e629c83b357d4832d1963eca17752944

Event Timeline

Restricted Application added a subscriber: Aklapper. · View Herald Transcript

When fixed, this should probably be back ported to 1.39 being an LTS.

Change 940944 had a related patch set uploaded (by Ammarpad; author: Ammarpad):

[mediawiki/core@master] rdbms: Fix postgres db function call

https://gerrit.wikimedia.org/r/940944

Change 940944 merged by jenkins-bot:

[mediawiki/core@master] rdbms: Fix postgres db function call

https://gerrit.wikimedia.org/r/940944

Change 941406 had a related patch set uploaded (by TheDJ; author: Ammarpad):

[mediawiki/core@REL1_40] rdbms: Fix postgres db function call

https://gerrit.wikimedia.org/r/941406

Change 941407 had a related patch set uploaded (by TheDJ; author: Ammarpad):

[mediawiki/core@REL1_39] rdbms: Fix postgres db function call

https://gerrit.wikimedia.org/r/941407

Change 941407 merged by jenkins-bot:

[mediawiki/core@REL1_39] rdbms: Fix postgres db function call

https://gerrit.wikimedia.org/r/941407

Change 941406 merged by jenkins-bot:

[mediawiki/core@REL1_40] rdbms: Fix postgres db function call

https://gerrit.wikimedia.org/r/941406

TheDJ assigned this task to Ammarpad.