Alert Aggregated Function Generates BAM-04005 Error (Doc ID 2236703.1)

Last updated on FEBRUARY 28, 2017

Applies to:

Oracle BAM (Business Activity Monitoring) - Version 12.2.1.0.0 and later
Information in this document applies to any platform.

Symptoms

On : 12.2.1.0.0 version, BAM Alerts

When attempting to save an alert which has more than one calculated field which use an aggregate function like count, sum, etc the following error occurs.

 

[2017-01-07T00:31:53.402+00:00] [bam_server1] [ERROR] [] [oracle.beam.cqservice.trace] [tid: [ACTIVE].ExecuteThread: '16' for queue: 'weblogic.kernel.Default (self-tuning)'] [userId: weblogic] [ecid: 60aa217b-ae97-4081-a538-10184a2e25e6-000005c8,0] [APP: BamCQService] [partition-name: DOMAIN] [tenant-name: GLOBAL] java.lang.NullPointerException

..
...

[2017-01-07T00:31:53.422+00:00] [bam_server1] [ERROR] [] [oracle.beam.cqservice] [tid: [ACTIVE].ExecuteThread: '16' for queue: 'weblogic.kernel.Default (self-tuning)'] [userId: ] [ecid: 60aa217b-ae97-4081-a538-10184a2e25e6-000005c8,0] [APP: BamCQService] [partition-name: DOMAIN] [tenant-name: GLOBAL] Can't rollback transanction.[[
at oracle.beam.cqservice.metadata.txn.Transaction.abort(Transaction.java:98)
at oracle.beam.cqservice.cql.codegen.BaseDriver.process(BaseDriver.java:50)
at oracle.beam.cqservice.ha.HACQLProcessor.onRegisterQuery(HACQLProcessor.java:249)
at oracle.beam.cqservice.ha.HAEventProcessor$RegisterQueryWork.run(HAEventProcessor.java:132)
at weblogic.work.j2ee.J2EEWorkManager$WorkWithListener.run(J2EEWorkManager.java:207)

]]
[2017-01-07T00:31:53.424+00:00] [bam_server1] [ERROR] [] [oracle.beam.cqservice] [tid: [ACTIVE].ExecuteThread: '16' for queue: 'weblogic.kernel.Default (self-tuning)'] [userId: ] [ecid: 60aa217b-ae97-4081-a538-10184a2e25e6-000005c8,0] [APP: BamCQService] [partition-name: DOMAIN] [tenant-name: GLOBAL] Fail to register query[[
java.rmi.RemoteException: null; nested exception is:
java.lang.NullPointerException
at oracle.cep.server.CEPServer.executeDDL(CEPServer.java:209)
at oracle.beam.cqservice.cqlinteg.CEPServerDriver.executeDDL(CEPServerDriver.java:128)
at oracle.beam.cqservice.metadata.Query.register(Query.java:230)
at oracle.beam.cqservice.cql.codegen.QueryDriver$RegisterQuery.execute(QueryDriver.java:72)
at oracle.beam.cqservice.metadata.txn.Transaction.add(Transaction.java:71)
at oracle.beam.cqservice.cql.codegen.QueryDriver$1.run(QueryDriver.java:48)
at java.security.AccessController.doPrivileged(Native Method)
at oracle.security.jps.util.JpsSubject.doAsPrivileged(JpsSubject.java:315)
at oracle.security.jps.internal.jaas.AccActionExecutor.execute(AccActionExecutor.java:70)
at oracle.security.jps.internal.jaas.AbstractSubjectSecurity$ActionExecutorWrapper.execute(AbstractSubjectSecurity.java:266)
at oracle.security.jps.internal.jaas.CascadeActionExecutor$SubjectPrivilegedExceptionAction.run(CascadeActionExecutor.java:82)
at weblogic.security.acl.internal.AuthenticatedSubject.doAs(AuthenticatedSubject.java:368)
at weblogic.security.service.SecurityManager.runAs(SecurityManager.java:163)
at weblogic.security.Security.runAs(Security.java:61)
at oracle.security.jps.wls.jaas.WlsActionExecutor.execute(WlsActionExecutor.java:50)
at oracle.security.jps.internal.jaas.CascadeActionExecutor.execute(CascadeActionExecutor.java:55)
at oracle.security.jps.internal.jaas.AbstractSubjectSecurity$ActionExecutorWrapper.execute(AbstractSubjectSecurity.java:266)
at oracle.beam.common.security.authentication.BeamPrivilegedExceptionAction.execute(BeamPrivilegedExceptionAction.java:115)
at oracle.beam.cqservice.cql.codegen.QueryDriver.processTxn(QueryDriver.java:53)
at oracle.beam.cqservice.cql.codegen.BaseDriver.process(BaseDriver.java:41)
at oracle.beam.cqservice.ha.HACQLProcessor.onRegisterQuery(HACQLProcessor.java:249)
at oracle.beam.cqservice.ha.HAEventProcessor$RegisterQueryWork.run(HAEventProcessor.java:132)
at weblogic.work.j2ee.J2EEWorkManager$WorkWithListener.run(J2EEWorkManager.java:207)
at weblogic.invocation.ComponentInvocationContextManager._runAs(ComponentInvocationContextManager.java:348)
at weblogic.invocation.ComponentInvocationContextManager.runAs(ComponentInvocationContextManager.java:333)
at weblogic.work.LivePartitionUtility.doRunWorkUnderContext(LivePartitionUtility.java:54)
at weblogic.work.PartitionUtility.runWorkUnderContext(PartitionUtility.java:41)
at weblogic.work.SelfTuningWorkManagerImpl.runWorkUnderContext(SelfTuningWorkManagerImpl.java:617)
at weblogic.work.ExecuteThread.execute(ExecuteThread.java:397)
at weblogic.work.ExecuteThread.run(ExecuteThread.java:346)
Caused by: java.lang.NullPointerException
at oracle.cep.semantic.BaseBExpr.equals(BaseBExpr.java:256)
at oracle.cep.semantic.CaseConditionExpr.equals(CaseConditionExpr.java:134)
at oracle.cep.semantic.SearchedCaseExpr.equals(SearchedCaseExpr.java:169)
at oracle.cep.semantic.AggrExpr.equals(AggrExpr.java:182)
at java.util.ArrayList.indexOf(ArrayList.java:317)
at java.util.ArrayList.contains(ArrayList.java:300)
at oracle.cep.semantic.AggrExpr.getAllReferencedAggrs(AggrExpr.java:144)
at oracle.cep.semantic.SFWQueryInterp.collectAggrs(SFWQueryInterp.java:645)
at oracle.cep.semantic.SFWQueryInterp.interpretSelectClause(SFWQueryInterp.java:445)
at oracle.cep.semantic.SFWQueryInterp.interpretNode(SFWQueryInterp.java:141)
at oracle.cep.semantic.QueryDefnInterp.interpretNode(QueryDefnInterp.java:61)
at oracle.cep.semantic.SemanticInterpreter.interpretQuery(SemanticInterpreter.java:117)
at oracle.cep.metadata.QueryManager.typecheck(QueryManager.java:1902)
at oracle.cep.metadata.QueryManager.addQuery(QueryManager.java:1830)
at oracle.cep.metadata.QueryManager.addNamedQuery(QueryManager.java:1755)
at oracle.cep.server.CommandDriver.QueryNodeDriver.execute(QueryNodeDriver.java:48)
at oracle.cep.server.CommandInterpreter.execute(CommandInterpreter.java:274)
at oracle.cep.server.CEPServer.executeDDL(CEPServer.java:197)
... 29 more

]]
[2017-01-07T00:31:53.839+00:00] [bam_server1] [WARNING] [] [oracle.beam.commonquery] [tid: [ACTIVE].ExecuteThread: '20' for queue: 'weblogic.kernel.Default (self-tuning)'] [userId: weblogic] [ecid: 60aa217b-ae97-4081-a538-10184a2e25e6-000005bc,0] [APP: BamServer] [partition-name: DOMAIN] [tenant-name: GLOBAL] [DSID: 0000L_qE^dSFw000jzwkno1OS2xe000001] Register Continuous Query is failed for Alert. Not converting to scheduled query.[[
oracle.beam.common.exceptions.BeamException: BAM-04005: Query execution error:"null".
at weblogic.rmi.internal.ServerRequest.sendReceive(ServerRequest.java:278)
at weblogic.rmi.cluster.ClusterableRemoteRef.invoke(ClusterableRemoteRef.java:497)
at weblogic.rmi.cluster.ClusterableRemoteRef.invoke(ClusterableRemoteRef.java:287)
at oracle.beam.cqservice.services.CQServiceBean_s4oast_CQServiceImpl_12210_WLStub.registerCQ(Unknown Source)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:497)
at weblogic.ejb.container.internal.RemoteBusinessIntfProxy.invoke(RemoteBusinessIntfProxy.java:85)
at com.sun.proxy.$Proxy324.registerCQ(Unknown Source)

 

Cause

Sign In with your My Oracle Support account

Don't have a My Oracle Support account? Click to get started

My Oracle Support provides customers with access to over a
Million Knowledge Articles and hundreds of Community platforms