7 Replies Latest reply on May 2, 2014 12:53 AM by Rakesh Balguri

    NullPointerException in SourceState

    Rakesh Balguri Expert

      Hi,

       

      When executing a SQL with multiple unions and joins we are getting a NPE in SourceState class. We are using Teiid8.7

       

      28 Apr 2014 05:35:28,574 ERROR [org.teiid.PROCESSOR] (http-CA31/141.202.65.31:30804-2) eA83y/9ZGnji TEIID30019 Unexpected exception for request eA83y/9ZGnji.6: java.lang.NullPointerException

        at org.teiid.query.processor.relational.SourceState.prefetch(SourceState.java:203)

        at org.teiid.query.processor.relational.JoinNode.prefetch(JoinNode.java:231)

        at org.teiid.query.processor.relational.JoinNode.nextBatchDirect(JoinNode.java:223)

        at org.teiid.query.processor.relational.RelationalNode.nextBatch(RelationalNode.java:278)

        at org.teiid.query.processor.relational.ProjectNode.nextBatchDirect(ProjectNode.java:146)

        at org.teiid.query.processor.relational.RelationalNode.nextBatch(RelationalNode.java:278)

        at org.teiid.query.processor.relational.UnionAllNode.nextBatchDirect(UnionAllNode.java:151)

        at org.teiid.query.processor.relational.RelationalNode.nextBatch(RelationalNode.java:278)

        at org.teiid.query.processor.BatchIterator.finalRow(BatchIterator.java:69)

        at org.teiid.common.buffer.AbstractTupleSource.getCurrentTuple(AbstractTupleSource.java:70)

        at org.teiid.query.processor.BatchIterator.getCurrentTuple(BatchIterator.java:84)

        at org.teiid.common.buffer.AbstractTupleSource.nextTuple(AbstractTupleSource.java:48)

        at org.teiid.query.processor.relational.SortUtility.initialSort(SortUtility.java:269)

        at org.teiid.query.processor.relational.SortUtility.sort(SortUtility.java:202)

        at org.teiid.query.processor.relational.SortNode.sortPhase(SortNode.java:112)

        at org.teiid.query.processor.relational.SortNode.getBuffer(SortNode.java:205)

        at org.teiid.query.processor.relational.RelationalPlan.getBuffer(RelationalPlan.java:250)

        at org.teiid.query.processor.QueryProcessor.getBuffer(QueryProcessor.java:289)

        at org.teiid.query.processor.BatchCollector.collectTuples(BatchCollector.java:149)

        at org.teiid.query.processor.BatchCollector.collectTuples(BatchCollector.java:141)

        at org.teiid.dqp.internal.process.RequestWorkItem.processMore(RequestWorkItem.java:444)

        at org.teiid.dqp.internal.process.RequestWorkItem.process(RequestWorkItem.java:326)

        at org.teiid.dqp.internal.process.AbstractWorkItem.run(AbstractWorkItem.java:51)

        at org.teiid.dqp.internal.process.RequestWorkItem.run(RequestWorkItem.java:254)

        at org.teiid.dqp.internal.process.DQPCore.executeRequest(DQPCore.java:295)

        at sun.reflect.GeneratedMethodAccessor129.invoke(Unknown Source) [:1.7.0]

        at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) [rt.jar:1.7.0]

        at java.lang.reflect.Method.invoke(Method.java:607) [rt.jar:1.7.0]

        at org.teiid.logging.LogManager$LoggingProxy.invoke(LogManager.java:121) [teiid-api-8.7.0.FinalCAFix-SNAPSHOT.jar:8.7.0.FinalCAFix-SNAPSHOT]

        at org.teiid.jboss.TransportService$2.invoke(TransportService.java:228)

        at com.sun.proxy.$Proxy19.executeRequest(Unknown Source)

        at sun.reflect.GeneratedMethodAccessor129.invoke(Unknown Source) [:1.7.0]

        at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) [rt.jar:1.7.0]

        at java.lang.reflect.Method.invoke(Method.java:607) [rt.jar:1.7.0]

        at org.teiid.transport.LocalServerConnection$1$1.call(LocalServerConnection.java:170)

        at java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:334) [rt.jar:1.7.0]

        at java.util.concurrent.FutureTask.run(FutureTask.java:166) [rt.jar:1.7.0]

        at org.teiid.dqp.internal.process.DQPWorkContext.runInContext(DQPWorkContext.java:274)

        at org.teiid.dqp.internal.process.DQPWorkContext.runInContext(DQPWorkContext.java:258)

        at org.teiid.transport.LocalServerConnection$1.invoke(LocalServerConnection.java:168)

        at com.sun.proxy.$Proxy19.executeRequest(Unknown Source)

        at org.teiid.jdbc.StatementImpl.execute(StatementImpl.java:634) [teiid-client-8.7.0.FinalCAFix-SNAPSHOT.jar:8.7.0.FinalCAFix-SNAPSHOT]

        at org.teiid.jdbc.StatementImpl.executeSql(StatementImpl.java:509) [teiid-client-8.7.0.FinalCAFix-SNAPSHOT.jar:8.7.0.FinalCAFix-SNAPSHOT]

        at org.teiid.jdbc.PreparedStatementImpl.executeQuery(PreparedStatementImpl.java:261) [teiid-client-8.7.0.FinalCAFix-SNAPSHOT.jar:8.7.0.FinalCAFix-SNAPSHOT]