-
-
Notifications
You must be signed in to change notification settings - Fork 31
Conversation
node ./prepare-essentials propose-updates | ||
node ./prepare-essentials propose-updates --uc ./update-center.json | ||
|
||
propose-experimental-updates: update-center-experimental.json |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Just offering an alternate target. Really this stuff should of course be replaced with usage of the updater logic from incrementals-tools
so that we get a single consistent way to update everything to whatever is in master
.
try { | ||
ok = compareVersions(needed[artifactId].version, plugin.version) == 1; | ||
} catch (x) { | ||
logger.warn(`Cannot compare ${artifactId}:${needed[artifactId].version} to ${plugin.version}: ${x}`); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Whatever Node library you are using to compare versions, it is hopeless in the face of the version numbers actually used in Jenkins components. We want to be using jenkinsci/lib-version-number
instead. (As, for example, incrementals-tools
does.)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I BTW, https://issues.jenkins-ci.org/browse/JENKINS-53767 is probably worth looking at. I agree at some point we'd need a central tool to do all this.
@@ -204,6 +211,7 @@ class ManifestResolver { | |||
return false; | |||
}).forEach((dep) => { | |||
envNeeds[dep] = deps[dep]; | |||
// TODO this is printing bogus messages like: The docker-cloud environment also needs docker-plugin |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Not sure what this is all about.
const manifest = Manifest.loadFile(); | ||
manifest.getPlugins().forEach((plugin) => { | ||
manifest.getActualPlugins().forEach((plugin) => { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The updater was failing to show updates to what was actually being delivered in status
! It only listed newer versions of plugins which were already in spec
. As I have noted before, this is not helpful, since for example workflow-aggregator
itself does nothing and should have been removed as of Jenkins 2; we need to actually enumerate the plugins we want to ship.
(compareVersions(updated.version, plugin.version) == 1)) { | ||
logger.info(`The update center has a newer ${plugin.artifactId}: ${updated.version}`); | ||
if (updated == null) { | ||
logger.warn(`No such plugin ${plugin.artifactId}`); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hit this at one point, not sure why.
version: '2.7' | ||
- groupId: org.jenkins-ci.plugins.workflow | ||
artifactId: workflow-support | ||
version: 2.21-beta-1 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This block is what I was actually trying to accomplish: pull in JEP-210.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Though I'm not against supporting using the experimental UC, I think it can be useful in some cases, why didn't you just use Incrementals to bump to latest of these?
services/essentials.yaml
Outdated
@@ -8,7 +8,7 @@ spec: | |||
plugins: | |||
- groupId: io.jenkins | |||
artifactId: configuration-as-code | |||
version: '1.0' | |||
version: '1.1' |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Just updating everything while I am here.
version: 1.29.3 | ||
- groupId: org.jenkins-ci.plugins | ||
artifactId: github-api | ||
version: '1.92' |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Seems the YAML serializer is more clever than we might like: x.y
is quoted as a string but x.y.z
is not, even though for our purposes we know all version
s ought to be loaded as strings. JavaScript 🤷♂️
@@ -87,6 +129,15 @@ spec: | |||
- groupId: org.jenkins-ci.plugins | |||
artifactId: jira | |||
version: 3.0.2 | |||
- groupId: org.jenkins-ci.ui | |||
artifactId: ace-editor |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hmm, we sort the status
when we write it out; should we not also sort the spec
?
(My advice remains to get rid of the separate spec
and status
sections.)
Build failed; the context from the latest run is: Expand to view
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM. It makes sense to me to support experimental UC in addition to the main one, though I wonder why we shouldn't anyway just jump to just using Incrementals.
But well, supporting this is probably good as we'll always find trickier cases where we'd like to consume experimental releases from non-incrementalified plugins, and having it is a good thing.
version: '2.7' | ||
- groupId: org.jenkins-ci.plugins.workflow | ||
artifactId: workflow-support | ||
version: 2.21-beta-1 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Though I'm not against supporting using the experimental UC, I think it can be useful in some cases, why didn't you just use Incrementals to bump to latest of these?
try { | ||
ok = compareVersions(needed[artifactId].version, plugin.version) == 1; | ||
} catch (x) { | ||
logger.warn(`Cannot compare ${artifactId}:${needed[artifactId].version} to ${plugin.version}: ${x}`); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I BTW, https://issues.jenkins-ci.org/browse/JENKINS-53767 is probably worth looking at. I agree at some point we'd need a central tool to do all this.
That would be my preference. I was making the minimal change I needed to get this particular set of updates in (with repeatable tooling rather than one-off edits). As noted in #312 (comment) I am not aware of existing tooling to do this. |
Well, you could always just file a PR to mvn incrementals:incrementalify and ship the result. :-) |
Going to bring these in before some other updates just to keep the pipes moving |
Pulls in JEP-210 beta releases. @svanoort @dwnusbaum