You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@gluten.apache.org by "jiangjiangtian (via GitHub)" <gi...@apache.org> on 2025/10/31 02:25:06 UTC
[PR] [MINOR][VL] Fix UnsupportedOperationException when the result type of expressions in GenerateArrowProjection is array [incubator-gluten]
jiangjiangtian opened a new pull request, #10986:
URL: https://github.com/apache/incubator-gluten/pull/10986
## What changes are proposed in this pull request?
When running CI in this [PR](https://github.com/apache/incubator-gluten/pull/10637), there is an exception as follows:
```
Function:operator(), Expression: Operator::getOutput failed for [operator: ValueStream, plan node ID: 0]: Error during calling Java code from native code: java.lang.UnsupportedOperationException
at org.apache.gluten.vectorized.ArrowWritableColumnVector$ArrowVectorAccessor.getInts(ArrowWritableColumnVector.java:857)
at org.apache.gluten.vectorized.ArrowWritableColumnVector.getInts(ArrowWritableColumnVector.java:605)
at org.apache.spark.sql.vectorized.ColumnarArray.toIntArray(ColumnarArray.java:102)
at org.apache.spark.sql.vectorized.ColumnarArray.copy(ColumnarArray.java:79)
at org.apache.spark.sql.catalyst.expressions.GeneratedClass$SpecificArrowProjection.apply(Unknown Source)
at org.apache.gluten.execution.ColumnarPartialProjectExec.$anonfun$getProjectedBatchArrow$3(ColumnarPartialProjectExec.scala:241)
at org.apache.gluten.execution.ColumnarPartialProjectExec.$anonfun$getProjectedBatchArrow$3$adapted(ColumnarPartialProjectExec.scala:239)
at scala.collection.immutable.Range.foreach(Range.scala:158)
at org.apache.gluten.execution.ColumnarPartialProjectExec.org$apache$gluten$execution$ColumnarPartialProjectExec$$getProjectedBatchArrow(ColumnarPartialProjectExec.scala:239)
at org.apache.gluten.execution.ColumnarPartialProjectExec$$anon$1.next(ColumnarPartialProjectExec.scala:180)
at org.apache.gluten.execution.ColumnarPartialProjectExec$$anon$1.next(ColumnarPartialProjectExec.scala:164)
at scala.collection.Iterator$$anon$10.next(Iterator.scala:461)
...
```
The reason is that the generated code will call `copy` on the results and finally call `getxxxs` on `ArrowWritableColumnVector`. But `ArrowWritableColumnVector` doesn't implement these methods.
So this PR follows `InterpretedArrowProjection`, in the generated class, we use an `Object` array called `values` to store the results of expressions and use these `values` to create `GenericInternalRow`.
## How was this patch tested?
Unit tests.
<!--
Describe how the changes were tested, if applicable.
Include new tests to validate the functionality, if necessary.
For UI-related changes, attach screenshots to demonstrate the updates.
-->
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@gluten.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@gluten.apache.org
For additional commands, e-mail: commits-help@gluten.apache.org
Re: [PR] [GLUTEN-10966][VL][FOLLOWUP] Fix UnsupportedOperationException when the result type of expressions in GenerateArrowProjection is array [incubator-gluten]
Posted by "jinchengchenghh (via GitHub)" <gi...@apache.org>.
jinchengchenghh merged PR #10986:
URL: https://github.com/apache/incubator-gluten/pull/10986
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@gluten.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@gluten.apache.org
For additional commands, e-mail: commits-help@gluten.apache.org