Open timja opened 6 years ago
Another use case: for JEP-200 we added several whitelist entries to core that actually apply to classes bundled in plugins, to make sure people could do a core upgrade without having to know about plugins to update. With this API, once the plugin releases appear which (for now redundantly) include those entries, we could delete them from core with a notice that the newer core versions are incompatible with the older plugin versions.
Maybe go shopping in the RPM dependency documentation for this: http://rpm.org/user_doc/dependencies.html http://rpm.org/user_doc/more_dependencies.html http://rpm.org/user_doc/boolean_dependencies.html
And here is a guide from openSUSE on how to do package splits, merges, renames, ...:
https://en.opensuse.org/openSUSE:Package_dependencies#Basic_dependencies
Yes Linux package manager docs would be a good source of potential use cases to validate a solution against. I think we can get away with a simpler system, since:
I think we can get away with a simpler system
Sure, I just think that with Requirements and Incompatible-With (aka Conflicts) you almost have everything in place to enable:
So I added the RPM documentation links here to save the implementer the time to come up with compatible semantics themselves.
Thinking about this some more I think Obsoletes and also handling core updates in the same resolver would net you almost everything. (IIRC KK talked about wanting to update core like the plugins)
JENKINS-31096 is another example of where this would be useful.
JENKINS-41854 is another example (DynamicContext needed a workflow-cps update to be interpreted).
JENKINS-5303 would be a major use case.
The current plugin metadata allows it to express minimum required versions of core and various other plugins, and this information is mirrored in update center metadata. That is enough for typical scenarios involving compatible upgrades of API components.
However, we have repeatedly encountered cases where Jenkins developers know that there are combinations of software components which will be broken for users. These include:
What all of these cases have in common is that there is some manner of incompatibility, and thus users who upgrade some components must also upgrade other components which would normally be in an inverse dependency relationship (or no expressed dependency at all) to avoid problems.
Unlike regular plugin dependencies, these relationships cannot be expressed in the downstream plugin manifest. For example, the fact that api 2.0 made incompatible changes which would break installations of impl 1.3 (which depended on api 1.2) cannot be expressed in impl 1.3's manifest—this might have been released years before the rewrite of api was even conceived. It is only the release of impl 2.0 which reveals the upgrade path. So we have two options:
This has the advantage that the relationships can be enforced by any part of the system, including plugin loading during startup, Docker image builders, JEP-201 if extended to declarative plugin configuration, etc. On the other hand you would need to a release an update to api every time another incompatible implementation is discovered (and a release using api 2.x cut).
Users participating in JEP-301 "Evergreen" should have less need of a system like this, since they would automatically receive only combinations of components which were pretested and verified compatible. But even Evergreen users could benefit if they are also adding plugins from outside the Essentials set, which might well be known to be broken by changes being made to other components (inside or outside Essentials).
Originally reported by jglick, imported from: Extend plugin/update center metadata with known incompatibilities