timja / jenkins-gh-issues-poc-06-18

0 stars 0 forks source link

[JENKINS-49651] Extend plugin/update center metadata with known incompatibilities #9666

Open timja opened 6 years ago

timja commented 6 years ago

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:

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
  • status: Open
  • priority: Major
  • resolution: Unresolved
  • imported: 2022/01/10
timja commented 6 years ago

jglick:

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.

timja commented 6 years ago

cobexer:

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

 

timja commented 6 years ago

jglick:

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:

timja commented 6 years ago

cobexer:

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)

timja commented 6 years ago

jglick:

JENKINS-31096 is another example of where this would be useful.

timja commented 5 years ago

jglick:

JENKINS-41854 is another example (DynamicContext needed a workflow-cps update to be interpreted).

timja commented 4 years ago

jglick:

JENKINS-5303 would be a major use case.