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

Fix NPE for the Pluggable Event bus

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Resolved
    • Priority: Major
    • Resolution: Cannot Reproduce
    • Affects Version/s: 8.10
    • Fix Version/s: None
    • Component/s: Events / Works

      Description

      NPE can be thrown right after server startup.

      Exception in thread "pool-2-thread-1" java.lang.NullPointerException
          at org.nuxeo.ecm.core.event.impl.AsyncEventExecutor.lambda$run$0(AsyncEventExecutor.java:103)
          at org.nuxeo.runtime.transaction.TransactionHelper.lambda$runInTransaction$2(TransactionHelper.java:539)
          at org.nuxeo.runtime.transaction.TransactionHelper.runInTransaction(TransactionHelper.java:559)
          at org.nuxeo.runtime.transaction.TransactionHelper.runInTransaction(TransactionHelper.java:539)
          at org.nuxeo.ecm.core.event.impl.AsyncEventExecutor.run(AsyncEventExecutor.java:95)
          at org.nuxeo.ecm.core.event.kafka.KafkaPipe$1.process(KafkaPipe.java:113)
          at org.nuxeo.ecm.core.event.kafka.KafkaPipe$1.run(KafkaPipe.java:123)
          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)
      

      This is due to code not dealing with event contexts that don't have a repository associated (which can be the case for instance for login events).

      Can be reproduced with plugged Event Bus addon on second and further starts.

        Attachments

          Activity

            People

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

              Dates

              • Created:
                Updated:
                Resolved: