Details
-
Bug
-
Resolution: Timed out
-
Low
-
None
-
4.4.3
-
4.04
-
Severity 3 - Minor
-
-
Description
In our plugin, I have an additional JIRA top navigation bar menu with a dynamically generated section (like in the Issues dropdown), implemented via <simple-link-factory> plugin module. The problem is that if I disable the plugin, and then enable it again, the factory no longer works. The only workaround is to reinstall the plugin or restart JIRA.
The important observation is that when the plugin is Enabled and then the drop-down link is clicked, the constructor of StructureBoardLinkFactory (our instance of SimpleLinkFactory) is not getting called – therefore, the old instance of the module with stale references to all other components is used.
(First posted as a question here: https://answers.atlassian.com/questions/26118 - assuming this is really a bug)
Having an old instance with bad links leads to the exceptions like this:
[WARNING] [talledLocalContainer] SEVERE: Internal server error [WARNING] [talledLocalContainer] org.springframework.osgi.service.importer.ServiceProxyDestroyedException: service proxy has been destroyed [WARNING] [talledLocalContainer] at org.springframework.osgi.service.importer.support.internal.aop.ServiceDynamicInterceptor$ServiceLookUpCallback.doWithRetry(ServiceDynamicInterceptor.java:105) [WARNING] [talledLocalContainer] at org.springframework.osgi.service.importer.support.internal.support.RetryTemplate.execute(RetryTemplate.java:83) [WARNING] [talledLocalContainer] at org.springframework.osgi.service.importer.support.internal.aop.ServiceDynamicInterceptor.lookupService(ServiceDynamicInterceptor.java:430) [WARNING] [talledLocalContainer] at org.springframework.osgi.service.importer.support.internal.aop.ServiceDynamicInterceptor.getTarget(ServiceDynamicInterceptor.java:415) [WARNING] [talledLocalContainer] at org.springframework.osgi.service.importer.support.internal.aop.ServiceInvoker.invoke(ServiceInvoker.java:62) [WARNING] [talledLocalContainer] at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:171) [WARNING] [talledLocalContainer] at org.springframework.aop.support.DelegatingIntroductionInterceptor.doProceed(DelegatingIntroductionInterceptor.java:131) [WARNING] [talledLocalContainer] at org.springframework.aop.support.DelegatingIntroductionInterceptor.invoke(DelegatingIntroductionInterceptor.java:119) [WARNING] [talledLocalContainer] at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:171) [WARNING] [talledLocalContainer] at org.springframework.osgi.service.util.internal.aop.ServiceTCCLInterceptor.invokeUnprivileged(ServiceTCCLInterceptor.java:56) [WARNING] [talledLocalContainer] at org.springframework.osgi.service.util.internal.aop.ServiceTCCLInterceptor.invoke(ServiceTCCLInterceptor.java:39) [WARNING] [talledLocalContainer] at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:171) [WARNING] [talledLocalContainer] at org.springframework.osgi.service.importer.support.LocalBundleContextAdvice.invoke(LocalBundleContextAdvice.java:59) [WARNING] [talledLocalContainer] at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:171) [WARNING] [talledLocalContainer] at org.springframework.aop.support.DelegatingIntroductionInterceptor.doProceed(DelegatingIntroductionInterceptor.java:131) [WARNING] [talledLocalContainer] at org.springframework.aop.support.DelegatingIntroductionInterceptor.invoke(DelegatingIntroductionInterceptor.java:119) [WARNING] [talledLocalContainer] at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:171) [WARNING] [talledLocalContainer] at org.springframework.aop.framework.JdkDynamicAopProxy.invoke(JdkDynamicAopProxy.java:204) [WARNING] [talledLocalContainer] at $Proxy1354.hasPermission(Unknown Source) [WARNING] [talledLocalContainer] at com.almworks.jira.structure.services.StructurePluginHelper.isAdmin(StructurePluginHelper.java:259) [WARNING] [talledLocalContainer] at com.almworks.jira.structure.services.BackendBasedStructureManager.getPermission0(BackendBasedStructureManager.java:248) [WARNING] [talledLocalContainer] at com.almworks.jira.structure.services.BackendBasedStructureManager.getStructurePermission(BackendBasedStructureManager.java:232) [WARNING] [talledLocalContainer] at com.almworks.jira.structure.services.BackendBasedStructureManager.isAccessible(BackendBasedStructureManager.java:895) [WARNING] [talledLocalContainer] at com.almworks.jira.structure.services.BackendBasedStructureManager.getStructure(BackendBasedStructureManager.java:161) [WARNING] [talledLocalContainer] at com.almworks.jira.structure.web.StructureBoardOpenParams.toDisplayString(StructureBoardOpenParams.java:70) [WARNING] [talledLocalContainer] at com.almworks.jira.structure.web.StructureBoardLinkFactory.createLink(StructureBoardLinkFactory.java:88) [WARNING] [talledLocalContainer] at com.almworks.jira.structure.web.StructureBoardLinkFactory.addLink(StructureBoardLinkFactory.java:82) [WARNING] [talledLocalContainer] at com.almworks.jira.structure.web.StructureBoardLinkFactory.addFromCookie(StructureBoardLinkFactory.java:74) [WARNING] [talledLocalContainer] at com.almworks.jira.structure.web.StructureBoardLinkFactory.getLinks0(StructureBoardLinkFactory.java:51) [WARNING] [talledLocalContainer] at com.almworks.jira.structure.web.StructureBoardLinkFactory.getLinks(StructureBoardLinkFactory.java:39) [WARNING] [talledLocalContainer] at com.atlassian.jira.plugin.webfragment.DefaultSimpleLinkManager.getLinks(DefaultSimpleLinkManager.java:207)