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

Fix #188 Fixes for configuration migration from 1.8 to 2.0 #202

Merged
merged 5 commits into from
Nov 22, 2016

Conversation

OwensCode
Copy link
Contributor

Migrate multi-branch-project plugin template configuration from 1.8
format to 2.0 format.

@jenkinsadmin
Copy link
Member

Thank you for this pull request! Please check this document for how the Jenkins project handles pull requests.

@OwensCode OwensCode changed the title [JENKINS-188] Migrate multi-branch-project configs Fix #188 Migrate multi-branch-project configs Mar 28, 2016
- Migrate multi-branch-project plugin template configuration from 1.8
  format to 2.0 format.

- Remove Slack job properties from Pipeline projects which do not have
  publishers to migrate to.

- Refactor migration code to better handle the additional complexity.
@OwensCode OwensCode force-pushed the issue-188-missing-descriptor branch from f4e2fcd to b6fd0cb Compare April 14, 2016 20:43
@OwensCode OwensCode changed the title Fix #188 Migrate multi-branch-project configs Fix #188 Fixes for configuration migration from 1.8 to 2.0 Apr 14, 2016
@OwensCode
Copy link
Contributor Author

I've added more changes to fix issues with pipeline jobs, and I also refactored the configuration migration code quite extensively because it was becoming more complicated. It's all in this PR because nobody seemed to be reviewing it yet, and the changes are all related.

@froland
Copy link

froland commented Apr 29, 2016

Hi. Just sharing some feedback. I've encountered the same stacktrace running jobs that were created with Job DSL and seed plugins. I built the slack plugin from this pull request and now it runs OK.

@OwensCode
Copy link
Contributor Author

Thanks @froland!

@samrocketman
Copy link
Member

I built the slack plugin from this pull request and now it runs OK.

Nice! I'll let @kmadel weigh in for the final merge.

@froland
Copy link

froland commented May 2, 2016

Sorry, I was a bit too quick at celebrating. When I updated the plugin, the jobs already created worked but not the one I tried to build through the seed plugin afterwards. Weird. I'll investigate a bit more if I get some time.

@OwensCode
Copy link
Contributor Author

@froland I don't think anyone has mentioned the seeds plugin yet; I'll have to take a closer look. Let me know if you dig up any more details.

@OwensCode
Copy link
Contributor Author

@froland If I'm understanding what you're saying correctly, this issue needs to be fixed within the job dsl plugin (although it is caused by the slack plugin configuration change); it needs to be updated to generate the latest slack plugin configuration. Take a look at https://issues.jenkins-ci.org/browse/JENKINS-34124. If you scroll down to the bottom of that issue, there may have been a recent release that rectifies the situation.

If I'm not understanding you correctly, could you please post your seed configuration (or relevant parts of it) so I can test with it. Thanks.

@froland
Copy link

froland commented May 19, 2016

@OwensCode, your last comment is right. I'm still getting the following stack trace after updating all my Jenkins plugins to their latest version, but I guess this issue is more on the Job DSL plugin side.

FATAL: class jenkins.plugins.slack.SlackNotifier$SlackJobProperty is missing its descriptor
java.lang.AssertionError: class jenkins.plugins.slack.SlackNotifier$SlackJobProperty is missing its descriptor
at jenkins.model.Jenkins.getDescriptorOrDie(Jenkins.java:1225)
at hudson.model.JobProperty.getDescriptor(JobProperty.java:105)
at hudson.model.JobProperty.getDescriptor(JobProperty.java:79)
at hudson.model.Descriptor.toMap(Descriptor.java:973)
at hudson.model.Job.getProperties(Job.java:558)
at hudson.model.AbstractBuild$AbstractBuildExecution.run(AbstractBuild.java:531)
at hudson.model.Run.execute(Run.java:1738)
at hudson.model.FreeStyleBuild.run(FreeStyleBuild.java:43)
at hudson.model.ResourceController.execute(ResourceController.java:98)
at hudson.model.Executor.run(Executor.java:410)

@dalvizu
Copy link
Member

dalvizu commented Sep 6, 2016

I just used this to test out the fix for #188 -- works for me!

@samrocketman @kmadel I don't believe there were any issues in this pull request - the discussion above is about job-dsl, but it is orthogonal to this change. Can this be merged?

@kmadel
Copy link
Contributor

kmadel commented Nov 19, 2016

Please merge the latest changes from master into this branch.

@kmadel kmadel added this to the slack-2.2 milestone Nov 19, 2016
@OwensCode
Copy link
Contributor Author

@kmadel I've merged master into this branch.

@kmadel kmadel merged commit 79c7cf6 into jenkinsci:master Nov 22, 2016
@OwensCode OwensCode deleted the issue-188-missing-descriptor branch November 23, 2016 14:01
@samrocketman
Copy link
Member

Feel free to subscribe to #296 for updates related to Slack Plugin 2.2 release.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants