aboutsummaryrefslogtreecommitdiffstats

# Cherry-pick Status Viewer Plugin for Gerrit

Gerrit Version License

A Gerrit plugin that provides web UI and REST API for fetching updated statuses of cherry-picks.

## Features

  • Web UI Features:
  • Filtering of changes based on repo name, original change owner
  • Additional filtering options to exclude results which contain blocker changes in ABANDONED.
  • Each created change links to the change in gerrit.
  • Finds tqtc-hidden changes even if the source change started in public repos and branches.
  • Security:
  • Uses Gerrit's internal user-based repo filtering to prevent unauthorized viewing.
  • Uses Gerrit's internal user-based accounts filtering to reject filtering on a user the viewing user cannot see.
  • Suggestions for both repo and user filters based on user-visible data provided by gerrit.
  • Anonymous access allowed, showing only publicly visible projects and changes.
  • Server-authenticated Database access performed by plugin backend.
  • API Support:
  • REST endpoint authenticated with user session, REST authentication, or anonymous access.

Installation

  1. Build the plugin: Requires building in-tree with Gerrit.

    bazelisk build plugins/gerrit-plugin-cherrypickstatus

  2. Deploy to Gerrit:

    • Copy target/gerrit-plugin-cherrypickstatus.jar to review_site/plugins/gerrit-plugin-cherrypickstatus

Testing:

  1. bazel test //plugins/gerrit-plugin-cherrypickstatus:tests

Configuration

  1. Configure /review_site/etc/gerrit-plugin-cherrypickstatus.config using the included example.
  2. Change of plugin configuration may require a full gerrit restart if gerrit plugin reload does not work.

Usage

  1. Navigate to /x/gerrit-plugin-cherrypickstatus/cherrypick:
    • Select "Cherry Pick Status" from the top menu
    • Select "View Status"

API Documentation

Get Configuration

GET /config/server/getdashboard

Parameters:

  • owner: Optional, email address.
  • repo: Optional, string. Do not use URI Encoding. If omitted, returns all visible repos.
  • onlyStuck: Optional, bool. Returns only changes with cherry-picks in problematic statuses
  • exclAbandon: Optional, bool. Requires combination with onlyStuck. Excludes changes where the only outstanding branches are abandoned, or depend on an abandoned change.

Response application/json: { totalPages: int, changes: [ { subject: str, repo: str, owner_email: str, merged_dt: date, branches: [{ status: str, depends_on: str, last_date: optional date, url: optional str }] } ] }