Loading
Add Orbit trial state to the group GraphQL API
What does this MR do and why?
Adds the Orbit trial state to the group GraphQL API. The Orbit button uses it first.
Group.orbitTrial(OrbitTrial,OrbitTrialState,OrbitTrialCredits).- The
orbit_trialfeature flag and theread_orbit_trialpermission for Owners.
| CDot trial | Result |
|---|---|
| Can start a trial | ELIGIBLE |
| Cannot start a trial | NOT_ELIGIBLE |
| Active, with credits | ACTIVE |
| Expired, or 0 credits | ENDED |
| CustomersDot request fails | orbitTrial is null |
The field resolves for one group per request. A later MR adds the start mutation.
References
gitlab-org/orbit#19
Closes gitlab-org/orbit/knowledge-graph#1334
How to set up and validate locally
With a local CustomersDot, in the Rails console:
Feature.enable(:orbit_trial, group)Then, as an Owner of the group:
query {
group(fullPath: "gitlab-org") {
orbitTrial { state expiresOn credits { remaining total } }
}
}Demo against a local CustomersDot: eligible group, a Maintainer (no access), start (201), active, ended, and CDot down.
MR acceptance checklist
See the MR acceptance checklist.
Edited by Jean-Gabriel Doyon