Stash Webhook to Jenkins add-on failed to enable
Platform notice: Server and Data Center only. This article only applies to Atlassian products on the Server and Data Center platforms.
Support for Server* products ended on February 15th 2024. If you are running a Server product, you can visit the Atlassian Server end of support announcement to review your migration options.
*Except Fisheye and Crucible
Problem
Stash Webhook to Jenkins add-on failed to enable
The following appears in the atlassian-stash.log:
015-10-27 00:55:31,181 ERROR [UpmAsynchronousTaskManager:thread-2] Anand.Joshi @1PY5B7Gx54x12125916x0 1mimkel 10.253.168.181,10.253.168.181 "POST /rest/plugins/1.0/ HTTP/1.1" c.a.u.c.r.r.i.InstallFromUriTask Error downloading plugin from https://marketplace.atlassian.com/download/plugins/com.nerdwin15.stash-stash-webhook-jenkins/version/162
2015-10-27 00:57:15,993 ERROR [ThreadPoolAsyncTaskExecutor::Thread 48] Anand.Joshi @1PY5B7Gx57x12126317x1 1mimkel 10.253.168.154,10.253.168.154 "POST /rest/plugins/1.0/ HTTP/1.1" c.a.plugin.osgi.factory.OsgiPlugin Unable to start the plugin container for plugin 'com.nerdwin15.stash-stash-webhook-jenkins'
java.lang.NoClassDefFoundError: org/apache/http/conn/scheme/SchemeSocketFactory
at java.lang.Class.getDeclaredConstructors0(Native Method) ~[na:1.7.0_67]
at java.lang.Class.privateGetDeclaredConstructors(Class.java:2532) ~[na:1.7.0_67]
at java.lang.Class.getConstructors(Class.java:1517) ~[na:1.7.0_67]
at java.security.AccessController.doPrivileged(Native Method) ~[na:1.7.0_67]
at java.security.AccessController.doPrivileged(Native Method) ~[na:1.7.0_67]
at java.security.AccessController.doPrivileged(Native Method) ~[na:1.7.0_67]
at org.springframework.context.support.AbstractApplicationContext.finishBeanFactoryInitialization(AbstractApplicationContext.java:728) ~[spring-context-4.0.5.RELEASE.jar:4.0.5.RELEASE]
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145) ~[na:1.7.0_67]
at java.lang.Thread.run(Thread.java:745) ~[na:1.7.0_67]
... 47 frames trimmed
Caused by: java.lang.ClassNotFoundException: org.apache.http.conn.scheme.SchemeSocketFactory not found by org.apache.httpcomponents.httpclient [14]
at org.apache.felix.framework.ModuleImpl.findClassOrResourceByDelegation(ModuleImpl.java:787) ~[org.apache.felix.framework-3.0.9.jar:na]
... 10 common frames omitted
2015-10-27 00:57:16,010 ERROR [ThreadPoolAsyncTaskExecutor::Thread 48] Anand.Joshi @1PY5B7Gx57x12126317x1 1mimkel 10.253.168.154,10.253.168.154 "POST /rest/plugins/1.0/ HTTP/1.1" c.a.plugin.osgi.factory.OsgiPlugin Unable to start the plugin container for plugin 'com.nerdwin15.stash-stash-webhook-jenkins'
java.lang.NoClassDefFoundError: org/apache/http/conn/scheme/SchemeSocketFactory
at java.lang.Class.getDeclaredConstructors0(Native Method) ~[na:1.7.0_67]
at java.lang.Class.privateGetDeclaredConstructors(Class.java:2532) ~[na:1.7.0_67]
at java.lang.Class.getConstructors(Class.java:1517) ~[na:1.7.0_67]
at java.security.AccessController.doPrivileged(Native Method) ~[na:1.7.0_67]
at java.security.AccessController.doPrivileged(Native Method) ~[na:1.7.0_67]
at java.security.AccessController.doPrivileged(Native Method) ~[na:1.7.0_67]
at org.springframework.context.support.AbstractApplicationContext.finishBeanFactoryInitialization(AbstractApplicationContext.java:728) ~[spring-context-4.0.5.RELEASE.jar:4.0.5.RELEASE]
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145) ~[na:1.7.0_67]
at java.lang.Thread.run(Thread.java:745) ~[na:1.7.0_67]
... 47 frames trimmed
Caused by: java.lang.ClassNotFoundException: org.apache.http.conn.scheme.SchemeSocketFactory not found by org.apache.httpcomponents.httpclient [14]
at org.apache.felix.framework.ModuleImpl.findClassOrResourceByDelegation(ModuleImpl.java:787) ~[org.apache.felix.framework-3.0.9.jar:na]
Cause
This bug seems to have been introduced on the 2.7.0 and 2.7.1 releases of this plugin as described on Nerdwin15's bug report.
Workaround
If you installed the plugin version 2.7.1 or 2.7.0, please roll back to version 2.6.0.
Resolution
For a final resolution, please follow up the bug report on the vendor's website.