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

Fix null pointer exception on async automation scripting

    Details

    • Type: Improvement
    • Status: Resolved
    • Priority: Critical
    • Resolution: Fixed
    • Affects Version/s: 2021.0
    • Fix Version/s: 2021.17
    • Component/s: Automation
    • Release Notes Summary:
      Automation scripting can now be run in an async way
    • Tags:

      Description

      The async service is not initialized in the InvokableMethod constructor used for automation scripts

      This results in a null pointer exception when trying to execute an automation script asynchronously

      2022-02-17 12:12:07,997 [Nuxeo-AsyncOperation-da704552-557a-4632-854f-bab1e0f298e1] ERROR [AsyncOperationAdapter] java.lang.NullPointerException java.lang.NullPointerException: null at org.nuxeo.ecm.automation.server.jaxrs.adapters.AsyncOperationAdapter.enterMethod(AsyncOperationAdapter.java:309) ~[nuxeo-automation-server-2021.16-SNAPSHOT.jar:?] at org.nuxeo.ecm.automation.server.jaxrs.adapters.AsyncOperationAdapter$1.onOperationEnter(AsyncOperationAdapter.java:174) ~[nuxeo-automation-server-2021.16-SNAPSHOT.jar:?] at org.nuxeo.ecm.automation.core.impl.OperationChainCompiler$OperationMethod.invoke(OperationChainCompiler.java:146) ~[nuxeo-automation-core-2021.16-SNAPSHOT.jar:?] at org.nuxeo.ecm.automation.core.impl.OperationChainCompiler$CompiledChainImpl.lambda$invoke$0(OperationChainCompiler.java:212) ~[nuxeo-automation-core-2021.16-SNAPSHOT.jar:?] at org.nuxeo.ecm.automation.OperationContext.call(OperationContext.java:314) ~[nuxeo-automation-core-2021.16-SNAPSHOT.jar:?] at org.nuxeo.ecm.automation.OperationContext.callWithChainParameters(OperationContext.java:279) ~[nuxeo-automation-core-2021.16-SNAPSHOT.jar:?] at org.nuxeo.ecm.automation.core.impl.OperationChainCompiler$CompiledChainImpl.invoke(OperationChainCompiler.java:209) ~[nuxeo-automation-core-2021.16-SNAPSHOT.jar:?] at org.nuxeo.ecm.automation.core.impl.OperationServiceImpl.run(OperationServiceImpl.java:115) ~[nuxeo-automation-core-2021.16-SNAPSHOT.jar:?] at org.nuxeo.ecm.automation.core.impl.OperationServiceImpl.lambda$run$0(OperationServiceImpl.java:105) ~[nuxeo-automation-core-2021.16-SNAPSHOT.jar:?] at org.nuxeo.ecm.automation.OperationContext.call(OperationContext.java:314) ~[nuxeo-automation-core-2021.16-SNAPSHOT.jar:?] at org.nuxeo.ecm.automation.OperationContext.callWithChainParameters(OperationContext.java:279) ~[nuxeo-automation-core-2021.16-SNAPSHOT.jar:?] at org.nuxeo.ecm.automation.core.impl.OperationServiceImpl.run(OperationServiceImpl.java:105) ~[nuxeo-automation-core-2021.16-SNAPSHOT.jar:?] at org.nuxeo.ecm.automation.server.jaxrs.adapters.AsyncOperationAdapter.lambda$doPost$0(AsyncOperationAdapter.java:206) ~[nuxeo-automation-server-2021.16-SNAPSHOT.jar:?] at org.nuxeo.runtime.transaction.TransactionHelper.lambda$runInTransaction$4(TransactionHelper.java:628) ~[nuxeo-runtime-jtajca-2021.16-SNAPSHOT.jar:?] at org.nuxeo.runtime.transaction.TransactionHelper.runInTransaction(TransactionHelper.java:661) ~[nuxeo-runtime-jtajca-2021.16-SNAPSHOT.jar:?] at org.nuxeo.runtime.transaction.TransactionHelper.runInTransaction(TransactionHelper.java:628) ~[nuxeo-runtime-jtajca-2021.16-SNAPSHOT.jar:?] at org.nuxeo.runtime.transaction.TransactionHelper.runInTransaction(TransactionHelper.java:616) ~[nuxeo-runtime-jtajca-2021.16-SNAPSHOT.jar:?] at org.nuxeo.ecm.automation.server.jaxrs.adapters.AsyncOperationAdapter.lambda$doPost$1(AsyncOperationAdapter.java:201) ~[nuxeo-automation-server-2021.16-SNAPSHOT.jar:?] at java.lang.Thread.run(Thread.java:829) [?:?] 2022-02-17 12:12:08,028 [Nuxeo-AsyncOperation-da704552-557a-4632-854f-bab1e0f298e1] ERROR [AsyncOperationAdapter] org.nuxeo.ecm.automation.OperationException: java.lang.NullPointerException org.nuxeo.ecm.automation.OperationException: java.lang.NullPointerException
      

        Attachments

          Issue Links

            Activity

              People

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

                Dates

                • Created:
                  Updated:
                  Resolved:

                  PagerDuty

                  Error rendering 'com.pagerduty.jira-server-plugin:PagerDuty'. Please contact your Jira administrators.