Skip to content

Conversation

@meiji163
Copy link
Contributor

Merge @grodowski's fix #1574.

Closes #1569

grodowski and others added 6 commits August 6, 2025 13:29
Based on experience, if the writer database fails inbeetween the copy & cutover stages (e.g. during cutover pause), the heartbeat writes will fail and stop,
then leading to throttled state and an infinite loop of throttler.shouldThrottle().

Since this state is irrecoverable, make the heartbeat writer panic if retries are exhausted, so that the migration can fail and be restarted later.
* add sysbench localtest

* fix table name

* Apply suggestion from @Copilot

Co-authored-by: Copilot <[email protected]>

* ensure cleanup

---------

Co-authored-by: Copilot <[email protected]>
@meiji163 meiji163 requested a review from rashiq as a code owner October 10, 2025 20:47
Copilot AI review requested due to automatic review settings October 10, 2025 20:47
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

This PR adds a panic mechanism to prevent infinite looping when heartbeat injection fails repeatedly in the gh-ost migration tool. The change ensures that if the InitiateHeartbeat function exhausts its retry attempts, it will trigger a panic abort instead of continuing indefinitely.

  • Adds panic abort mechanism when heartbeat injection fails after maximum retry attempts
  • Provides detailed error information including failure count and last encountered error

Tip: Customize your code reviews with copilot-instructions.md. Create the file or learn how to get started.

@meiji163 meiji163 merged commit 4f5e58c into master Oct 10, 2025
8 of 9 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

gh-ost process stuck infinitely after writer database failure

4 participants