Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Improve the latest version updating to be dynamic #785

Open
johnoliver opened this issue Nov 7, 2023 · 1 comment
Open

Improve the latest version updating to be dynamic #785

johnoliver opened this issue Nov 7, 2023 · 1 comment
Labels
enhancement New feature or request good first issue Good for newcomers

Comments

@johnoliver
Copy link
Contributor

Currently the latest version is set at compile or runtime at:

https://github.com/adoptium/api.adoptium.net/blob/main/adoptium-models-parent/adoptium-api-v3-models/src/main/kotlin/net/adoptium/api/v3/models/Versions.kt#L14

But does not update when a new release is performed, requiring a re-deploy when we release a new major version.

We could make this more dynamic by sing the "tip information" that we pull down at:

https://github.com/adoptium/api.adoptium.net/blob/main/adoptium-updater-parent/adoptium-api-v3-updater/src/main/kotlin/net/adoptium/api/v3/dataSources/ReleaseVersionResolver.kt#L20

That tells us what is the latest version is in source code, so gives us a number that we could set the latest version number to, just need to figure out how to expose that version number and set it inside Versions.kt.

One issue: the incremental update only updates major versions that already exist within the repository, (see https://github.com/adoptium/api.adoptium.net/blob/main/adoptium-updater-parent/adoptium-api-v3-updater/src/main/kotlin/net/adoptium/api/v3/AdoptReposBuilder.kt#L46) as such, updating the Versions will not be enough on its own, the incremental update code would also need to be altered to look for a new major version too.

@johnoliver johnoliver added the enhancement New feature or request label Nov 7, 2023
@gdams gdams added the good first issue Good for newcomers label Nov 7, 2023
@gdams
Copy link
Member

gdams commented Nov 7, 2023

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request good first issue Good for newcomers
Projects
None yet
Development

No branches or pull requests

2 participants