You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@spark.apache.org by "kanika dhuria (JIRA)" <ji...@apache.org> on 2016/10/13 22:03:20 UTC
[jira] [Created] (SPARK-17922) ClassCastException
java.lang.ClassCastException:
org.apache.spark.sql.catalyst.expressions.GeneratedClass$GeneratedIterator
cannot be cast to
org.apache.spark.sql.catalyst.expressions.UnsafeProjection
kanika dhuria created SPARK-17922:
-------------------------------------
Summary: ClassCastException java.lang.ClassCastException: org.apache.spark.sql.catalyst.expressions.GeneratedClass$GeneratedIterator cannot be cast to org.apache.spark.sql.catalyst.expressions.UnsafeProjection
Key: SPARK-17922
URL: https://issues.apache.org/jira/browse/SPARK-17922
Project: Spark
Issue Type: Bug
Components: SQL
Affects Versions: 2.0.0
Reporter: kanika dhuria
I am using spark 2.0
Seeing class loading issue because the whole stage code gen is generating multiple classes with same name as "org.apache.spark.sql.catalyst.expressions.GeneratedClass"
I am using dataframe transform. and within transform i use Osgi.
Osgi replaces the thread context class loader to ContextFinder which looks at all the class loaders in the stack to find out the new generated class and finds the GeneratedClass with inner class GeneratedIterator byteclass loader(instead of falling back to the byte class loader created by janino compiler), since the class name is same that byte class loader loads the class and returns GeneratedClass$GeneratedIterator instead of expected GeneratedClass$UnsafeProjection.
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)
---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@spark.apache.org
For additional commands, e-mail: issues-help@spark.apache.org