Uploaded image for project: 'Nuxeo Platform'
  1. Nuxeo Platform
  2. NXP-17472

Fix error management on unknown runtime extension point

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Resolved
    • Priority: Minor
    • Resolution: Fixed
    • Affects Version/s: 7.3
    • Fix Version/s: 7.4
    • Component/s: Runtime
    • Tags:
    • Sprint:
      nxNag Sprint 7.3.7

      Description

      When the extension point is not defined, there are spurious "null" error logs:

      2015-07-09 12:02:13,666 ERROR [localhost-startStop-1] [org.nuxeo.runtime.api.Framework] null
      2015-07-09 12:02:13,666 ERROR [localhost-startStop-1] [org.nuxeo.runtime.model.impl.ComponentInstanceImpl] Warning: target extension point 'views' of 'org.nuxeo.theme.services.ThemeService' is unknown. Check your extension in component service:org.nuxeo.ecm.user.center.oauth.themes
      2015-07-09 12:02:13,666 ERROR [localhost-startStop-1] [org.nuxeo.runtime.api.Framework] null
      2015-07-09 12:02:13,666 ERROR [localhost-startStop-1] [org.nuxeo.runtime.model.impl.ComponentInstanceImpl] Warning: target extension point 'views' of 'org.nuxeo.theme.services.ThemeService' is unknown. Check your extension in component service:org.nuxeo.ecm.user.center.oauth.themes
      2015-07-09 12:02:13,666 ERROR [localhost-startStop-1] [org.nuxeo.runtime.api.Framework] null
      

      Also, there is a stackoverflow, stopping the runtime startup:

      2015-07-09 12:21:29,665 ERROR [localhost-startStop-1] [org.nuxeo.runtime.model.impl.ComponentInstanceImpl] Warning: target extension point 'views' of '
      org.nuxeo.theme.services.ThemeService' is unknown. Check your extension in component service:org.nuxeo.ecm.user.center.oauth.themes
      2015-07-09 12:21:29,866 ERROR [localhost-startStop-1] [org.apache.catalina.core.ContainerBase.[Catalina].[localhost].[/nuxeo]] Exception sending contex
      t initialized event to listener instance of class org.nuxeo.runtime.deployment.NuxeoStarter
      java.lang.StackOverflowError
              at org.nuxeo.runtime.model.impl.ComponentInstanceImpl.registerExtension(ComponentInstanceImpl.java:217)
              at sun.reflect.GeneratedMethodAccessor44.invoke(Unknown Source)
              at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
              at java.lang.reflect.Method.invoke(Method.java:497)
              at org.nuxeo.runtime.model.impl.ComponentInstanceImpl.registerExtension(ComponentInstanceImpl.java:213)
              at sun.reflect.GeneratedMethodAccessor44.invoke(Unknown Source)
              at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
              at java.lang.reflect.Method.invoke(Method.java:497)
              at org.nuxeo.runtime.model.impl.ComponentInstanceImpl.registerExtension(ComponentInstanceImpl.java:213)
              at sun.reflect.GeneratedMethodAccessor44.invoke(Unknown Source)
              at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
              at java.lang.reflect.Method.invoke(Method.java:497)
              at org.nuxeo.runtime.model.impl.ComponentInstanceImpl.registerExtension(ComponentInstanceImpl.java:213)
              at sun.reflect.GeneratedMethodAccessor44.invoke(Unknown Source)
              at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
              at java.lang.reflect.Method.invoke(Method.java:497)
              at org.nuxeo.runtime.model.impl.ComponentInstanceImpl.registerExtension(ComponentInstanceImpl.java:213)
              at sun.reflect.GeneratedMethodAccessor44.invoke(Unknown Source)
              at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
      

      Stack overflow can also happen at unregister, when component and instance are the same:

      2015-07-09 17:04:03,556 ERROR [localhost-startStop-2] [org.nuxeo.runtime.tomcat.NuxeoLauncher] Failed to handle event: stop
      java.lang.reflect.InvocationTargetException
      	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:497)
      	at org.nuxeo.osgi.application.FrameworkBootstrap.stop(FrameworkBootstrap.java:136)
      	at org.nuxeo.runtime.tomcat.NuxeoLauncher.handleEvent(NuxeoLauncher.java:117)
      	at org.nuxeo.runtime.tomcat.NuxeoLauncher.lifecycleEvent(NuxeoLauncher.java:90)
      	at org.apache.catalina.util.LifecycleSupport.fireLifecycleEvent(LifecycleSupport.java:117)
      	at org.apache.catalina.util.LifecycleBase.fireLifecycleEvent(LifecycleBase.java:90)
      	at org.apache.catalina.util.LifecycleBase.setStateInternal(LifecycleBase.java:402)
      	at org.apache.catalina.util.LifecycleBase.setState(LifecycleBase.java:347)
      	at org.apache.catalina.core.StandardContext.stopInternal(StandardContext.java:5659)
      	at org.apache.catalina.util.LifecycleBase.stop(LifecycleBase.java:232)
      	at org.apache.catalina.core.ContainerBase$StopChild.call(ContainerBase.java:1591)
      	at org.apache.catalina.core.ContainerBase$StopChild.call(ContainerBase.java:1580)
      	at java.util.concurrent.FutureTask.run(FutureTask.java:266)
      	at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
      	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
      	at java.lang.Thread.run(Thread.java:745)
      Caused by: java.lang.StackOverflowError
      	at org.nuxeo.runtime.model.impl.ComponentInstanceImpl.unregisterExtension(ComponentInstanceImpl.java:237)
      	at sun.reflect.GeneratedMethodAccessor1517.invoke(Unknown Source)
      	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
      	at java.lang.reflect.Method.invoke(Method.java:497)
      	at org.nuxeo.runtime.model.impl.ComponentInstanceImpl.unregisterExtension(ComponentInstanceImpl.java:234)
      	at sun.reflect.GeneratedMethodAccessor1517.invoke(Unknown Source)
      	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
      [...]
      	at org.nuxeo.runtime.model.impl.ComponentInstanceImpl.unregisterExtension(ComponentInstanceImpl.java:234)
      	at sun.reflect.GeneratedMethodAccessor1517.invoke(Unknown Source)
      	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
      	at java.lang.reflect.Method.invoke(Method.java:497)
      2015-07-09 17:04:03,605 ERROR [localhost-startStop-2] [org.nuxeo.osgi.BundleRegistry] Failed to stop bundle org.nuxeo.ecm.platform.ui
      org.osgi.framework.BundleException: Failed to stop activator: org.nuxeo.ecm.platform.ui.web.UIWebActivator
      	at org.nuxeo.osgi.BundleImpl.shutdown(BundleImpl.java:327)
      	at org.nuxeo.osgi.BundleRegistry.shutdown(BundleRegistry.java:209)
      	at org.nuxeo.osgi.OSGiAdapter.shutdown(OSGiAdapter.java:154)
      	at org.nuxeo.osgi.application.loader.FrameworkLoader.doStop(FrameworkLoader.java:253)
      	at org.nuxeo.osgi.application.loader.FrameworkLoader.stop(FrameworkLoader.java:140)
      	at org.nuxeo.runtime.deployment.NuxeoStarter.stop(NuxeoStarter.java:122)
      	at org.nuxeo.runtime.deployment.NuxeoStarter.contextDestroyed(NuxeoStarter.java:104)
      	at org.apache.catalina.core.StandardContext.listenerStop(StandardContext.java:5035)
      	at org.apache.catalina.core.StandardContext.stopInternal(StandardContext.java:5687)
      	at org.apache.catalina.util.LifecycleBase.stop(LifecycleBase.java:232)
      	at org.apache.catalina.core.ContainerBase$StopChild.call(ContainerBase.java:1591)
      	at org.apache.catalina.core.ContainerBase$StopChild.call(ContainerBase.java:1580)
      	at java.util.concurrent.FutureTask.run(FutureTask.java:266)
      	at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
      	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
      	at java.lang.Thread.run(Thread.java:745)
      Caused by: java.lang.NullPointerException
      	at org.nuxeo.ecm.platform.ui.web.util.beans.PropertiesEditorsInstaller.uninstallEditor(PropertiesEditorsInstaller.java:46)
      	at org.nuxeo.ecm.platform.ui.web.util.beans.PropertiesEditorsInstaller.uninstallEditors(PropertiesEditorsInstaller.java:34)
      	at org.nuxeo.ecm.platform.ui.web.UIWebActivator.stop(UIWebActivator.java:36)
      	at org.nuxeo.osgi.BundleImpl.shutdown(BundleImpl.java:320)
      	... 15 more
      2015-07-09 17:04:03,606 ERROR [localhost-startStop-2] [org.nuxeo.osgi.BundleRegistry] Failed to stop bundle org.nuxeo.runtime
      org.osgi.framework.BundleException: Failed to stop activator: org.nuxeo.runtime.osgi.OSGiRuntimeActivator
      	at org.nuxeo.osgi.BundleImpl.shutdown(BundleImpl.java:327)
      	at org.nuxeo.osgi.BundleRegistry.shutdown(BundleRegistry.java:209)
      	at org.nuxeo.osgi.OSGiAdapter.shutdown(OSGiAdapter.java:154)
      	at org.nuxeo.osgi.application.loader.FrameworkLoader.doStop(FrameworkLoader.java:253)
      	at org.nuxeo.osgi.application.loader.FrameworkLoader.stop(FrameworkLoader.java:140)
      	at org.nuxeo.runtime.deployment.NuxeoStarter.stop(NuxeoStarter.java:122)
      	at org.nuxeo.runtime.deployment.NuxeoStarter.contextDestroyed(NuxeoStarter.java:104)
      	at org.apache.catalina.core.StandardContext.listenerStop(StandardContext.java:5035)
      	at org.apache.catalina.core.StandardContext.stopInternal(StandardContext.java:5687)
      	at org.apache.catalina.util.LifecycleBase.stop(LifecycleBase.java:232)
      	at org.apache.catalina.core.ContainerBase$StopChild.call(ContainerBase.java:1591)
      	at org.apache.catalina.core.ContainerBase$StopChild.call(ContainerBase.java:1580)
      	at java.util.concurrent.FutureTask.run(FutureTask.java:266)
      	at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
      	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
      	at java.lang.Thread.run(Thread.java:745)
      Caused by: java.lang.NullPointerException
      	at org.nuxeo.runtime.osgi.OSGiRuntimeActivator.stop(OSGiRuntimeActivator.java:88)
      	at org.nuxeo.osgi.BundleImpl.shutdown(BundleImpl.java:320)
      	... 15 more
      

      + runtime warnings need to be improved in case of bad registration

        Attachments

          Issue Links

            Activity

              People

              • Votes:
                0 Vote for this issue
                Watchers:
                2 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved: