]
RH Bugzilla Integration commented on TEIID-3964:
------------------------------------------------
Jan Stastny <jstastny(a)redhat.com> changed the Status of [bug
Cassandra does not account for null values
------------------------------------------
Key: TEIID-3964
URL:
https://issues.jboss.org/browse/TEIID-3964
Project: Teiid
Issue Type: Bug
Components: Misc. Connectors
Affects Versions: 8.6
Reporter: Filip Elias
Assignee: Steven Hawkins
Priority: Blocker
Fix For: 9.0, 8.12.5, 8.13.1
Attachments: cassandra-vdb.xml
primitive wrapper types (integer, long, float, double, etc.) do not account for null
values from Cassandra, but instead return their default 0 value. Teiid also throws NPE
when Blob column contains null.
Query (should return [14,null]):
{code}select intkey, objectvalue from smalla where intkey = 14 {code}
Stack Trace:
{code}
12:14:58,599 ERROR [org.teiid.CONNECTOR] (Worker0_QueryProcessorQueue7) Connector worker
process failed for atomic-request=afOb+DA5w6pF.5.0.5: java.lang.NullPointerException
at
org.teiid.translator.cassandra.CassandraQueryExecution.getRow(CassandraQueryExecution.java:160)
[translator-cassandra-8.12.3.redhat-1.jar:8.12.3.redhat-1]
at
org.teiid.translator.cassandra.CassandraQueryExecution.next(CassandraQueryExecution.java:86)
[translator-cassandra-8.12.3.redhat-1.jar:8.12.3.redhat-1]
at
org.teiid.dqp.internal.datamgr.ConnectorWorkItem.handleBatch(ConnectorWorkItem.java:419)
at org.teiid.dqp.internal.datamgr.ConnectorWorkItem.more(ConnectorWorkItem.java:220)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) [rt.jar:1.8.0_45]
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
[rt.jar:1.8.0_45]
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
[rt.jar:1.8.0_45]
at java.lang.reflect.Method.invoke(Method.java:497) [rt.jar:1.8.0_45]
at org.teiid.dqp.internal.datamgr.ConnectorManager$1.invoke(ConnectorManager.java:211)
at com.sun.proxy.$Proxy94.more(Unknown Source)
at
org.teiid.dqp.internal.process.DataTierTupleSource.getResults(DataTierTupleSource.java:309)
at
org.teiid.dqp.internal.process.DataTierTupleSource.nextTuple(DataTierTupleSource.java:142)
at org.teiid.query.processor.relational.AccessNode.nextBatchDirect(AccessNode.java:374)
at
org.teiid.query.processor.relational.RelationalNode.nextBatch(RelationalNode.java:282)
at
org.teiid.query.processor.relational.RelationalPlan.nextBatch(RelationalPlan.java:145)
at org.teiid.query.processor.QueryProcessor.nextBatchDirect(QueryProcessor.java:151)
at org.teiid.query.processor.QueryProcessor.nextBatch(QueryProcessor.java:114)
at org.teiid.query.processor.BatchCollector.collectTuples(BatchCollector.java:164)
at org.teiid.query.processor.BatchCollector.collectTuples(BatchCollector.java:146)
at org.teiid.dqp.internal.process.RequestWorkItem.processMore(RequestWorkItem.java:470)
at org.teiid.dqp.internal.process.RequestWorkItem.process(RequestWorkItem.java:348)
at org.teiid.dqp.internal.process.AbstractWorkItem.run(AbstractWorkItem.java:51)
at org.teiid.dqp.internal.process.RequestWorkItem.run(RequestWorkItem.java:274)
at org.teiid.dqp.internal.process.DQPWorkContext.runInContext(DQPWorkContext.java:276)
at
org.teiid.dqp.internal.process.ThreadReuseExecutor$RunnableWrapper.run(ThreadReuseExecutor.java:119)
at
org.teiid.dqp.internal.process.ThreadReuseExecutor$3.run(ThreadReuseExecutor.java:210)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
[rt.jar:1.8.0_45]
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
[rt.jar:1.8.0_45]
at java.lang.Thread.run(Thread.java:745) [rt.jar:1.8.0_45]
{code}