Bug #115811 | Replication Delay consistent at 1 second. | ||
---|---|---|---|
Submitted: | 9 Aug 2024 18:59 | Modified: | 12 Aug 2024 19:51 |
Reporter: | Gabe Tucker | Email Updates: | |
Status: | Can't repeat | Impact on me: | |
Category: | MySQL Server: Replication | Severity: | S3 (Non-critical) |
Version: | 8.0.35-27 | OS: | Ubuntu (Only Tested on Ubuntu) |
Assigned to: | MySQL Verification Team | CPU Architecture: | Any |
Tags: | replication performance |
[9 Aug 2024 18:59]
Gabe Tucker
[12 Aug 2024 11:07]
MySQL Verification Team
Hi, I am not sure I understand the report? You are reporting that you have 1sec replication delay or something else? 1sec replication delay is not a bug.
[12 Aug 2024 13:36]
Gabe Tucker
Hi, I believe that there is a bug with replica_parallel_workers and replica_parallel_type. I agree that 1 one second delay is not a bug :) As I mentioned, we have a single database instance, 5.7.37-40 master with an 8.0.35-27 replica. Our 5.7.37-40 replica was not experiencing any replications delays while we had consistent replication delays on our 8.0.35-27. We checked the settings that we have on the 5.7 replicas. They have replica_parallel_workers=0 and replica_parallel_type="DATABASE" As setting replica_parallel_workers to 0 is deprecated and will be removed, and that we only need one replica sql thread, we set this to 1, which we expect to be one thread to apply the replication transactions. Additionally, replica_parallel_type of DATABASE is deprecated in this versions and will be removed, we set this to "LOGICAL CLOCK" However, with these settings, we experience constant replication delay. When we set replica_parallel_workers=0 and replica_parallel_type="DATABASE", the 8.0.35-27 replica no longer has replication delay. The documentation says that both replica_parallel_workers=0 and replica_parallel_type="DATABASE" are being deprecated: "As of MySQL 8.0.30, setting this variable to 0 is deprecated, raises a warning, and is subject to removal in a future MySQL release. For a single worker, set replica_parallel_workers to 1 instead. ... replica_parallel_type is deprecated beginning with MySQL 8.0.29, as is support for parallelization of transactions using database partitioning. Expect support for these to be removed in a future release, and for LOGICAL_CLOCK to be used exclusively thereafter." Since the recommended settings for our single database, replica_parallel_workers=1 and replica_parallel_type="LOGICAL_CLOCK", cause us replication delays, we believe that there is a bug. Thank You
[12 Aug 2024 15:36]
MySQL Verification Team
Hi, Problem is that difference between 0 and 1 is not something we can use as important factor as we are "rounding" here so we are talking probably between difference of 0.4 and 0.6 seconds between two configs. This is why I cannot accept this as "causing replication delay". There is always a delay in replication, it is impossible to have slave lag really 0 seconds as there is time required to send data to slave and implement the changes, maybe it will be in microseconds but it will not be 0. Since we are rounding to a whole second, 1 second is not a delay really - not a change I can call "causing replication delay".
[12 Aug 2024 17:10]
Gabe Tucker
I understand your points and I feel that there is something not working properly. If I have more time, I will work on this more to better prove my point. Unfortunately, I do not have that time currently. Thank You
[12 Aug 2024 19:51]
MySQL Verification Team
Hi Gabe, Please do. I tried this myself and I get 1 on both, as expected. If we were talking about 10sec and 15sec it would make sense but 1sec difference can be from 0.01sec to 1.4sec difference. Let us know if you manage to get more data about it