-
Notifications
You must be signed in to change notification settings - Fork 185
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
Upgrade to 1102 erased all resource labels #434
Comments
Ouch. That not good . I have tested it with JCaC and on my production jenkins too. And has works as well. Do you use JCaC or classic configuration via /manage page? Just to simulate it assap |
I am managing classically, still. I need to eventually convert to casc. On the whole it wasn't too bad since I had downloaded my casc configuration and could look that up to reapply it. |
Thx for answer. I will try to reproduce it. When it is not critical, it might take a while, because my vacation starts today. |
I thing I find it. |
Sorry, I am wrong. It must be used the 'new' wrong format with the tags. |
Ah, that's good to know. All the more reason for me to work on upgrading to a proper configuration as code setup, eh? |
How to explain it. Configuration as code is perfect feature. But it is definitely a bug. So it must be fixed by our side. But yes I personally will propose to use JCaC. it helps you to manage many things in jenkins. I personally like it because our Configuration is in git repository. That means it is transparent who and why make the changes. |
Hi to all, just to inform, it happened to me too. We need to improve ourselves in doing that conf via code, but we are not there yet. Fortunately we updated only our test env, so we will wait for the fix to update the pdn env. Thanks for doing this super plugin!! for us is really useful! |
Thx for feedback. I am currently on the vacation. I will try to fix it at January. I have the fix now. But it is not checked in, because I don't like not tested last checkins. So we hear us in next year. |
It occurred to us, too. Thanks for your work on this useful plugin and for the heads up regarding CaC. |
Came here to report this issue as well. Thanks for having it fixed already! |
Hi, after the upgrade to 1102, I manually restored all missing labels. It looks like the new version erased them again. |
same to me.. I will wait for next release. I'm testing in UAT. This time it seams that in the xml the labels were there, but jenkins did not show them or was taking in consideration on the gui and use. I opened the xml and copy the labels from there to restore uat. I think first time, were even erased from xml. Thanks |
Can somebody poste here your configs please. This is strange behavior. I test it in few scenarios and found only one failure. When you save your configs in the version 1102 from global-config page, it will erase all labels. But in the latest 1106 release it must works. @rollingstones62 when I understand correct it, this is what you did:
|
Our scenario is the following:
After 1106, I once again re-created the labels. This is an excerpt from the diff of the backed up Jenkins configuration after I clicked "Save": <org.jenkins.plugins.lockableresources.LockableResource>
<name>tests-integration-installation-0</name>
<description>Lock for synchronizing integration test installations</description>
- <labels>
+ <labelsAsList>
<string>tests-integration-installation</string>
- </labels>
+ </labelsAsList>
<note></note>
<stolen>false</stolen>
<ephemeral>false</ephemeral>
<queueItemId>0</queueItemId>
<queuingStarted>0</queuingStarted>
<queuedContexts/>
</org.jenkins.plugins.lockableresources.LockableResource> |
Strange, let me check it. The config looks good. |
i confirm that same steps were done by me! thanks @andreyakostovsap and @mPokornyETM for the help |
I got it now. It is little hard to explain, but I will try to do my best: Config before 1102 will looks like:
This is simply string in xml config. The release 1102 expect list-of-string like this:
That was original issue. In the release 1106 I use new property 'labelsAsList' and convert automatically all string labels to the list. That fix the issue as well and do not slow down the plugin. Pretty nice BUT
It looks to be good and work for the release 1102. And the fun starts now :-( When you has config from 1102, it is not possible to read it in 1106, because the property labels is It is really not possible, to do it programmatically or better I have no solution for that :-(. I am so sorry, but yeah, we can not jump back to the history.
to
(currently tested by me and it works) or install JCaC plugin export current properties, make a update and import it again. What we shall definitely to do, is to update 'Proposed upgrade guidelines' in the 1106 and documentation as well. Again sorry for that. |
Please can somebody check linked PR #440 |
Jenkins and plugins versions report
Environment
What Operating System are you using (both controller, and any agents involved in the problem)?
Linux on controller (Docker container)
Windows on most agents needing the locked resources
Reproduction steps
Expected Results
I expected my labels to still be available after upgrading the plugin.
Actual Results
The labels on all of my lockable resources were empty.
Anything else?
No response
The text was updated successfully, but these errors were encountered: