Skip to content

Remove global metadata/index.json file and its usage#960

Closed
jormundur00 wants to merge 3 commits intomasterfrom
jormundur00/gh-847
Closed

Remove global metadata/index.json file and its usage#960
jormundur00 wants to merge 3 commits intomasterfrom
jormundur00/gh-847

Conversation

@jormundur00
Copy link
Member

@jormundur00 jormundur00 commented Jan 21, 2026

What does this PR do?

In this PR we remove the global index.json file located at metadata/index.json to simplify new metadata addition (so we only need to create/maintain one index.json file located at metadata/groupId/artifactId/index.json per library artifact).

To do this, we move the allowed-packages and requires fields to the inner index.json, as this is data that only the global one had previously. As the module field was used to map between the global and inner index files, we remove this field as it was redundant (the information it keeps can always be resolved from the inner-index's path). All library metadata resolution is now based on file paths (so every library is strictly in metadata/<groupId>/<artifactId>). The scaffold and other tasks which generate these metadata directories have also been updated accordingly to match the new format.

As these changes include relatively major changes to the index structure, the remaining schema version was bumped from 1.0.0 to 2.0.0.

As running changes in this PR depend on the buildtools PR which adds support for the removal of the metadata/index.json file, and this PR depends on buildtools working with the new format to successfully pass CI, the merge/release process of these PRs should have the following order:

  1. This PR should be merged first (running CI on the branch of the buildtools PR to complete successfully),
  2. The next reachability metadata release should be dispatched so that buildtools can use it in their corresponding PR,
  3. The buildtools PR should then include the bump to this new reachability metadata version and get merged ASAP,
  4. This repository's CI will work on the latest SNAPSHOT of buildtools until the new NBT release is released (which should be scheduled as soon as the buildtools PR is merged),
  5. We open a follow-up PR here to use the newest release of buildtools and no longer use snapshots in the CI.

Fixes: #847

@jormundur00
Copy link
Member Author

Closed to rename branch (as we want to have mirror branch names on this repo and NBT). New PR is here: #983.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Feature: Remove global metadata index.json from the repository

1 participant