From 004ffaa91a28b860ec80351f07c22ca2f3398763 Mon Sep 17 00:00:00 2001 From: Aaron Schulz Date: Wed, 8 Mar 2017 21:16:00 -0800 Subject: [PATCH] Make masterPosWait() error clearer Change-Id: I86706b2c4167fba897c56235072675b66ed06634 --- includes/libs/rdbms/database/DatabaseMysqlBase.php | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/includes/libs/rdbms/database/DatabaseMysqlBase.php b/includes/libs/rdbms/database/DatabaseMysqlBase.php index 9270589345..e90002797c 100644 --- a/includes/libs/rdbms/database/DatabaseMysqlBase.php +++ b/includes/libs/rdbms/database/DatabaseMysqlBase.php @@ -821,7 +821,8 @@ abstract class DatabaseMysqlBase extends Database { $row = $res ? $this->fetchRow( $res ) : false; if ( !$row ) { - throw new DBExpectedError( $this, "Failed to query MASTER_POS_WAIT()" ); + throw new DBExpectedError( $this, + "MASTER_POS_WAIT() or MASTER_GTID_WAIT() failed: {$this->lastError()}" ); } // Result can be NULL (error), -1 (timeout), or 0+ per the MySQL manual -- 2.20.1