2022-07-14: Group's "CI/CD > Runners" page returns 500 for all users

Incident Roles

The DRI for this incident is the incident issue assignee, see roles and responsibilities.

Roles when the incident was declared:

  • Incident Manager (IMOC): @mksionek, @juan-silva, mkaeppler (user lookup failed), @theoretick
  • Engineer on-call (EOC): @mwasilewski-gitlab, cgardner (user lookup failed)

Current Status

Group runners pages display 500 error. Runners themselves are working fine and are picking up work.

See https://gitlab.com/groups/gitlab-com/-/runners as an example

Here's the MR with the fix: gitlab-org/gitlab!92411 (merged) . It was picked up for deployment so it should reach production in a couple of hours.

Summary for CMOC notice / Exec summary:

  1. Customer Impact: GitLab's group and instance admin runners views unavailable (showing empty results)
  2. Service Impact: ServiceCI Runners ServiceWeb
  3. Impact Duration: 2022-07-14T13:09 to 2022-07-14T18:48 (339 minutes)
  4. Root cause: A code refactor introduced a regression that prevented the dashboard from loading and required corrective MR to address

Timeline

Recent Events (available internally only):

  • Deployments
  • Feature Flag Changes
  • Infrastructure Configurations
  • GCP Events (e.g. host failure)
  • Gitlab.com Latest Updates

All times UTC.

2022-07-14

  • 13:09 - Łukasz Korbasiewicz declares incident in Slack.
  • 13:30 - The root cause was identified and an MR created
  • 14:05 - We discussed the solution and added to the deployment pipeline.
  • 14:15 - Updated the status page to notify users of the known issue and the fix coming up
  • 16:18 - Fix has landed on canary and should be accessible from next.gitlab.com
  • 16:19 - Confirmed fixed in canary
  • 18:48 - New pod deployment has reached gprd and runner page is loading as expected. Status page updated accordingly

Create related issues

Use the following links to create related issues to this incident if additional work needs to be completed after it is resolved:

  • Corrective action
  • Investigation followup
  • Confidential / Support contact
  • QA investigation
  • Infradev

Takeaways

  • The lack of adequate integration tests prevented the change of a service's return type from being surfaced at the GraphQL query level.

Corrective Actions

Corrective actions should be put here as soon as an incident is mitigated, ensure that all corrective actions mentioned in the notes below are included.

  • Fix chatops reporting incorrect deployment information for the provided fix: delivery#2483 (closed);
  • gitlab-org/gitlab!92411 (merged) was created to address the root issue by fixing the usages of check_runner_upgrade_status;
  • gitlab-org/gitlab#367836 (closed) was created to add integration tests that would have surfaced the problem at development time.

Note: In some cases we need to redact information from public view. We only do this in a limited number of documented cases. This might include the summary, timeline or any other bits of information, laid out in out handbook page. Any of this confidential data will be in a linked issue, only visible internally. By default, all information we can share, will be public, in accordance to our transparency value.


Click to expand or collapse the Incident Review section.

Incident Review

  • Ensure that the exec summary is completed at the top of the incident issue, the timeline is updated and relevant graphs are included in the summary
  • If there are any corrective action items mentioned in the notes on the incident, ensure they are listed in the "Corrective Action" section
  • Fill out relevant sections below or link to the meeting review notes that cover these topics

Customer Impact

  1. Who was impacted by this incident? (i.e. external customers, internal customers)
    1. SaaS customers who tried to manage GitLab runners at the group level;
    2. Internal customers who tried to manage GitLab runners at the instance or group level.
  2. What was the customer experience during the incident? (i.e. preventing them from doing X, incorrect display of Y, ...)
    1. The customer would see an HTTP 500 page, preventing them from seeing the list of runners, and to interact with their registration. For example: listing or deleting runners, changing their tags, pausing/unpausing them, or seeing the registration token that would allow the customer to register new runners.
  3. How many customers were affected?
    1. Any SaaS customer who visited the group runners page. Kibana prod logs show a total of 586 unique users (including GitLab engineers).
  4. If a precise customer impact number is unknown, what is the estimated impact (number and ratio of failed requests, amount of traffic drop, ...)?
    1. 100% of the visits to the runners' admin page resulted in a 500 error. Kibana shows that there were a total of 11230 requests that resulted in a 500 error.

What were the root causes?

  • A small code refactor introduced a regression on newly introduced functionality that wasn't sufficiently covered by integration tests (unit tests were sufficient).

Incident Response Analysis

  1. How was the incident detected?
    1. Customers reported 500 errors while trying to access the runners' management page.
  2. How could detection time be improved?
    1. Having monitoring tests on staging that attempt visiting a runners admin page and confirm that a success HTTP status code is returned (500 was being returned in this case).
  3. How was the root cause diagnosed?
    1. The root cause was immediately evident to the original author since a related change had been merged a few hours before, and the error was reproducible in GraphiQL Explorer only when requesting the upgradeStatus field.
  4. How could time to diagnosis be improved?
    1. The diagnosis was quite quick, so I'm not sure if we could have improved (at least in this situation). Maybe having more details like the call stack or exception message in the GraphQL endpoint message, instead of the generic Internal server error.
  5. How did we reach the point where we knew how to mitigate the impact?
    1. After reproducing the error in GraphiQL Explorer and obtaining the call stack in the log files, it became immediately apparent that some usages of the check_runner_upgrade_status method hadn't been updated, and it would be a question of merging an MR that updated those usages.
  6. How could time to mitigation be improved?
    1. N/A
  7. What went well?
    1. The MR was quickly created, reviewed, and merged. It was picked into autodeploy at 11:35 UTC, but only went live on production at 18:25 UTC.

Post Incident Analysis

  1. Did we have other events in the past with the same root cause?
    1. No
  2. Do we have existing backlog items that would've prevented or greatly reduced the impact of this incident?
    1. There were no existing backlog items regarding that.
  3. Was this incident triggered by a change (deployment of code or change to infrastructure)? If yes, link the issue.
    1. No

What went well?

  • @mrincon flagged an issue with runners admin page, which allowed the original author to quickly push a corrective action MR through review and pick into autodeploy.

  • The incident team reached out to the delivery team to understand why a fix that the chatbot said was in canary wasn't actually deployed yet.

    @rpereira2: Yup, the auto_deploy status command looks at where the auto_deploy branch has been deployed. Looks like it doesn't consider the case where there are commits in the auto deploy branch that have not been included in the deployment.

Guidelines

  • Blameless RCA Guideline

Resources

  1. If the Situation Zoom room was utilised, recording will be automatically uploaded to Incident room Google Drive folder (private)
Edited Jul 19, 2022 by Pedro Pombeiro
Assignee Loading
Time tracking Loading