Skip to content
Permalink

Comparing changes

Choose two branches to see what’s changed or to start a new pull request. If you need to, you can also or learn more about diff comparisons.

Open a pull request

Create a new pull request by comparing changes across two branches. If you need to, you can also . Learn more about diff comparisons here.
base repository: github/gh-ost
Failed to load repositories. Confirm that selected base ref is valid, then try again.
Loading
base: v1.1.9
Choose a base ref
...
head repository: github/gh-ost
Failed to load repositories. Confirm that selected head ref is valid, then try again.
Loading
compare: v1.1.10
Choose a head ref
  • 11 commits
  • 155 files changed
  • 12 contributors

Commits on May 11, 2026

  1. Prevent throttle() from blocking forever when context is cancelled (#…

    …1671)
    
    * Prevent throttle() from blocking forever when context is cancelled
    
    When abort() is called (e.g. due to heartbeat failures after a MySQL
    failover), the context is cancelled and initiateThrottlerChecks exits
    via ctx.Done() without calling SetThrottled(false). The throttle() loop
    only checks IsThrottled(), so it would spin indefinitely, preventing the
    migration from ever returning.
    
    Replace time.Sleep with a select on ctx.Done() so throttle() unblocks
    immediately on context cancellation.
    
    Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
    
    * Address copilot feedback
    
    ---------
    
    Co-authored-by: Claude Sonnet 4.6 <noreply@anthropic.com>
    ggilder and claude authored May 11, 2026
    Configuration menu
    Copy the full SHA
    494570d View commit details
    Browse the repository at this point in the history

Commits on May 14, 2026

  1. Add MigrationContext.Hooks for in-process hook implementations (#1675)

    * Add MigrationContext.Hooks for in-process hook implementations
    
    gh-ost's only hook extension point is on-disk scripts globbed from
    --hooks-path. Library callers that embed Migrator must either ship
    scripts and their dependencies alongside their binary or maintain a
    parallel Go layer that bridges script side effects back into the host
    application.
    
    Introduce a Hooks interface in go/base with one method per lifecycle
    event, and an optional MigrationContext.Hooks field. NewMigrator reads
    the field once at construction and falls back to the existing
    HooksExecutor when unset, so CLI behavior is unchanged. A CompositeHooks
    helper in go/logic lets callers run the on-disk script executor and
    their own Go implementation side-by-side.
    
    HooksExecutor's previously package-private method names are renamed
    (onStartup -> OnStartup, etc.) so external types can satisfy the
    interface. The struct and constructor were already exported but the
    methods weren't, so no usable external API is displaced.
    
    * Skip nil entries in CompositeHooks and self-contain doc example
    
    Address PR review feedback:
    
    - CompositeHooks.OnX methods skip nil members instead of panicking,
      allowing callers to conditionally append optional hooks.
    - doc/hooks.md embedded-usage snippet now defines ctx and version so it
      is self-contained.
    olsonjp authored May 14, 2026
    Configuration menu
    Copy the full SHA
    e62debe View commit details
    Browse the repository at this point in the history

Commits on May 15, 2026

  1. Bump golang.org/x/crypto from 0.37.0 to 0.45.0 in the go_modules grou…

    …p across 1 directory (#1606)
    
    * Bump golang.org/x/crypto in the go_modules group across 1 directory
    
    Bumps the go_modules group with 1 update in the / directory: [golang.org/x/crypto](https://github.com/golang/crypto).
    
    
    Updates `golang.org/x/crypto` from 0.37.0 to 0.45.0
    - [Commits](golang/crypto@v0.37.0...v0.45.0)
    
    ---
    updated-dependencies:
    - dependency-name: golang.org/x/crypto
      dependency-version: 0.45.0
      dependency-type: indirect
      dependency-group: go_modules
    ...
    
    Signed-off-by: dependabot[bot] <support@github.com>
    
    ---------
    
    Signed-off-by: dependabot[bot] <support@github.com>
    Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
    Co-authored-by: meiji163 <meiji163@github.com>
    dependabot[bot] and meiji163 authored May 15, 2026
    Configuration menu
    Copy the full SHA
    b9ff6a6 View commit details
    Browse the repository at this point in the history

Commits on May 19, 2026

  1. Configuration menu
    Copy the full SHA
    fe459a9 View commit details
    Browse the repository at this point in the history
  2. Handle context cancellation in consumeRowCopyComplete to prevent dead…

    …locks (#1677)
    
    Co-authored-by: meiji163 <meiji163@github.com>
    jakubpliszka and meiji163 authored May 19, 2026
    Configuration menu
    Copy the full SHA
    154d214 View commit details
    Browse the repository at this point in the history

Commits on May 26, 2026

  1. Fix resume data loss: route heartbeat coords through applyEventsQueue (

    …#1684)
    
    * Fix resume data loss: route heartbeat coords through applyEventsQueue
    
    onChangelogHeartbeatEvent was mutating applier.CurrentCoordinates directly
    from the streamer goroutine, before any DML that preceded the heartbeat was
    applied to the ghost table. The checkpoint loop reads CurrentCoordinates as
    "applied through this GTID" and could persist a checkpoint whose
    LastTrxCoords was ahead of what was actually applied.
    
    If gh-ost crashed before applyEventsQueue drained, --resume read that
    checkpoint and called StartSyncGTID with the persisted set; MySQL treated
    the un-applied GTIDs as already-seen and never re-streamed them. The ghost
    table silently lost those DMLs and cut-over produced a stale table.
    
    Fix: enqueue a tableWriteFunc onto applyEventsQueue that performs the
    coords bump. The apply goroutine executes it in order, after the DMLs the
    streamer enqueued before the heartbeat, restoring the invariant.
    
    Adds TestMigratorHeartbeatDoesNotAdvancePastUnappliedDML, which fails at
    the previous HEAD and passes after the fix; also asserts queue ordering to
    guard against future changes that wrap the heartbeat enqueue in a goroutine.
    
    Co-authored-by: Bastian Bartmann <bastian.bartmann@shopify.com>
    
    * Replace direct channel write with SendWithContext
    
    Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
    
    ---------
    
    Co-authored-by: Bastian Bartmann <bastian.bartmann@shopify.com>
    Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
    3 people authored May 26, 2026
    Configuration menu
    Copy the full SHA
    72cf229 View commit details
    Browse the repository at this point in the history

Commits on May 27, 2026

  1. Configuration menu
    Copy the full SHA
    e59af3a View commit details
    Browse the repository at this point in the history
  2. Add Go runtime metrics to statsd reporting (#1690)

    * Add Datadog/statsd with simple client emitting startup
    
    * Add go runtime metrics to statsd reporting
    
    ---------
    
    Co-authored-by: meiji163 <meiji163@github.com>
    forge33 and meiji163 authored May 27, 2026
    Configuration menu
    Copy the full SHA
    59f400f View commit details
    Browse the repository at this point in the history

Commits on May 28, 2026

  1. Configuration menu
    Copy the full SHA
    c636347 View commit details
    Browse the repository at this point in the history

Commits on May 29, 2026

  1. Use os.TempDir() for test socket path (#1694)

    Refactor newTestMigrationContext to set ServeSocketFile via os.TempDir() and remove runtime.Caller-based path derivation.
    ericyan authored May 29, 2026
    Configuration menu
    Copy the full SHA
    251b08d View commit details
    Browse the repository at this point in the history

Commits on Jun 1, 2026

  1. Configuration menu
    Copy the full SHA
    835f537 View commit details
    Browse the repository at this point in the history
Loading