Skip to content

Unified: convert data extensions to JSON - #23101

Merged
nickrolfe merged 2 commits into
mainfrom
nickrolfe/json-data-extensions-unified
Nov 11, 2026
Merged

nickrolfe merged 2 commits into
mainfrom
nickrolfe/json-data-extensions-unified

Conversation

@nickrolfe

Copy link
Copy Markdown
Contributor

CodeQL CLI 2.27.3 supports JSON data extensions (aka MaD models), and can load them significantly faster than YAML. This PR converts those in the Unified library pack (first commit), along with $TEST.ext.yml files (second commit). The conversions were automated by an LLM-generated Python script (which I will add in a separate PR).

Although JSON is preferred going forward, unified/ql/lib/qlpack.yml now has patterns that will pick up both .model.yml and .model.json files, so that any YAML files that do get checked in won't get silently dropped.

To verify successful conversion in the first commit, I cherry-picked it onto #23100, which has a temporary test that enumerates all tuples from data extensions. The test still passes after conversion.

@nickrolfe nickrolfe added the no-change-note-required This PR does not need a change note label Nov 11, 2026
@nickrolfe nickrolfe changed the title Unified: convert data extensionsn to JSON Unified: convert data extensions to JSON Nov 11, 2026
@nickrolfe
nickrolfe marked this pull request as ready for review November 11, 2026 14:20
@nickrolfe
nickrolfe requested a review from a team as a code owner November 11, 2026 14:20
Copilot AI auto review requested due to automatic review settings November 11, 2026 14:20

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🟢 Approval recommended

No active review issues are reported for the YAML-to-JSON data-extension migration.

No open issues 🎉

What changed in this PR

Converts Unified’s data extensions from YAML to JSON to use faster loading supported by CodeQL CLI 2.27.3, while retaining YAML discovery for future contributions.

Changes:

  • Migrates legacy Swift models to JSON without changing their tuples.
  • Converts dataflow and model-as-data test extensions to JSON.
  • Adds JSON model discovery alongside the existing YAML pattern.
File Description
unified/​ql/​test/​library-tests/​mad/​test.ext.yml Removes the replaced YAML test models.
unified/​ql/​test/​library-tests/​mad/​test.ext.json Preserves source and sink test models in JSON.
unified/​ql/​test/​library-tests/​dataflow/​test.ext.yml Removes the replaced YAML flow summaries.
unified/​ql/​test/​library-tests/​dataflow/​test.ext.json Preserves dataflow test summaries in JSON.
unified/​ql/​lib/​qlpack.yml Discovers both JSON and YAML model files.
unified/​ql/​lib/​ext/​legacy-swift.model.yml Removes the replaced YAML Swift models.
unified/​ql/​lib/​ext/​legacy-swift.model.json Carries forward Swift source, sink, and summary models in JSON.

Review effort: Balanced (auto)

@owen-mc owen-mc left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The described validation seems sufficient.

@nickrolfe
nickrolfe merged commit fbf9fca into main Nov 11, 2026
17 checks passed
@nickrolfe
nickrolfe deleted the nickrolfe/json-data-extensions-unified branch November 11, 2026 15:02
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

no-change-note-required This PR does not need a change note Unified

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants