Uploaded image for project: '[Read Only] - Hippo Repository'
  1. [Read Only] - Hippo Repository
  2. REPO-1069

Repository does not start when web resources are imported from non-existing directory

    XMLWordPrintable

Details

    • Bug
    • Status: Closed
    • Normal
    • Resolution: Fixed
    • 2.28.00
    • 2.28.00
    • None
    • Sprint 89

    Description

      When web resources are imported from a non-existing directory, the repository does not start up. That's a bit crude: it should just log a warning for the failed initialize item and continue booting.

      Steps to reproduce:
      1. in the archetype-generated project, edit the file 'bootstrap/webresources/src/main/resources/hippoecm-extension.xml' and change the 'hippo:webresourcebundle' value from 'site' to 'nosuchdirectory'
      2. build and startup the project (mvn clean install; mvn -Pcargo.run)

      Expected: the repository starts up and logs a warning about the webresources initialize item since it cannot import from the 'nosuchdirectory' directory

      Actual: the repository does not startup at all. The following exception is logged:

      [INFO] [talledLocalContainer] 22.09.2014 09:20:40 ERROR localhost-startStop-1 [RepositoryServlet.init:229] Error while setting up JCR repository:
      [INFO] [talledLocalContainer] javax.jcr.RepositoryException: unchecked exception: java.lang.reflect.InvocationTargetException: null
      [INFO] [talledLocalContainer] at org.hippoecm.repository.HippoRepositoryFactory.getHippoRepository(HippoRepositoryFactory.java:191)
      [INFO] [talledLocalContainer] at org.hippoecm.repository.RepositoryServlet.init(RepositoryServlet.java:189)
      [INFO] [talledLocalContainer] at org.apache.catalina.core.StandardWrapper.initServlet(StandardWrapper.java:1284)
      [INFO] [talledLocalContainer] at org.apache.catalina.core.StandardWrapper.loadServlet(StandardWrapper.java:1197)
      [INFO] [talledLocalContainer] at org.apache.catalina.core.StandardWrapper.load(StandardWrapper.java:1087)
      [INFO] [talledLocalContainer] at org.apache.catalina.core.StandardContext.loadOnStartup(StandardContext.java:5229)
      [INFO] [talledLocalContainer] at org.apache.catalina.core.StandardContext.startInternal(StandardContext.java:5516)
      [INFO] [talledLocalContainer] at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150)
      [INFO] [talledLocalContainer] at org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java:901)
      [INFO] [talledLocalContainer] at org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:877)
      [INFO] [talledLocalContainer] at org.apache.catalina.core.StandardHost.addChild(StandardHost.java:649)
      [INFO] [talledLocalContainer] at org.apache.catalina.startup.HostConfig.deployWAR(HostConfig.java:1083)
      [INFO] [talledLocalContainer] at org.apache.catalina.startup.HostConfig$DeployWar.run(HostConfig.java:1880)
      [INFO] [talledLocalContainer] at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:471)
      [INFO] [talledLocalContainer] at java.util.concurrent.FutureTask.run(FutureTask.java:262)
      [INFO] [talledLocalContainer] Sep 22, 2014 9:20:40 AM org.apache.catalina.core.StandardContext loadOnStartup
      [INFO] [talledLocalContainer] at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145)
      [INFO] [talledLocalContainer] SEVERE: Servlet /cms threw load() exception
      [INFO] [talledLocalContainer] at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615)
      [INFO] [talledLocalContainer] javax.servlet.ServletException: RepositoryException: unchecked exception: java.lang.reflect.InvocationTargetException: null
      [INFO] [talledLocalContainer] at java.lang.Thread.run(Thread.java:744)
      [INFO] [talledLocalContainer] at org.hippoecm.repository.RepositoryServlet.init(RepositoryServlet.java:230)
      [INFO] [talledLocalContainer] Caused by: java.lang.reflect.InvocationTargetException
      [INFO] [talledLocalContainer] at org.apache.catalina.core.StandardWrapper.initServlet(StandardWrapper.java:1284)
      [INFO] [talledLocalContainer] at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
      [INFO] [talledLocalContainer] at org.apache.catalina.core.StandardWrapper.loadServlet(StandardWrapper.java:1197)
      [INFO] [talledLocalContainer] at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
      [INFO] [talledLocalContainer] at org.apache.catalina.core.StandardWrapper.load(StandardWrapper.java:1087)
      [INFO] [talledLocalContainer] at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
      [INFO] [talledLocalContainer] at org.apache.catalina.core.StandardContext.loadOnStartup(StandardContext.java:5229)
      [INFO] [talledLocalContainer] at java.lang.reflect.Method.invoke(Method.java:606)
      [INFO] [talledLocalContainer] at org.apache.catalina.core.StandardContext.startInternal(StandardContext.java:5516)
      [INFO] [talledLocalContainer] at org.hippoecm.repository.HippoRepositoryFactory.getHippoRepository(HippoRepositoryFactory.java:178)
      [INFO] [talledLocalContainer] at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150)
      [INFO] [talledLocalContainer] ... 17 more
      [INFO] [talledLocalContainer] at org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java:901)
      [INFO] [talledLocalContainer] Caused by: org.onehippo.cms7.services.webresources.WebResourceException: Cannot determine the web resource bundle name: the archive contains no directories
      [INFO] [talledLocalContainer] at org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:877)
      [INFO] [talledLocalContainer] at org.onehippo.cms7.services.webresources.vault.WebResourceBundleArchive.getBundleName(WebResourceBundleArchive.java:51)
      [INFO] [talledLocalContainer] at org.apache.catalina.core.StandardHost.addChild(StandardHost.java:649)
      [INFO] [talledLocalContainer] at org.onehippo.cms7.services.webresources.WebResourcesServiceImpl.importJcrWebResourceBundle(WebResourcesServiceImpl.java:104)
      [INFO] [talledLocalContainer] at org.apache.catalina.startup.HostConfig.deployWAR(HostConfig.java:1083)
      [INFO] [talledLocalContainer] at org.onehippo.cms7.services.webresources.WebResourcesServiceImpl.importJcrWebResourceBundle(WebResourcesServiceImpl.java:96)
      [INFO] [talledLocalContainer] at org.apache.catalina.startup.HostConfig$DeployWar.run(HostConfig.java:1880)
      [INFO] [talledLocalContainer] at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
      [INFO] [talledLocalContainer] at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:471)
      [INFO] [talledLocalContainer] at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
      [INFO] [talledLocalContainer] at java.util.concurrent.FutureTask.run(FutureTask.java:262)
      [INFO] [talledLocalContainer] at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
      [INFO] [talledLocalContainer] at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145)
      [INFO] [talledLocalContainer] at java.lang.reflect.Method.invoke(Method.java:606)
      [INFO] [talledLocalContainer] at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615)
      [INFO] [talledLocalContainer] at org.onehippo.cms7.services.HippoServiceRegistry$NamedRegistration$1.invoke(HippoServiceRegistry.java:54)
      [INFO] [talledLocalContainer] at java.lang.Thread.run(Thread.java:744)
      [INFO] [talledLocalContainer] at com.sun.proxy.$Proxy45.importJcrWebResourceBundle(Unknown Source)
      [INFO] [talledLocalContainer]
      [INFO] [talledLocalContainer] at org.hippoecm.repository.impl.InitializationProcessorImpl$ImportWebResourceBundleFromZipTask.execute(InitializationProcessorImpl.java:1173)
      [INFO] [talledLocalContainer] at org.hippoecm.repository.LocalHippoRepository.initializeStartup(LocalHippoRepository.java:374)
      [INFO] [talledLocalContainer] at org.hippoecm.repository.LocalHippoRepository.initialize(LocalHippoRepository.java:288)
      [INFO] [talledLocalContainer] at org.hippoecm.repository.LocalHippoRepository.create(LocalHippoRepository.java:146)
      [INFO] [talledLocalContainer] at org.hippoecm.repository.LocalHippoRepository.create(LocalHippoRepository.java:136)
      [INFO] [talledLocalContainer] ... 22 more

      Attachments

        1. warning.jpg
          817 kB
          Pankaj Gupta

        Activity

          People

            pgupta Pankaj Gupta (Inactive)
            mdenburger Mathijs den Burger (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: