Uploaded image for project: 'Sling'
  1. Sling
  2. SLING-4910

NPE in JCrResourceBundleProvider

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Minor
    • Resolution: Fixed
    • i18n 2.4.4
    • i18n 2.4.4
    • Extensions
    • None

    Description

      At fresh startup seeing couple of exceptions like below. Looks like by the time events are delivered ResourceResolverFactory is still not set (ResourceResolverFactory is missing. Cannot create ResourceResolver) which later causes NPE.

      28.07.2015 09:37:49.803 *ERROR* [Thread-36] org.apache.sling.i18n.impl.JcrResourceBundleProvider getResourceResolver: ResourceResolverFactory is missing. Cannot create ResourceResolver
      28.07.2015 09:37:49.804 *WARN* [Thread-36] org.apache.felix.eventadmin Service [org.apache.sling.i18n.impl.JcrResourceBundleProvider,160, [org.apache.sling.i18n.ResourceBundleProvider, org.osgi.service.event.EventHandler]] EventAdmin: Exception during event dispatch [org.osgi.service.event.Event [topic=org/apache/sling/api/resource/Resource/ADDED] | [org.apache.sling.i18n.ResourceBundleProvider, org.osgi.service.event.EventHandler] | Bundle(org.apache.sling.i18n [93])] (java.lang.NullPointerException)
      java.lang.NullPointerException: null
      	at org.apache.sling.i18n.impl.JcrResourceBundle.refreshSession(JcrResourceBundle.java:98)
      	at org.apache.sling.i18n.impl.JcrResourceBundleProvider.isDictionaryResource(JcrResourceBundleProvider.java:250)
      	at org.apache.sling.i18n.impl.JcrResourceBundleProvider.handleEvent(JcrResourceBundleProvider.java:229)
      	at org.apache.felix.eventadmin.impl.handler.EventHandlerProxy.sendEvent(EventHandlerProxy.java:415)
      	at org.apache.felix.eventadmin.impl.tasks.SyncDeliverTasks$1.run(SyncDeliverTasks.java:145)
      	at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:471)
      	at java.util.concurrent.FutureTask.run(FutureTask.java:262)
      	at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145)
      	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615)
      	at java.lang.Thread.run(Thread.java:745)
      
      

      Attachments

        Issue Links

          Activity

            People

              kwin Konrad Windszus
              chetanm Chetan Mehrotra
              Votes:
              0 Vote for this issue
              Watchers:
              4 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: