Fix source indexer stage - #7694
Conversation
There was a problem hiding this comment.
Pull request overview
This PR adjusts the Azure Pipelines configuration to fix/unstick the source indexing stage by reusing the repository’s restore/build steps in a shared template and wiring those steps into the source-index job.
Changes:
- Introduces a reusable
RestoreAndBuild.ymlpipeline template encapsulating Node setup, restore, solution generation, and build. - Refactors
BuildAndTest.ymlto consume the new restore/build template instead of duplicating those steps. - Updates
azure-pipelines.ymlto drive source indexing via a parameterized condition and to run restore/build aspreStepsfor the source-index job.
Reviewed changes
Copilot reviewed 3 out of 3 changed files in this pull request and generated 3 comments.
| File | Description |
|---|---|
| eng/pipelines/templates/RestoreAndBuild.yml | New shared restore/build step template used by build/test and source-index preSteps. |
| eng/pipelines/templates/BuildAndTest.yml | Switches restore/build steps to use the shared template. |
| azure-pipelines.yml | Updates source index configuration (condition, build script variable, and preSteps using the shared template). |
💡 Add a code-review agent skill for context-aware, tailored reviews. Learn more in the docs.
| enableMicrobuild: true | ||
| enableTelemetry: true | ||
| enableSourceIndex: ${{ variables['enableSourceIndex'] }} | ||
| enableSourceIndex: true |
There was a problem hiding this comment.
Does this mean that it will enable source index updating even for PRs now?
There was a problem hiding this comment.
No, the condition just moved (because I needed it to depend on a runtime variable forceEnableSourceIndex for testing, and ${{ }} can only use compile time variables).
Validation: https://dev.azure.com/dnceng/internal/_build/results?buildId=3044826&view=results
(Ignore the intermediate commits, they contain some experiments; this should be squashed on merge.)
Microsoft Reviewers: Open in CodeFlow