[TIME-277] timesheet plugin rest servlet error 404 , log reports "Bundle is uninstalled"

Issue #277 resolved
Andriy Zhdanov created an issue

Hi. We installed your time sheet plugin on our company internal Jira server, with the intent to use the REST interface after successful evaluation.

Some of our business partners already use this plugin successfully. To my knowledge, anything but a 404 error to the rest interface should indicate the interface is working correctly.

However, access to the rest interface only and reproducibly leads to the following result:

GET /rest/timesheet-gadget/1.0/raw-timesheet.json HTTP/1.1
...
HTTP/1.1 404 Not Found
Server: Apache-Coyote/1.1
X-AREQUESTID: 793x36413x1
Set-Cookie: atlassian.xsrf.token=BS71-14NM-DBLA-Q6TW|58b1facaae728ded021811b07bb07005d7459df8|lout; Path=/
X-AUSERNAME: anonymous
Cache-Control: no-transform
Content-Type: application/json;charset=UTF-8
Transfer-Encoding: chunked
Date: Wed, 22 Aug 2012 11:13:42 GMT

13

{"status-code":404}

0

the same string {"status-code":404} is displayed when browsing to that URL while logged in in Jira as Administrator
the result header changes to:

Cache-Control:no-transform
Content-Type:application/json;charset=UTF-8
Server:Apache-Coyote/1.1
Transfer-Encoding:chunked
X-AREQUESTID:796x36546x1
X-ASESSIONID:1gezr0j
X-AUSERNAME:admin
X-Seraph-LoginReason:OK

in both cases I get the same error in the jira log file:

2012-08-22 13:19:10,519 http-80-33 ERROR anonymous 799x36857x1 1gezr0j <X.X.X.X> /rest/timesheet-gadget/1.0/raw-timesheet.json [atlassian.plugin.servlet.DefaultServletModule
Manager] Unable to create filter
com.atlassian.util.concurrent.LazyReference$InitializationException: java.lang.IllegalStateException: Bundle is uninstalled
at com.atlassian.util.concurrent.LazyReference.getInterruptibly(LazyReference.java:152)
at com.atlassian.util.concurrent.LazyReference.get(LazyReference.java:115)
at com.atlassian.plugin.servlet.DefaultServletModuleManager.getFilter(DefaultServletModuleManager.java:358)
at com.atlassian.plugin.servlet.DefaultServletModuleManager.getFilters(DefaultServletModuleManager.java:212)
at com.atlassian.plugin.servlet.filter.ServletFilterModuleContainerFilter.doFilter(ServletFilterModuleContainerFilter.java:75)
at com.atlassian.plugin.servlet.filter.ServletFilterModuleContainerFilter.doFilter(ServletFilterModuleContainerFilter.java:63)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
at com.atlassian.jira.web.filters.steps.ChainedFilterStepRunner.doFilter(ChainedFilterStepRunner.java:78)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
at com.atlassian.core.filters.cache.AbstractCachingFilter.doFilter(AbstractCachingFilter.java:33)
at com.atlassian.core.filters.AbstractHttpFilter.doFilter(AbstractHttpFilter.java:31)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
at com.atlassian.core.filters.encoding.AbstractEncodingFilter.doFilter(AbstractEncodingFilter.java:41)
at com.atlassian.core.filters.AbstractHttpFilter.doFilter(AbstractHttpFilter.java:31)
at com.atlassian.jira.web.filters.PathMatchingEncodingFilter.doFilter(PathMatchingEncodingFilter.java:45)
at com.atlassian.core.filters.AbstractHttpFilter.doFilter(AbstractHttpFilter.java:31)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
at com.atlassian.jira.web.monitor.ActiveRequestsFilter$PassToChainFilterFunc.doFilter(ActiveRequestsFilter.java:346)
at com.atlassian.jira.web.monitor.ActiveRequestsFilter$DebugLogFilterFunc.doFilter(ActiveRequestsFilter.java:463)
at com.atlassian.jira.web.monitor.ActiveRequestsFilter.doFilter(ActiveRequestsFilter.java:173)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
at com.atlassian.jira.startup.JiraStartupChecklistFilter.doFilter(JiraStartupChecklistFilter.java:75)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
at com.atlassian.multitenant.servlet.MultiTenantServletFilter.doFilter(MultiTenantServletFilter.java:91)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
at com.atlassian.jira.web.filters.steps.ChainedFilterStepRunner.doFilter(ChainedFilterStepRunner.java:78)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:233)
at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:191)
at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:127)
at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:102)
at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)
at org.apache.catalina.valves.AccessLogValve.invoke(AccessLogValve.java:554)
at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:298)
at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:859)
at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:588)
at org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:489)
at java.lang.Thread.run(Unknown Source)
Caused by: java.lang.IllegalStateException: Bundle is uninstalled
at org.apache.felix.framework.Felix.loadBundleClass(Felix.java:1574)
at org.apache.felix.framework.BundleImpl.loadClass(BundleImpl.java:887)
at com.atlassian.plugin.osgi.util.BundleClassLoaderAccessor.loadClass(BundleClassLoaderAccessor.java:46)
at com.atlassian.plugin.osgi.factory.OsgiPluginInstalledHelper.loadClass(OsgiPluginInstalledHelper.java:63)
at com.atlassian.plugin.osgi.factory.OsgiPlugin.loadClass(OsgiPlugin.java:165)
at com.atlassian.plugin.module.ClassPrefixModuleFactory.getModuleClass(ClassPrefixModuleFactory.java:45)
at com.atlassian.plugin.module.ClassPrefixModuleFactory.createModule(ClassPrefixModuleFactory.java:27)
at com.atlassian.plugin.module.PrefixDelegatingModuleFactory.createModule(PrefixDelegatingModuleFactory.java:99)
at com.atlassian.plugin.servlet.descriptors.ServletFilterModuleDescriptor.getModule(ServletFilterModuleDescriptor.java:139)
at com.atlassian.plugin.servlet.filter.DelegatingPluginFilter.<init>(DelegatingPluginFilter.java:35)
at com.atlassian.plugin.servlet.DefaultServletModuleManager$LazyLoadedFilterReference.create(DefaultServletModuleManager.java:410)
at com.atlassian.plugin.servlet.DefaultServletModuleManager$LazyLoadedFilterReference.create(DefaultServletModuleManager.java:396)
at com.atlassian.util.concurrent.LazyReference$Sync.run(LazyReference.java:326)
at com.atlassian.util.concurrent.LazyReference.getInterruptibly(LazyReference.java:146)
... 45 more

(in case of anonymous logins the error starts with:
2012-08-22 13:20:11,978 http-80-33 ERROR anonymous 800x36858x1 - <X.X.X.X> /rest/timesheet-gadget/1.0/raw-timesheet.json atlassian.plugin.servlet.DefaultServletModuleManager Unable to create filter
com.atlassian.util.concurrent.LazyReference$InitializationException: java.lang.IllegalStateException: Bundle is uninstalled
... the rest is the same

Could you confirm whether this is a bug in the Time Sheet Plugin or maybe an incompatibility with certain Jira versions?

Could you provide additional information about the possible causes for this issue?

After searching for possible causes of Jira "Bundle is uninstalled" errors, we already double checked that all subcomponents of the Time Sheet Plugin are correctly enabled. They are, and so are all Jira system modules. Are there any additional unmentioned dependencies that could be broken?

By lightwerk/Lightwerk on Wed, 22 Aug 2012 04:30:45 -0700

Comments (8)

  1. Andriy Zhdanov reporter

    Hi,

    Looks like you performed great diagnosis, I'd like to double check the following:

    1) Are other plugin assets usable? E.g. Timesheet gadget on dashboard or Timesheet report

    2) Even though all plugin components are enabled, could you please try to reinstall plugin or re-enable (i.e. disable and then enable again), and see if there are any errors in jira log before you access raw-timesheet?

    3) I guess it worked during evaluation on other jira instance, does it still work there?

    Other than that your analysis and details are perfect and clear and everything looks correct.

    Thank you.

    By azhdanov on Wed, 22 Aug 2012 12:27:24 -0700

  2. Andriy Zhdanov reporter

    Thanks for your quick reply.

    1.) Other assets are usable.
    2.) reenable the plugin changed nothing on the current situation .
    The only error in the log is the "bundle not found exception" mentionet in the first post
    3.) We only have one jira-instance

    Greetings and thank you

    By lightwerk on Thu, 23 Aug 2012 07:44:01 -0700

  3. Andriy Zhdanov reporter

    Weird.. and what about this url: rest/timesheet-gadget/1.0/timesheet.json - does it work?

    By azhdanov on Thu, 23 Aug 2012 13:25:47 -0700

  4. Andriy Zhdanov reporter

    This call seems working

    {"html":"<style type=\"text/css\">\r\n .rowHeader {\r\n background-color:#E2E2E2;\r\n }\r\n .rowAlternate {\r\n
    ....

    By lightwerk on Thu, 23 Aug 2012 22:19:40 -0700

  5. Andriy Zhdanov reporter

    Strange, raw resource does not have much difference, it's a bit simplified from one hand, and just uses more JAXB from other hand.
    If in previous attempt you did not try to re-install plugin (instead of re-enable), please try it. Even though it sounds stupid, as you've just installed it.
    Also it could be useful to double check there is no other version of plugin installed. It should be enough to check there is just jira/home/plugins/installed-plugins/jira-timesheet-plugin-2.3.5.jar and no other versions.
    If nothing helps, I can suggest to setup another (trial) instance of jira and plugin, and see if it works there. Also I guess if I provide a working example it won't help.
    Or pack your jira webapp, not home, and just home/plugins, and send it to me, via dropbox for example. I must be safe, no your data will be passed.

    By azhdanov on Fri, 24 Aug 2012 12:12:16 -0700

  6. Log in to comment