java.lang.ClassCastException: test.spark.SampleTest$A cannot be cast to java.lang.Long

Stack Overflow | jigsaw | 4 months ago
tip
Your exception is missing from the Samebug knowledge base.
Here are the best solutions we found on the Internet.
Click on the to mark the helpful solution and get rewards for you help.
  1. 0

    Converting typed JavaRDD to Row JavaRDD

    Stack Overflow | 4 months ago | jigsaw
    java.lang.ClassCastException: test.spark.SampleTest$A cannot be cast to java.lang.Long
  2. 0

    Spark Working with custom UADF in java

    Stack Overflow | 11 months ago | Assaf Mendelson
    java.lang.ClassCastException: org.apache.spark.sql.types.GenericArrayData cannot be cast to java.lang.Long
  3. 0

    GitHub comment 107#227570980

    GitHub | 8 months ago | velvia
    java.lang.ClassCastException: java.lang.String cannot be cast to java.lang.Long
  4. Speed up your debug routine!

    Automated exception search integrated into your IDE

  5. 0

    sbt test fails on second launch

    GitHub | 8 months ago | elppc
    java.lang.ClassCastException: java.lang.String cannot be cast to java.lang.Long
  6. 0

    run the spark workload terasort failed.

    GitHub | 2 months ago | SheltonCui
    java.lang.ClassCastException: java.lang.Integer cannot be cast to java.lang.Long

  1. Handemelindo 4 times, last 1 month ago
  2. rp 5 times, last 3 months ago
  3. tyson925 5 times, last 3 months ago
  4. kid 3 times, last 6 months ago
  5. poroszd 2 times, last 7 months ago
3 unregistered visitors
Not finding the right solution?
Take a tour to get the most out of Samebug.

Tired of useless tips?

Automated exception search integrated into your IDE

Root Cause Analysis

  1. java.lang.ClassCastException

    test.spark.SampleTest$A cannot be cast to java.lang.Long

    at scala.runtime.BoxesRunTime.unboxToLong()
  2. Scala
    BoxesRunTime.unboxToLong
    1. scala.runtime.BoxesRunTime.unboxToLong(BoxesRunTime.java:110)
    1 frame
  3. Spark Project Catalyst
    CatalystTypeConverters$LongConverter$.toScalaImpl
    1. org.apache.spark.sql.catalyst.expressions.BaseGenericInternalRow$class.getLong(rows.scala:42)
    2. org.apache.spark.sql.catalyst.expressions.GenericInternalRow.getLong(rows.scala:221)
    3. org.apache.spark.sql.catalyst.CatalystTypeConverters$LongConverter$.toScalaImpl(CatalystTypeConverters.scala:367)
    3 frames