Bug #99500 incorrect table refs in documentation
Submitted: 9 May 2020 23:18 Modified: 18 May 2020 10:59
Reporter: Trey Raymond Email Updates:
Status: Closed Impact on me:
None 
Category:MySQL Server: Documentation Severity:S3 (Non-critical)
Version: OS:Any
Assigned to: CPU Architecture:Any

[9 May 2020 23:18] Trey Raymond
Description:
from https://dev.mysql.com/doc/refman/8.0/en/performance-schema-replication-tables.html

 In the Performance Schema, this error information is available in the LAST_ERROR_NUMBER and LAST_ERROR_MESSAGE columns of the replication_applier_status_by_coordinator table (and replication_applier_status_by_worker if the slave is multithreaded). Those tables provide more specific per-thread error information than is available from Last_Errno and Last_Error. 

in reality, the replication_applier_status_by_coordinator table is only populated on a multi-threaded slave.  for a single threaded one, that table is empty, and you need to check by_worker (which will in this case have one row per channel).

How to repeat:
read doc

Suggested fix:
fix doc
[11 May 2020 12:19] MySQL Verification Team
Hello Mr. Raymond,

Thank you for your documentation bug report.

Let me just clear one small detail, before I verify your report.

According to your report, current documentation is correct in the case when you have multi-threaded slave. However, it is incorrect for a single-threaded slave.

Am I correct ???

Thank you in advance.
[11 May 2020 21:25] Trey Raymond
that's right.
channel count is one for single source repl, in the numbers below.

with slave_parallel_workers>0:
replication_applier_status_by_coordinator - has one row per channel
replication_applier_status_by_worker - has one row per worker (channel count * slave_parallel_workers)

with slave_parallel_workers=0:
replication_applier_status_by_coordinator - has 0 rows, this table is unused in this case
replication_applier_status_by_worker - has one row per channel, this single table takes over the role of both
[11 May 2020 21:26] Trey Raymond
it'd be nice to have it consistent no matter what the setting, of course, but that's the way it is currently
[12 May 2020 12:18] MySQL Verification Team
Hi Mr. Raymond,

Thanks a lot for the clarification.

Verified as a documentation bug.
[18 May 2020 10:59] Margaret Fisher
Posted by developer:
 
Thanks very much for pointing this out! I have corrected the error in 8.0 and 5.7.
[18 May 2020 12:37] MySQL Verification Team
Thank you, Mrs. Fisher.