spark-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Kazuaki Ishizaki (JIRA)" <>
Subject [jira] [Commented] (SPARK-22284) Code of class \"org.apache.spark.sql.catalyst.expressions.GeneratedClass$SpecificUnsafeProjection\" grows beyond 64 KB
Date Sun, 22 Oct 2017 14:49:00 GMT


Kazuaki Ishizaki commented on SPARK-22284:

Yes, there was a similar ticket that was solved. Your case is more complicated case that includes
`struct`. I created a repro in my environment. I think that it could be solvable. I will create
a PR this week.

To fix a problem, we usually submit a PR to the master branch. Then, we consider whether the
PR could be applicable to previous versions based on risk assessments by committers.

> Code of class \"org.apache.spark.sql.catalyst.expressions.GeneratedClass$SpecificUnsafeProjection\"
grows beyond 64 KB
> ----------------------------------------------------------------------------------------------------------------------
>                 Key: SPARK-22284
>                 URL:
>             Project: Spark
>          Issue Type: Bug
>          Components: Optimizer, PySpark, SQL
>    Affects Versions: 2.1.0
>            Reporter: Ben
>         Attachments: 64KB Error.log
> I am using pySpark 2.1.0 in a production environment, and trying to join two DataFrames,
one of which is very large and has complex nested structures.
> Basically, I load both DataFrames and cache them.
> Then, in the large DataFrame, I extract 3 nested values and save them as direct columns.
> Finally, I join on these three columns with the smaller DataFrame.
> This would be a short code for this:
> {code}
> dataFrame = dataFrame.selectExpr(['*','nested.Value1 AS Value1','nested.Value2 AS Value2','nested.Value3
AS Value3'])
> dataFrame = dataFrame.dropDuplicates().join(dataFrameSmall, ['Value1','Value2',Value3'])
> dataFrame.count()
> {code}
> And this is the error I get when it gets to the count():
> {code}
> org.apache.spark.SparkException: Job aborted due to stage failure: Task 11 in stage 7.0
failed 4 times, most recent failure: Lost task 11.3 in stage 7.0 (TID 11234,,
executor 10): java.util.concurrent.ExecutionException: java.lang.Exception: failed to compile:
org.codehaus.janino.JaninoRuntimeException: Code of method \"apply_1$(Lorg/apache/spark/sql/catalyst/expressions/GeneratedClass$SpecificUnsafeProjection;Lorg/apache/spark/sql/catalyst/InternalRow;)V\"
of class \"org.apache.spark.sql.catalyst.expressions.GeneratedClass$SpecificUnsafeProjection\"
grows beyond 64 KB
> {code}
> I have seen many tickets with similar issues here, but no proper solution. Most of the
fixes are until Spark 2.1.0 so I don't know if running it on Spark 2.2.0 would fix it. In
any case I cannot change the version of Spark since it is in production.
> I have also tried setting 
> {code:java}
> spark.sql.codegen.wholeStage=false
> {code}
>  but still the same error.
> The job worked well up to now, also with large datasets, but apparently this batch got
larger, and that is the only thing that changed. Is there any workaround for this?

This message was sent by Atlassian JIRA

To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message