Uploaded image for project: 'OpenIDM'
  1. OpenIDM
  2. OPENIDM-9339

Clustered recon update may abort due to a Rhino NPE

    Details

      Description

      Clustered recon user update test may fail with a NPE as below and when it occurs the whole recon would be canceled. This happened only once so far, talked to Dirk, he indicated it's bug from Rhino and suggested the ticket for early replacement of Rhino to Nashorn.

      Sep 22, 2017 5:35:18 AM org.forgerock.openidm.sync.impl.SyncOperation updateTargetObject
      WARNING: Failed to update target object
      org.forgerock.json.resource.InternalServerErrorException: onUpdate script encountered exception
      	at org.forgerock.openidm.managed.ManagedObjectSet.execScript(ManagedObjectSet.java:363)
      	at org.forgerock.openidm.managed.ManagedObjectSet.execScriptHook(ManagedObjectSet.java:313)
      	at org.forgerock.openidm.managed.ManagedObjectSet.update(ManagedObjectSet.java:565)
      	at org.forgerock.openidm.managed.ManagedObjectSet.updateInstance(ManagedObjectSet.java:1035)
      	at org.forgerock.json.resource.InterfaceCollectionInstance.handleUpdate(InterfaceCollectionInstance.java:64)
      	at org.forgerock.json.resource.FilterChain$Cursor.handleUpdate(FilterChain.java:115)
      	at org.forgerock.json.resource.Resources$CollectionInstanceIdContextFilter.filterUpdate(Resources.java:528)
      	at org.forgerock.json.resource.FilterChain$Cursor.handleUpdate(FilterChain.java:113)
      	at org.forgerock.json.resource.FilterChain.handleUpdate(FilterChain.java:258)
      	at org.forgerock.json.resource.Router.handleUpdate(Router.java:344)
      	at org.forgerock.openidm.managed.ManagedObjectService$ManagedObjectSetRequestHandler.handleUpdate(ManagedObjectService.java:221)
      	at org.forgerock.json.resource.Router.handleUpdate(Router.java:344)
      	at org.forgerock.openidm.managed.ManagedObjectService.handleUpdate(ManagedObjectService.java:353)
      	at org.forgerock.json.resource.Router.handleUpdate(Router.java:344)
      	at org.forgerock.json.resource.FilterChain$Cursor.handleUpdate(FilterChain.java:115)
      	at org.forgerock.json.resource.Filters$ConditionalFilter.filterUpdate(Filters.java:104)
      	at org.forgerock.json.resource.FilterChain$Cursor.handleUpdate(FilterChain.java:113)
      	at org.forgerock.openidm.filter.ScriptedFilter.lambda$filterUpdate$5(ScriptedFilter.java:110)
      	at org.forgerock.util.promise.Promises$CompletedPromise.thenAsync(Promises.java:252)
      	at org.forgerock.util.promise.Promises$CompletedPromise.thenAsync(Promises.java:216)
      	at org.forgerock.openidm.filter.ScriptedFilter.filterRequest(ScriptedFilter.java:142)
      	at org.forgerock.openidm.filter.ScriptedFilter.filterUpdate(ScriptedFilter.java:110)
      	at org.forgerock.json.resource.Filters$ConditionalFilter.filterUpdate(Filters.java:102)
      	at org.forgerock.json.resource.FilterChain$Cursor.handleUpdate(FilterChain.java:113)
      	at org.forgerock.json.resource.Filters$ConditionalFilter.filterUpdate(Filters.java:104)
      	at org.forgerock.json.resource.FilterChain$Cursor.handleUpdate(FilterChain.java:113)
      	at org.forgerock.openidm.audit.filter.AuditFilter.lambda$filterUpdate$6(AuditFilter.java:148)
      	at org.forgerock.openidm.audit.filter.AuditFilter.logAuditAccessEntry(AuditFilter.java:168)
      	at org.forgerock.openidm.audit.filter.AuditFilter.filterUpdate(AuditFilter.java:148)
      	at org.forgerock.openidm.filter.MutableFilterDecorator.filterUpdate(MutableFilterDecorator.java:102)
      	at org.forgerock.json.resource.Filters$ConditionalFilter.filterUpdate(Filters.java:102)
      	at org.forgerock.json.resource.FilterChain$Cursor.handleUpdate(FilterChain.java:113)
      	at org.forgerock.openidm.servlet.internal.ServletConnectionFactory$3.lambda$filterUpdate$6(ServletConnectionFactory.java:409)
      	at org.forgerock.openidm.servlet.internal.ServletConnectionFactory$3.handleRequestWithLogging(ServletConnectionFactory.java:430)
      	at org.forgerock.openidm.servlet.internal.ServletConnectionFactory$3.filterUpdate(ServletConnectionFactory.java:409)
      	at org.forgerock.json.resource.FilterChain$Cursor.handleUpdate(FilterChain.java:113)
      	at org.forgerock.openidm.filter.PassthroughFilter.filterUpdate(PassthroughFilter.java:78)
      	at org.forgerock.openidm.filter.MutableFilterDecorator.filterUpdate(MutableFilterDecorator.java:102)
      	at org.forgerock.openidm.filter.MutableFilterDecorator.filterUpdate(MutableFilterDecorator.java:102)
      	at org.forgerock.json.resource.FilterChain$Cursor.handleUpdate(FilterChain.java:113)
      	at org.forgerock.json.resource.Filters$ConditionalFilter.filterUpdate(Filters.java:104)
      	at org.forgerock.json.resource.FilterChain$Cursor.handleUpdate(FilterChain.java:113)
      	at org.forgerock.json.resource.FilterChain.handleUpdate(FilterChain.java:258)
      	at org.forgerock.json.resource.InternalConnection.updateAsync(InternalConnection.java:88)
      	at org.forgerock.json.resource.AbstractAsynchronousConnection.update(AbstractAsynchronousConnection.java:100)
      	at org.forgerock.json.resource.AbstractConnectionWrapper.update(AbstractConnectionWrapper.java:212)
      	at org.forgerock.openidm.servlet.internal.ServletConnectionFactory$2$1.update(ServletConnectionFactory.java:282)
      	at org.forgerock.json.resource.AbstractConnectionWrapper.update(AbstractConnectionWrapper.java:212)
      	at org.forgerock.openidm.sync.impl.SyncOperation.updateTargetObject(SyncOperation.java:870)
      	at org.forgerock.openidm.sync.impl.SyncOperation.performAction(SyncOperation.java:527)
      	at org.forgerock.openidm.sync.impl.SourceSyncOperation.sync(SourceSyncOperation.java:75)
      	at org.forgerock.openidm.sync.impl.SourceRecon.recon(SourceRecon.java:72)
      	at org.forgerock.openidm.sync.impl.ReconTask.call(ReconTask.java:57)
      	at org.forgerock.openidm.sync.impl.ReconTask.call(ReconTask.java:24)
      	at java.util.concurrent.FutureTask.run(FutureTask.java:266)
      	at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511)
      	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: javax.script.ScriptException: java.lang.NullPointerException
      	at org.forgerock.openidm.script.javascript.RhinoScript.eval(RhinoScript.java:323)
      	at sun.reflect.GeneratedMethodAccessor98.invoke(Unknown Source)
      	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
      	at java.lang.reflect.Method.invoke(Method.java:498)
      	at org.forgerock.openidm.script.registry.ScriptRegistryImpl$LibraryRecord.invoke(ScriptRegistryImpl.java:498)
      	at com.sun.proxy.$Proxy44.eval(Unknown Source)
      	at org.forgerock.openidm.script.registry.ScriptRegistryImpl$ScriptImpl.eval(ScriptRegistryImpl.java:768)
      	at org.forgerock.openidm.script.registry.ScriptRegistryImpl$ScriptImpl.eval(ScriptRegistryImpl.java:779)
      	at org.forgerock.openidm.managed.ManagedObjectSet.execScript(ManagedObjectSet.java:355)
      	... 59 more
      Caused by: java.lang.NullPointerException
      	at java.util.LinkedList$ListItr.next(LinkedList.java:893)
      	at org.mozilla.javascript.NativeJavaMethod.findCachedFunction(NativeJavaMethod.java:254)
      	at org.mozilla.javascript.NativeJavaMethod.call(NativeJavaMethod.java:139)
      	at org.mozilla.javascript.optimizer.OptRuntime.call1(OptRuntime.java:32)
      	at org.mozilla.javascript.gen.file__external_testuser_jenkins_workspace_IDM_5_5_0_Clustered_Recon_Tests_IDM_5_5_0_Stress_Tests_Recon_System_Ldap_2Nodes_Cluster_Target_Phase_Disabled_results_20170922_051049_idm_ReconLDAPToManUserInClusterTargetPhaseDisabled_IDM_node2_openidm_bin_defaults_script_ui_onUpdateUser_js_76._c_anonymous_9(file:/external/testuser/jenkins/workspace/IDM-5.5.0/Clustered-Recon-Tests/IDM-5.5.0-Stress-Tests-Recon-System-Ldap-2Nodes-Cluster-Target-Phase-Disabled/results/20170922-051049/idm/ReconLDAPToManUserInClusterTargetPhaseDisabled/IDM_node2/openidm/bin/defaults/script/ui/onUpdateUser.js:94)
      	at org.mozilla.javascript.gen.file__external_testuser_jenkins_workspace_IDM_5_5_0_Clustered_Recon_Tests_IDM_5_5_0_Stress_Tests_Recon_System_Ldap_2Nodes_Cluster_Target_Phase_Disabled_results_20170922_051049_idm_ReconLDAPToManUserInClusterTargetPhaseDisabled_IDM_node2_openidm_bin_defaults_script_ui_onUpdateUser_js_76.call(file:/external/testuser/jenkins/workspace/IDM-5.5.0/Clustered-Recon-Tests/IDM-5.5.0-Stress-Tests-Recon-System-Ldap-2Nodes-Cluster-Target-Phase-Disabled/results/20170922-051049/idm/ReconLDAPToManUserInClusterTargetPhaseDisabled/IDM_node2/openidm/bin/defaults/script/ui/onUpdateUser.js)
      	at org.mozilla.javascript.optimizer.OptRuntime.call2(OptRuntime.java:42)
      	at org.mozilla.javascript.gen._542EFA21574CC8A2B287773F8A130CDEB72D0BF7_47._c_script_0(542EFA21574CC8A2B287773F8A130CDEB72D0BF7:1)
      	at org.mozilla.javascript.gen._542EFA21574CC8A2B287773F8A130CDEB72D0BF7_47.call(542EFA21574CC8A2B287773F8A130CDEB72D0BF7)
      	at org.mozilla.javascript.ContextFactory.doTopCall(ContextFactory.java:394)
      	at org.mozilla.javascript.ScriptRuntime.doTopCall(ScriptRuntime.java:3091)
      	at org.mozilla.javascript.gen._542EFA21574CC8A2B287773F8A130CDEB72D0BF7_47.call(542EFA21574CC8A2B287773F8A130CDEB72D0BF7)
      	at org.mozilla.javascript.gen._542EFA21574CC8A2B287773F8A130CDEB72D0BF7_47.exec(542EFA21574CC8A2B287773F8A130CDEB72D0BF7)
      	at org.forgerock.openidm.script.javascript.RhinoScript.eval(RhinoScript.java:289)
      	... 67 more
      

      and then

      Sep 22, 2017 5:36:06 AM org.forgerock.openidm.sync.impl.ClusteredRecon dispatchClusteredRecon
      SEVERE: Clustered reconciliation failed: Reconciliation canceled: e791eb75-329d-4e0b-b53a-8d656efcbc70-1101858
      org.forgerock.openidm.sync.SynchronizationException: Reconciliation canceled: e791eb75-329d-4e0b-b53a-8d656efcbc70-1101858
              at org.forgerock.openidm.sync.impl.ReconciliationContext.checkCanceled(ReconciliationContext.java:240)
              at org.forgerock.openidm.sync.impl.SourceRecon.recon(SourceRecon.java:41)
              at org.forgerock.openidm.sync.impl.ReconTask.call(ReconTask.java:57)
              at org.forgerock.openidm.sync.impl.ReconTask.call(ReconTask.java:24)
              at java.util.concurrent.FutureTask.run(FutureTask.java:266)
              at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511)
              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)
      

        Attachments

          Issue Links

            Activity

              People

              • Assignee:
                brmiller Brendan Miller
                Reporter:
                Tinghua.Xu Tinghua.Xu
              • Votes:
                0 Vote for this issue
                Watchers:
                2 Start watching this issue

                Dates

                • Created:
                  Updated: