[
https://issues.jboss.org/browse/TEIID-2890?page=com.atlassian.jira.plugin...
]
Steven Hawkins updated TEIID-2890:
----------------------------------
Fix Version/s: 8.7
Priority: Major (was: Minor)
Affects Version/s: 8.4
(was: 8.7)
This seemed to be reproducible for me back to 8.4. Although that was using the repository
versions, rather than finals so I'm not sure if there could have been a patch
regression to explain why you didn't see this on 8.6. In any case the issue is the
indexing logic in the grouping node assumes that each order by expression is unique, which
is something that we don't enforce.
IndexOutOfBoundsException when using GROUP BY
---------------------------------------------
Key: TEIID-2890
URL:
https://issues.jboss.org/browse/TEIID-2890
Project: Teiid
Issue Type: Bug
Components: Query Engine
Affects Versions: 8.4
Reporter: Tom Arnold
Assignee: Steven Hawkins
Labels: 8.7, grouping, translator
Fix For: 8.7
I have a translator that does not support aggregates or grouping. I am using a view to
try to normalize data from several sources. I am duplicating some of the fields as an
approximation. I have existing software that is querying with GROUP BY, and sometimes this
happens.
This query works fine in 8.6:
{code:sql}
select identifier
from foo.items
group by identifier, identifier;
{code}
In 8.7 this happens:
{code}
10:15:24,280 ERROR [org.teiid.PROCESSOR] (Worker2_QueryProcessorQueue39) njknuxobPkVY
TEIID30019 Unexpected exception for request njknuxobPkVY.3:
java.lang.IndexOutOfBoundsException: Index: 1, Size: 1
at java.util.ArrayList.rangeCheck(ArrayList.java:604) [rt.jar:1.7.0_02]
at java.util.ArrayList.get(ArrayList.java:382) [rt.jar:1.7.0_02]
at
org.teiid.query.processor.relational.MergeJoinStrategy.compareTuples(MergeJoinStrategy.java:313)
[teiid-engine-8.7.0.Beta2-SNAPSHOT.jar:8.7.0.Beta2-SNAPSHOT]
at org.teiid.query.processor.relational.GroupingNode.sameGroup(GroupingNode.java:488)
[teiid-engine-8.7.0.Beta2-SNAPSHOT.jar:8.7.0.Beta2-SNAPSHOT]
at
org.teiid.query.processor.relational.GroupingNode.groupPhase(GroupingNode.java:414)
[teiid-engine-8.7.0.Beta2-SNAPSHOT.jar:8.7.0.Beta2-SNAPSHOT]
at
org.teiid.query.processor.relational.GroupingNode.nextBatchDirect(GroupingNode.java:336)
[teiid-engine-8.7.0.Beta2-SNAPSHOT.jar:8.7.0.Beta2-SNAPSHOT]
at
org.teiid.query.processor.relational.RelationalNode.nextBatch(RelationalNode.java:278)
[teiid-engine-8.7.0.Beta2-SNAPSHOT.jar:8.7.0.Beta2-SNAPSHOT]
at
org.teiid.query.processor.relational.ProjectNode.nextBatchDirect(ProjectNode.java:146)
[teiid-engine-8.7.0.Beta2-SNAPSHOT.jar:8.7.0.Beta2-SNAPSHOT]
at
org.teiid.query.processor.relational.RelationalNode.nextBatch(RelationalNode.java:278)
[teiid-engine-8.7.0.Beta2-SNAPSHOT.jar:8.7.0.Beta2-SNAPSHOT]
at
org.teiid.query.processor.relational.RelationalPlan.nextBatch(RelationalPlan.java:136)
[teiid-engine-8.7.0.Beta2-SNAPSHOT.jar:8.7.0.Beta2-SNAPSHOT]
at org.teiid.query.processor.QueryProcessor.nextBatchDirect(QueryProcessor.java:151)
[teiid-engine-8.7.0.Beta2-SNAPSHOT.jar:8.7.0.Beta2-SNAPSHOT]
at org.teiid.query.processor.QueryProcessor.nextBatch(QueryProcessor.java:114)
[teiid-engine-8.7.0.Beta2-SNAPSHOT.jar:8.7.0.Beta2-SNAPSHOT]
at org.teiid.query.processor.BatchCollector.collectTuples(BatchCollector.java:159)
[teiid-engine-8.7.0.Beta2-SNAPSHOT.jar:8.7.0.Beta2-SNAPSHOT]
at org.teiid.query.processor.BatchCollector.collectTuples(BatchCollector.java:141)
[teiid-engine-8.7.0.Beta2-SNAPSHOT.jar:8.7.0.Beta2-SNAPSHOT]
at
org.teiid.dqp.internal.process.RequestWorkItem.processMore(RequestWorkItem.java:435)
[teiid-engine-8.7.0.Beta2-SNAPSHOT.jar:8.7.0.Beta2-SNAPSHOT]
at org.teiid.dqp.internal.process.RequestWorkItem.process(RequestWorkItem.java:320)
[teiid-engine-8.7.0.Beta2-SNAPSHOT.jar:8.7.0.Beta2-SNAPSHOT]
at org.teiid.dqp.internal.process.AbstractWorkItem.run(AbstractWorkItem.java:51)
[teiid-engine-8.7.0.Beta2-SNAPSHOT.jar:8.7.0.Beta2-SNAPSHOT]
at org.teiid.dqp.internal.process.RequestWorkItem.run(RequestWorkItem.java:248)
[teiid-engine-8.7.0.Beta2-SNAPSHOT.jar:8.7.0.Beta2-SNAPSHOT]
at
org.teiid.dqp.internal.process.DQPWorkContext.runInContext(DQPWorkContext.java:273)
[teiid-engine-8.7.0.Beta2-SNAPSHOT.jar:8.7.0.Beta2-SNAPSHOT]
at
org.teiid.dqp.internal.process.ThreadReuseExecutor$RunnableWrapper.run(ThreadReuseExecutor.java:119)
[teiid-engine-8.7.0.Beta2-SNAPSHOT.jar:8.7.0.Beta2-SNAPSHOT]
at
org.teiid.dqp.internal.process.ThreadReuseExecutor$3.run(ThreadReuseExecutor.java:214)
[teiid-engine-8.7.0.Beta2-SNAPSHOT.jar:8.7.0.Beta2-SNAPSHOT]
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1110)
[rt.jar:1.7.0_02]
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:603)
[rt.jar:1.7.0_02]
at java.lang.Thread.run(Thread.java:722) [rt.jar:1.7.0_02]
{code}
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see:
http://www.atlassian.com/software/jira