Skip to content
Snippets Groups Projects

refactoring backfiller to support non-global iteration

Merged Warren Gifford requested to merge insights/unify/historical_enq_refactor into main

Created by: coury-clark

Closes https://github.com/sourcegraph/sourcegraph/issues/36098 Closes https://github.com/sourcegraph/sourcegraph/issues/35580

Refactors the historical backfiller to support non globally scoped series in support of unifying insight behaviors. Some thoughts:

  1. Refactoring this was kind of a mess, and isn't necessarily in the state I'd like it to be. However it works and I'd like to get this merged so we can start to test this earlier than later. Happy for any suggestions, I feel like I'm going in circles on this.
  2. This has a very basic integration with the API, and only on the create path. Edits don't work yet. We have a separate issue here.
  3. We can toggle the behavior of the backfill with the feature flag code_insights_deprecate_jit. You can create an override for your user with this gql (replace the namespace with your user ID)
mutation CreateFeatureFlagOverride{
  createFeatureFlagOverride(
    namespace: "VXNlcjox", 
    flagName: "code_insights_deprecate_jit",
    value: true,
  ){
    __typename
  }
}
  1. There isn't really any new test coverage on the scoped path. I'm going to add this in a follow up PR because it's somewhat non-trivial and this PR is already fairly complicated.

Test plan

I've tested a variety of scenarios locally, but by no means is exhaustive. Here is a screenshot of the dashboard showing a bunch of scoped (mostly using the query insights) series. CleanShot 2022-05-26 at 15 03 16@2x

Merge request reports

Merged by avatar (Jul 13, 2025 4:13pm UTC)

Loading

Activity

Filter activity
  • Approvals
  • Assignees & reviewers
  • Comments (from bots)
  • Comments (from users)
  • Commits & branches
  • Edits
  • Labels
  • Lock status
  • Mentions
  • Merge request status
  • Tracking
Please register or sign in to reply
Loading