To find out if this integration is available in your organization, see your Datadog Integrations page or ask your organization administrator.
To initiate an exception request to enable this integration for your organization, email [email protected].
Mergify - Merge Queue Stats
このページは日本語には対応しておりません。随時翻訳に取り組んでいます。
翻訳に関してご質問やご意見ございましたら、
お気軽にご連絡ください。
Overview
This integration sends Mergify merge queue metrics to your Datadog account, so you can monitor and alert on your merge queue alongside the rest of your observability data. It covers merge queue throughput (pull requests entered and merged, queue and batch size), queue health (exit reasons, check outcomes, CI retries, and bisections), and performance (queue time, CI runtime, and idle waits) for each configured repository. It ships with an out-of-the-box Mergify - Merge Queue Stats dashboard to get you started.
Setup
- In Datadog: Go to Integrations, select the Mergify tile and click Install Integration.
- Click Connect Accounts to begin authorization of this integration. You will be redirected to the Mergify dashboard.
- In the Mergify dashboard: Log in, select the organization you would like to set up the Datadog Integration for and click Connect the integration.
Your Mergify statistics now appear in Datadog.
Uninstallation
- Go to the Mergify dashboard, log in, and navigate to Integrations.
- Click the Disconnect button in the Datadog tile.
Once this integration has been uninstalled, any previous authorizations are revoked.
Note: Ensure that all API keys associated with this integration have been disabled by searching for the integration name on the Datadog API Keys page.
Data Collected
Metrics
| |
|---|
mergify.merge_queue_length (gauge) | [Deprecated] Merge queue length. Use mergify.queue.size.max instead |
mergify.time_to_merge.median (gauge) | [Deprecated] Median time to merge. Use mergify.queue.total_queue_time instead Shown as second |
mergify.time_to_merge.mean (gauge) | [Deprecated] Mean time to merge. Use mergify.queue.total_queue_time instead Shown as second |
mergify.queue_checks_outcome (gauge) | [Deprecated] Number of queue operation outcomes by outcome_type tag. Use mergify.queue.check_outcome instead |
mergify.queue.entered (count) | Number of pull requests that entered the merge queue |
mergify.queue.merged (count) | Number of pull requests merged from the queue |
mergify.queue.size.max (gauge) | Maximum number of pull requests waiting in the queue during the period |
mergify.queue.batch_size.sum (count) | Sum of batch sizes in pull requests per batch. Divide by mergify.queue.batch_size.count for the average batch size |
mergify.queue.batch_size.count (count) | Number of batches observed. Denominator for the average batch size |
mergify.queue.running_checks.max (gauge) | Maximum number of concurrent CI checks running for the queue during the period |
mergify.queue.exit_reason (count) | Number of pull requests that left the queue split by reason in the exit_reason tag |
mergify.queue.check_outcome (count) | Number of batch check outcomes split by result in the outcome tag |
mergify.queue.checks_retries.recovered (count) | Number of CI check sessions that recovered after a retry |
mergify.queue.checks_retries.not_recovered (count) | Number of CI check sessions that did not recover after a retry |
mergify.queue.bisection.started (count) | Number of batch bisections started to isolate a failing pull request |
mergify.queue.total_queue_time.sum (count) | Sum of total time pull requests spent in the queue. Divide by mergify.queue.total_queue_time.count for the average queue time Shown as second |
mergify.queue.total_queue_time.count (count) | Number of pull requests that left the queue. Denominator for the average total queue time |
mergify.queue.ci_runtime.sum (count) | Sum of CI runtime across queued pull requests. Divide by mergify.queue.ci_runtime.count for the average CI runtime Shown as second |
mergify.queue.ci_runtime.count (count) | Number of CI runtime samples. Denominator for the average CI runtime |
mergify.queue.idle.capacity.sum (count) | Sum of time pull requests spent waiting for queue capacity (CI slots). Divide by mergify.queue.idle.count for the average Shown as second |
mergify.queue.idle.schedule.sum (count) | Sum of time pull requests spent waiting on a merge schedule. Divide by mergify.queue.idle.count for the average Shown as second |
mergify.queue.idle.freeze.sum (count) | Sum of time pull requests spent waiting on a queue freeze. Divide by mergify.queue.idle.count for the average Shown as second |
mergify.queue.idle.count (count) | Number of queue-leave events. Shared denominator for the mergify.queue.idle.*.sum metrics |
The merge queue stats metrics (prefixed mergify.queue.) cover three categories:
- Throughput: pull requests entered and merged, queue size, batch size, and concurrent running checks.
- Queue Health: queue exit reasons, batch check outcomes, CI check retries, and batch bisections.
- Performance: total queue time, CI runtime, and idle time spent waiting for capacity, schedules, or freezes.
These metrics are tagged by repository, branch, queue, and priority_rule. Duration and size averages are submitted as sum and count companions, derived in Datadog as sum / count (for example, mergify.queue.total_queue_time.sum / mergify.queue.total_queue_time.count).
Queue outcomes and exit reasons
mergify.queue.check_outcome (tag outcome) and the deprecated mergify.queue_checks_outcome (tag outcome_type) report the same set of values. mergify.queue.exit_reason (tag exit_reason) reports these same values plus UNKNOWN (no reason was recorded):
SUCCESS: the pull request was mergedPR_DEQUEUED: the pull request was manually dequeuedPR_DEQUEUED_FROM_PARTITION: the pull request was removed from a partitionPR_AHEAD_DEQUEUED: a pull request ahead in the queue was dequeuedBATCH_AHEAD_FAILED: a batch ahead in the queue failed to mergePR_WITH_HIGHER_PRIORITY_QUEUED: a higher-priority pull request was queuedSCHEDULED_FREEZE_STATUS_CHANGED: a scheduled freeze changed the freeze statusSPECULATIVE_CHECK_NUMBER_REDUCED: the number of speculative checks was reducedCHECKS_TIMEOUT: the speculative checks timed outCHECKS_FAILED: the speculative checks failedQUEUE_RULE_MISSING: the queue rule used to queue the pull request no longer existsBASE_BRANCH_MISSING: the base branch no longer existsBASE_BRANCH_CHANGED: the pull request base branch changedPR_UNEXPECTEDLY_FAILED_TO_MERGE: the pull request unexpectedly failed to mergeBATCH_MAX_FAILURE_RESOLUTION_ATTEMPTS: the maximum batch failure-resolution attempts were reachedPR_CHECKS_STOPPED_BECAUSE_MERGE_QUEUE_PAUSE: checks were interrupted because the merge queue is pausedCONFLICT_WITH_BASE_BRANCH: the pull request conflicts with the base branchCONFLICT_WITH_PULL_AHEAD: the pull request conflicts with a pull request ahead in the queueBRANCH_UPDATE_FAILED: the pull request branch could not be updatedDRAFT_PULL_REQUEST_CHANGED: non-Mergify commits were added to the draft pull requestBATCH_PULL_REQUEST_CLOSED: the batch pull request was closedPULL_REQUEST_UPDATED: the pull request was manually updatedMERGE_QUEUE_RESET: the merge queue was resetINCOMPATIBILITY_WITH_BRANCH_PROTECTIONS: the pull request is incompatible with the branch protectionsPR_MANUALLY_MERGED: the pull request was merged manually, outside MergifyDRAFT_PULL_REQUEST_CREATION_FAILED: the draft pull request could not be createdDRAFT_PULL_REQUEST_CREATION_BRANCH_NOT_INDEXED: the draft pull request could not be created because of a GitHub branch-indexing delayCONFIGURATION_CHANGED: the Mergify configuration changedUNPROCESSABLE_PULL_REQUEST: the pull request could not be processedPR_MANUALLY_DEQUEUED: the pull request was dequeued by a commandSTACK_PREDECESSOR_DEQUEUED: a stack predecessor was dequeuedINTERMEDIATE_RESULTS_SKIPPED: intermediate results were skipped during batch promotionCHECKS_RETRIED: the checks failed and are being retriedSCHEDULE_BLOCKED_AHEAD_YIELDED: a schedule-blocked pull request ahead yielded its position
Service Checks
Mergify does not include any service checks.
Events
Mergify does not include any events.
Support
Need help? Contact Mergify support.