Opend
← All company guides

Free interview prep

Get ready for
GitLab.

Code review · CI systems · async collaboration

GitLab · Opend practice case · Updated

Can a faster pipeline still deploy the right commit?

A monorepo builds an API in four minutes and a UI in ten. API tests take six minutes and UI tests take two. Both test suites currently wait for the entire build stage. Design the fastest safe deployment assuming two available runners.

Short answerSchedule each test as soon as its own build succeeds. Deploy after both required test jobs pass, then serialize access to the target environment across pipelines.

Independent branches meet at the release gate
API
Build 4mTest 6m
UI
Build 10mTest 2m
  • API branch

    Build from minute 0 to 4. Test from minute 4 to 10.

  • UI branch

    Build from minute 0 to 10. Test from minute 10 to 12.

  • Release gate

    Both branches are green at minute 12. Deploy the tested artifact for that commit.

Compute the critical path before adding runners

With a stage barrier, both builds finish at minute ten. The longest test then takes another six minutes. With explicit dependencies, the longest path instead takes twelve minutes. The API test occupies the runner freed by the API build. The UI build keeps its original runner. GitLab supports expressing these dependencies with needs. The timing calculation assumes no queue delay and excludes deployment time.

GitLab job dependencies with needs ↗

Carry artifact identity through the graph

Tests should consume the artifact produced by their declared upstream commit. A shared mutable tag such as latest can point at a newer build by the time a test starts. Pass the digest or immutable artifact reference downstream. When an upstream test fails, block deployment and keep the failed run inspectable. A retry can rerun the failed test against the same artifact without rebuilding everything.

Handle two pipelines finishing out of order

Suppose commit B finishes while older commit A waits for a flaky test. A resource group serializes deployment to one environment. Mutual exclusion alone still permits A to deploy after B. Pick an ordering policy and add an environment check that rejects an obsolete candidate, while leaving an explicit rollback path. GitLab documents different resource-group processing modes and their requirements.

GitLab resource groups and process modes ↗
Earliest safe release, in minutes
ScheduleAPI tests finishBoth branches ready
Build-stage barrier · 2 runners1616
Dependency graph · 2 runners1012
Same work · 1 runnerOrder dependent22
Try the follow-upShould the deployment run at minute ten if the API tests have already passed?

Only if the deployable unit is genuinely independent of the UI and has its own release contract. In this exercise one release contains both artifacts. Removing the dependency saves time by changing what green means. Splitting releases requires a compatibility strategy and a way to roll each part back.

Interview rounds & focus areas

GitLab's candidate handbook lists screening, role-dependent assessments or technical interviews, team interviews, references and offer/background steps. Your recruiter confirms which stages apply.

  1. PREP FOCUS 01

    Screening & role alignment

    Prepare your motivation, relevant experience and questions about the team.

  2. PREP FOCUS 02

    Technical assessment, where required

    Practice coding, code review and explaining tradeoffs. The format depends on the role.

  3. PREP FOCUS 03

    Team interviews

    Use concrete examples of collaboration, engineering judgment and communicating decisions asynchronously.

More practice questions

Try each Opend practice question before opening its hints.

How would you review a change that adds a background job?Code review / LLD · Open solution hints
  1. Check idempotency, retry behavior, authorization and failure observability.
  2. Ask whether the job can run twice or run after its source record changes.
  3. Separate correctness blockers from style suggestions; propose a focused test.
How would you schedule a CI pipeline with dependencies?Coding / systems · Open solution hints
  1. Represent jobs as a directed graph and detect cycles.
  2. Track dependency completion, bounded concurrency and failed or cancelled ancestors.
  3. Explain how restarts avoid rerunning completed external side effects.
How do you explain a technical disagreement asynchronously?Collaboration · Open solution hints
  1. Write the shared problem, evidence and tradeoffs before recommending an option.
  2. Record the decision and what new evidence would change it.
  3. Use a real example and describe how you kept the work moving.

Live open roles at GitLab

Employer sources checked within seven days. This catalogue covers India and worldwide remote engineering openings; confirm location and availability on the employer’s site.

View live roles & check your fit →

Get a free personal fit check →