[JIRA] (JENKINS-60393) cloudbees-folder circular dependency

68 views
Skip to first unread message

mhall@tivo.com (JIRA)

unread,
Dec 6, 2019, 3:33:03 PM12/6/19
to jenkinsc...@googlegroups.com
Matthew Hall created an issue
 
Jenkins / Bug JENKINS-60393
cloudbees-folder circular dependency
Issue Type: Bug Bug
Assignee: Francisco Fernández
Components: cloudbees-folder-plugin
Created: 2019-12-06 20:32
Environment: jenkins 2.190.3
cloudbees-folder-plugin 6.10
Priority: Minor Minor
Reporter: Matthew Hall

 

Seeing the following in my jenkins log as a stacktrace :

 

2019-12-06 19:26:29.676+0000 [id=29] WARNING h.ExtensionFinder$GuiceFinder$FaultTolerantScope$1#error: Failed to instantiate Key[type=com.cloudbees.hudson.plugins.folder.config.AbstractFolderConfiguration, annotation=[none]]; skipping this component
com.google.inject.ProvisionException: Unable to provision, see the following errors:1) Tried proxying com.cloudbees.hudson.plugins.folder.config.AbstractFolderConfiguration to support a circular dependency, but it is not an interface.1 error
{{ at com.google.inject.internal.ProviderToInternalFactoryAdapter.get(ProviderToInternalFactoryAdapter.java:52)}}
{{ at com.google.inject.internal.SingletonScope$1.get(SingletonScope.java:145)}}
{{ at hudson.ExtensionFinder$GuiceFinder$FaultTolerantScope$1.get(ExtensionFinder.java:439)}}
{{ at com.google.inject.internal.InternalFactoryToProviderAdapter.get(InternalFactoryToProviderAdapter.java:41)}}
{{ at com.google.inject.internal.InjectorImpl$2$1.call(InjectorImpl.java:1016)}}
{{ at com.google.inject.internal.InjectorImpl.callInContext(InjectorImpl.java:1103)}}
{{ at com.google.inject.internal.InjectorImpl$2.get(InjectorImpl.java:1012)}}
{{ at hudson.ExtensionFinder$GuiceFinder._find(ExtensionFinder.java:401)}}
{{ at hudson.ExtensionFinder$GuiceFinder.find(ExtensionFinder.java:392)}}
{{ at hudson.ClassicPluginStrategy.findComponents(ClassicPluginStrategy.java:344)}}
{{ at hudson.ExtensionList.load(ExtensionList.java:381)}}
{{ at hudson.ExtensionList.ensureLoaded(ExtensionList.java:317)}}
{{ at hudson.ExtensionList.getComponents(ExtensionList.java:183)}}
{{ at hudson.DescriptorExtensionList.load(DescriptorExtensionList.java:193)}}
{{ at hudson.ExtensionList.ensureLoaded(ExtensionList.java:317)}}
{{ at hudson.ExtensionList.iterator(ExtensionList.java:172)}}
{{ at com.cloudbees.hudson.plugins.folder.config.AbstractFolderConfiguration.<init>(AbstractFolderConfiguration.java:36)}}
{{ at com.cloudbees.hudson.plugins.folder.config.AbstractFolderConfiguration$$FastClassByGuice$$2295d22e.newInstance(<generated>)}}
{{ at com.google.inject.internal.cglib.reflect.$FastConstructor.newInstance(FastConstructor.java:40)}}
{{ at com.google.inject.internal.DefaultConstructionProxyFactory$1.newInstance(DefaultConstructionProxyFactory.java:61)}}
{{ at com.google.inject.internal.ConstructorInjector.provision(ConstructorInjector.java:105)}}
{{ at com.google.inject.internal.ConstructorInjector.access$000(ConstructorInjector.java:32)}}
{{ at com.google.inject.internal.ConstructorInjector$1.call(ConstructorInjector.java:89)}}
{{ at com.google.inject.internal.ProvisionListenerStackCallback$Provision.provision(ProvisionListenerStackCallback.java:115)}}
{{ at hudson.ExtensionFinder$GuiceFinder$SezpozModule.onProvision(ExtensionFinder.java:567)}}
{{ at com.google.inject.internal.ProvisionListenerStackCallback$Provision.provision(ProvisionListenerStackCallback.java:126)}}
{{ at com.google.inject.internal.ProvisionListenerStackCallback.provision(ProvisionListenerStackCallback.java:68)}}
{{ at com.google.inject.internal.ConstructorInjector.construct(ConstructorInjector.java:87)}}
{{ at com.google.inject.internal.ConstructorBindingImpl$Factory.get(ConstructorBindingImpl.java:267)}}
{{ at com.google.inject.internal.ProviderToInternalFactoryAdapter$1.call(ProviderToInternalFactoryAdapter.java:46)}}
{{ at com.google.inject.internal.InjectorImpl.callInContext(InjectorImpl.java:1103)}}
{{ at com.google.inject.internal.ProviderToInternalFactoryAdapter.get(ProviderToInternalFactoryAdapter.java:40)}}
{{ at com.google.inject.internal.SingletonScope$1.get(SingletonScope.java:145)}}
{{ at hudson.ExtensionFinder$GuiceFinder$FaultTolerantScope$1.get(ExtensionFinder.java:439)}}
{{ at com.google.inject.internal.InternalFactoryToProviderAdapter.get(InternalFactoryToProviderAdapter.java:41)}}
{{ at com.google.inject.internal.InjectorImpl$2$1.call(InjectorImpl.java:1016)}}
{{ at com.google.inject.internal.InjectorImpl.callInContext(InjectorImpl.java:1092)}}
{{ at com.google.inject.internal.InjectorImpl$2.get(InjectorImpl.java:1012)}}
{{ at hudson.ExtensionFinder$GuiceFinder._find(ExtensionFinder.java:401)}}
{{ at hudson.ExtensionFinder$GuiceFinder.find(ExtensionFinder.java:392)}}
{{ at hudson.ClassicPluginStrategy.findComponents(ClassicPluginStrategy.java:344)}}
{{ at hudson.ExtensionList.load(ExtensionList.java:381)}}
{{ at hudson.ExtensionList.ensureLoaded(ExtensionList.java:317)}}
{{ at hudson.ExtensionList.getComponents(ExtensionList.java:183)}}
{{ at hudson.DescriptorExtensionList.load(DescriptorExtensionList.java:193)}}
{{ at hudson.ExtensionList.ensureLoaded(ExtensionList.java:317)}}
{{ at hudson.ExtensionList.iterator(ExtensionList.java:172)}}
{{ at java.util.Spliterators$IteratorSpliterator.estimateSize(Spliterators.java:1821)}}
{{ at java.util.Spliterator.getExactSizeIfKnown(Spliterator.java:408)}}
{{ at java.util.stream.AbstractPipeline.copyInto(AbstractPipeline.java:480)}}
{{ at java.util.stream.AbstractPipeline.wrapAndCopyInto(AbstractPipeline.java:471)}}
{{ at java.util.stream.ForEachOps$ForEachOp.evaluateSequential(ForEachOps.java:151)}}
{{ at java.util.stream.ForEachOps$ForEachOp$OfRef.evaluateSequential(ForEachOps.java:174)}}
{{ at java.util.stream.AbstractPipeline.evaluate(AbstractPipeline.java:234)}}
{{ at java.util.stream.ReferencePipeline.forEach(ReferencePipeline.java:418)}}
{{ at io.jenkins.plugins.coverage.CoverageElementInitializer.registerAllCoverageElement(CoverageElementInitializer.java:21)}}
{{ at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)}}
{{ at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)}}
{{ at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)}}
{{ at java.lang.reflect.Method.invoke(Method.java:498)}}
{{ at hudson.init.TaskMethodFinder.invoke(TaskMethodFinder.java:104)}}
{{ at hudson.init.TaskMethodFinder$TaskImpl.run(TaskMethodFinder.java:175)}}
{{ at org.jvnet.hudson.reactor.Reactor.runTask(Reactor.java:296)}}
{{ at jenkins.model.Jenkins$5.runTask(Jenkins.java:1119)}}
{{ at org.jvnet.hudson.reactor.Reactor$2.run(Reactor.java:214)}}
{{ at org.jvnet.hudson.reactor.Reactor$Node.run(Reactor.java:117)}}
{{ at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)}}
{{ at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)}}
{{ at java.lang.Thread.run(Thread.java:748)}}

 

When I downgrade to 6.9, this issue goes away.

Add Comment Add Comment
 
This message was sent by Atlassian Jira (v7.13.6#713006-sha1:cc4451f)
Atlassian logo

rob.echlin@solace.com (JIRA)

unread,
Dec 9, 2019, 11:38:02 AM12/9/19
to jenkinsc...@googlegroups.com
Rob Echlin commented on Bug JENKINS-60393
 
Re: cloudbees-folder circular dependency

My Jenkins would not start, and had this error.

I reverted all of my changed plugins, including cloudbees-folder, and I was able to start Jenkins.

I will try with just this plugin kept back to 6.9, and updating all the others, sometime soon.

rob.echlin@solace.com (JIRA)

unread,
Dec 9, 2019, 11:57:02 AM12/9/19
to jenkinsc...@googlegroups.com
Rob Echlin edited a comment on Bug JENKINS-60393
 
Re: cloudbees-folder circular dependency
My Jenkins LTS would not start, and had this error.


I reverted all of my changed plugins, including cloudbees-folder, and I was able to start Jenkins.

I will try with just this plugin kept back to 6.9, and updating all the others, sometime soon.

rob.echlin@solace.com (JIRA)

unread,
Dec 9, 2019, 1:20:07 PM12/9/19
to jenkinsc...@googlegroups.com
Rob Echlin commented on Bug JENKINS-60393
 
Re: cloudbees-folder circular dependency

I was able to catch that Jenkins server with only one job, and only a few minutes left.

When I updated all my plugins except cloudbees-folder, Jenkins restarted with no visible issues.

Looks like it really was cloudbees-folder that was blocking our server from starting.

rene.scheibe@gmail.com (JIRA)

unread,
Dec 10, 2019, 1:50:03 PM12/10/19
to jenkinsc...@googlegroups.com
René Scheibe assigned an issue to René Scheibe
Change By: René Scheibe
Assignee: Francisco Fernández René Scheibe

rene.scheibe@gmail.com (JIRA)

unread,
Dec 10, 2019, 1:50:03 PM12/10/19
to jenkinsc...@googlegroups.com
René Scheibe assigned an issue to Unassigned
Change By: René Scheibe
Assignee: René Scheibe

rene.scheibe@gmail.com (JIRA)

unread,
Dec 10, 2019, 1:52:05 PM12/10/19
to jenkinsc...@googlegroups.com
René Scheibe updated an issue
 

Seeing the following in my jenkins Jenkins log as a stacktrace :

 

{ { code}
2019-12-06 19:26:29.676+0000 [id=29] WARNING h.ExtensionFinder$GuiceFinder$FaultTolerantScope$1#error: Failed to instantiate Key[type=com.cloudbees.hudson.plugins.folder.config.AbstractFolderConfiguration, annotation=[none]]; skipping this component }}
{{ com.google.inject.ProvisionException: Unable to provision, see the following errors: }}{{ 1) Tried proxying com.cloudbees.hudson.plugins.folder.config.AbstractFolderConfiguration to support a circular dependency, but it is not an interface. }}{{ 1 error }}

{code
} }

 

{{
When I downgrade to 6.9, this issue goes away. }}

rene.scheibe@gmail.com (JIRA)

unread,
Dec 10, 2019, 1:53:02 PM12/10/19
to jenkinsc...@googlegroups.com
René Scheibe updated an issue
Seeing the following in my Jenkins log as a stacktrace :

rene.scheibe@gmail.com (JIRA)

unread,
Dec 10, 2019, 1:56:03 PM12/10/19
to jenkinsc...@googlegroups.com
René Scheibe commented on Bug JENKINS-60393
 
Re: cloudbees-folder circular dependency

Note for plugin developers: The stacktrace can simply be reproduced by running "mvn hpi:run" on the source code using the "cloudbees-folder-6.10.0" tag.

rene.scheibe@gmail.com (JIRA)

unread,
Dec 10, 2019, 2:06:02 PM12/10/19
to jenkinsc...@googlegroups.com
Note for plugin developers: The stacktrace can simply be reproduced by running "{{mvn hpi:run}}" on the source code using the "cloudbees-folder-6.10.0" tag.

 

rene.scheibe@gmail.com (JIRA)

unread,
Dec 10, 2019, 2:06:02 PM12/10/19
to jenkinsc...@googlegroups.com
René Scheibe edited a comment on Bug JENKINS-60393
Note for plugin developers: The stacktrace can simply be reproduced by running "{{mvn hpi:run}}" on the source code using the "cloudbees-folder-6.10.0" tag.

r.fuereder@xortex.com (JIRA)

unread,
Dec 11, 2019, 12:58:02 AM12/11/19
to jenkinsc...@googlegroups.com
Reinhold Füreder commented on Bug JENKINS-60393
 
Re: cloudbees-folder circular dependency

Naive question: My Jenkins server was starting up fine => is downgrading strictly necessary so that "Folder" job etc is working?

mail@nicoprediger.de (JIRA)

unread,
Dec 11, 2019, 1:30:02 AM12/11/19
to jenkinsc...@googlegroups.com
Nico Prediger commented on Bug JENKINS-60393
 
Re: cloudbees-folder circular dependency

My Jenkins instances can also start, yet when I try to create a new folder, I get an IllegalStateExcaption, which I_think_ may be caused by this error?

 

```java.lang.IllegalStateException
at com.cloudbees.hudson.plugins.folder.config.AbstractFolderConfiguration.get(AbstractFolderConfiguration.java:26)
at com.cloudbees.hudson.plugins.folder.AbstractFolder.init(AbstractFolder.java:293)
at com.cloudbees.hudson.plugins.folder.Folder.init(Folder.java:115)
at com.cloudbees.hudson.plugins.folder.Folder.<init>(Folder.java:104)
at com.cloudbees.hudson.plugins.folder.Folder$DescriptorImpl.newInstance(Folder.java:374)
at hudson.model.ItemGroupMixIn.createProject(ItemGroupMixIn.java:316)
at hudson.model.ItemGroupMixIn.createTopLevelItem(ItemGroupMixIn.java:205)
at jenkins.model.Jenkins.doCreateItem(Jenkins.java:3940)
at jenkins.model.Jenkins.doCreateItem(Jenkins.java:312)
at hudson.model.AllView.doCreateItem(AllView.java:99)
at java.lang.invoke.MethodHandle.invokeWithArguments(MethodHandle.java:627)
at org.kohsuke.stapler.Function$MethodFunction.invoke(Function.java:396)
at org.kohsuke.stapler.Function$InstanceFunction.invoke(Function.java:408)
at org.kohsuke.stapler.interceptor.RequirePOST$Processor.invoke(RequirePOST.java:77)
at org.kohsuke.stapler.PreInvokeInterceptedFunction.invoke(PreInvokeInterceptedFunction.java:26)
at org.kohsuke.stapler.Function.bindAndInvoke(Function.java:212)
at org.kohsuke.stapler.Function.bindAndInvokeAndServeResponse(Function.java:145)
at org.kohsuke.stapler.MetaClass$11.doDispatch(MetaClass.java:535)
at org.kohsuke.stapler.NameBasedDispatcher.dispatch(NameBasedDispatcher.java:58)
at org.kohsuke.stapler.Stapler.tryInvoke(Stapler.java:747)
Caused: javax.servlet.ServletException
at org.kohsuke.stapler.Stapler.tryInvoke(Stapler.java:797)

[...]

```

fjfernandez@cloudbees.com (JIRA)

unread,
Dec 11, 2019, 7:03:04 AM12/11/19
to jenkinsc...@googlegroups.com

fjfernandez@cloudbees.com (JIRA)

unread,
Dec 11, 2019, 7:04:03 AM12/11/19
to jenkinsc...@googlegroups.com
Francisco Fernández commented on Bug JENKINS-60393
 
Re: cloudbees-folder circular dependency

Hi Allan BURDAJEWICZ,

 

https://github.com/jenkinsci/cloudbees-folder-plugin/pull/129 is causing a regression. Could you please have a look at it?

 

Thanks in advance!

aburdajewicz@cloudbees.com (JIRA)

unread,
Dec 11, 2019, 7:35:03 PM12/11/19
to jenkinsc...@googlegroups.com
Allan BURDAJEWICZ started work on Bug JENKINS-60393
 
Change By: Allan BURDAJEWICZ
Status: Open In Progress

aburdajewicz@cloudbees.com (JIRA)

unread,
Dec 11, 2019, 10:07:03 PM12/11/19
to jenkinsc...@googlegroups.com

aburdajewicz@cloudbees.com (JIRA)

unread,
Dec 11, 2019, 10:53:02 PM12/11/19
to jenkinsc...@googlegroups.com
Allan BURDAJEWICZ updated an issue
Change By: Allan BURDAJEWICZ
Attachment: com.cloudbees.hudson.plugins.folder.config.AbstractFolderConfiguration.xml

aburdajewicz@cloudbees.com (JIRA)

unread,
Dec 11, 2019, 10:55:04 PM12/11/19
to jenkinsc...@googlegroups.com
 
Re: cloudbees-folder circular dependency

I can reproduce the problem when plugins like xunit and code-coverage-api are installed. I think because they use some initializer that happen before the folder global configuration is loaded:

It does not prevent Jenkins to start in the scenario I tested and a way to workaround that problem if Jenkins starts is to go to *Manage Jenkins > Configure System* (check that there is a section named "Folder") and save. Otherwise, another workaround is to ensure that there is already a global configuration: add the file com.cloudbees.hudson.plugins.folder.config.AbstractFolderConfiguration.xml to $JENKINS_HOME/ and restart Jenkins.

aburdajewicz@cloudbees.com (JIRA)

unread,
Dec 11, 2019, 10:56:04 PM12/11/19
to jenkinsc...@googlegroups.com

aburdajewicz@cloudbees.com (JIRA)

unread,
Dec 11, 2019, 10:56:04 PM12/11/19
to jenkinsc...@googlegroups.com
I can reproduce the problem when plugins like {{xunit}} and {{code-coverage-api}} are installed. I think because they use some initializer that happen before the folder global configuration is loaded:

* https://github.com/jenkinsci/xunit-plugin/blob/xunit-2.3.7/src/main/java/org/jenkinsci/plugins/xunit/AliasInitializer.java#L42
* https://github.com/jenkinsci/code-coverage-api-plugin/blob/code-coverage-api-1.1.1/src/main/java/io/jenkins/plugins/coverage/CoverageElementInitializer.java#L12

It does not prevent Jenkins to start in the scenario I tested and a way to workaround that problem if Jenkins starts is to go to *
* Manage Jenkins > Configure System* * (check that there is a section named "Folder") and save. Otherwise, another workaround is to ensure that there is already a global configuration: add the file  [^com.cloudbees.hudson.plugins.folder.config.AbstractFolderConfiguration.xml] to {{$JENKINS_HOME/}} and restart Jenkins.

rob.echlin@solace.com (JIRA)

unread,
Dec 13, 2019, 10:18:06 AM12/13/19
to jenkinsc...@googlegroups.com
Rob Echlin updated an issue
Change By: Rob Echlin
Attachment: plugins-list.txt

rob.echlin@solace.com (JIRA)

unread,
Dec 13, 2019, 10:22:03 AM12/13/19
to jenkinsc...@googlegroups.com
Rob Echlin commented on Bug JENKINS-60393
 
Re: cloudbees-folder circular dependency

Sorry, I have been off sick for three days.
I see you were not able to reproduce my problem with Jenkins starting.

I have attached a list of plugins, obtained as a list of all the jpi files in my plugins folder.

Is there a better way to get a list of plugins, as a text file?

Thanks for your fast work on this ticket!

mark.earl.waite@gmail.com (JIRA)

unread,
Dec 14, 2019, 6:14:04 PM12/14/19
to jenkinsc...@googlegroups.com
Mark Waite commented on Bug JENKINS-60393
 
Re: cloudbees-folder circular dependency

My startup is not blocked, but I can definitely see the error in the log consistently with the cloudbees folder plugin 6.10.0 as represented in the 291e29a264 commit on the lts-plugins branch of my docker-lfs repository.

Steps to duplicate the problem using that repository:

  1. Clone the docker image repository with the commands:
    $ git clone -o public -b lts-with-plugins https://github.com/MarkEWaite/docker-lfs.git
    $ cd docker-lfs
    $ git remote add upstream https://github.com/jenkinsci/docker.git
    $ git pull --all
    $ git checkout -b lts -t public/lts
    $ git checkout lts-with-plugins
    $ ./docker_build.py
    $ ./docker_run.py --clean --quiet
    
  2. Connect to the URL of that server (port 8080 on current host)
  3. Install CloudBees Folder plugin 6.10.0
  4. Restart Jenkins, watch for the stack trace message

fjfernandez@cloudbees.com (JIRA)

unread,
Dec 16, 2019, 11:48:04 AM12/16/19
to jenkinsc...@googlegroups.com
Francisco Fernández commented on Bug JENKINS-60393
 
Re: cloudbees-folder circular dependency

cloudbees-folder-6.10.1 is out and it should fix the issue. Could you please check?

fjfernandez@cloudbees.com (JIRA)

unread,
Dec 16, 2019, 11:48:07 AM12/16/19
to jenkinsc...@googlegroups.com
Change By: Francisco Fernández
Status: In Review Resolved
Resolution: Fixed
Released As: cloudbees-folder-6.10.1

mark.earl.waite@gmail.com (JIRA)

unread,
Dec 16, 2019, 12:32:04 PM12/16/19
to jenkinsc...@googlegroups.com
Mark Waite commented on Bug JENKINS-60393
 
Re: cloudbees-folder circular dependency

Francisco Fernández I installed 6.10.1 on my instance and do not see any messages about circular dependencies. Fixed. Thanks!

rene.scheibe@gmail.com (JIRA)

unread,
Dec 16, 2019, 1:48:04 PM12/16/19
to jenkinsc...@googlegroups.com

fjfernandez@cloudbees.com (JIRA)

unread,
Dec 17, 2019, 2:28:03 AM12/17/19
to jenkinsc...@googlegroups.com
Reply all
Reply to author
Forward
0 new messages