Interface MergeQueueCheckContext


public interface MergeQueueCheckContext
The context provided to a MergeQueueCheck when it is run.

This context provides information a check needs to evaluate whether a queued pull request is ready to be merged.

Since:
10.2
See Also:
  • Method Summary

    Modifier and Type
    Method
    Description
    Returns the hash of the prepared merge commit, that represents the result of merging the pull request into the target branch in the merge queue.
    com.atlassian.bitbucket.pull.PullRequest
     
  • Method Details

    • getMergeHash

      @Nonnull String getMergeHash()
      Returns the hash of the prepared merge commit, that represents the result of merging the pull request into the target branch in the merge queue.

      This "merge hash" is the commit that would become the new tip of the target branch if the queued merge is applied. It is the actual code that will be merged, including changes from pull requests that are ahead in the queue. Depending on the merge strategy it may be:

      • a synthetic merge commit, or
      • the pull request head commit (for fast-forward merges).
      Implementations of MergeQueueCheck can use this hash to query build statuses or perform other checks against the merged state of the pull request.
      Returns:
      the merge hash for this pull request in the merge queue
    • getPullRequest

      @Nonnull com.atlassian.bitbucket.pull.PullRequest getPullRequest()
      Returns:
      the pull request that was added to the merge queue