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

Stack Overflow | jigsaw | 5 months ago
tip
Click on the to mark the solution that helps you, Samebug will learn from it.
As a community member, you’ll be rewarded for you help.
  1. 0

    Converting typed JavaRDD to Row JavaRDD

    Stack Overflow | 5 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 | 1 year 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 | 9 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 | 9 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 | 3 months ago | SheltonCui
    java.lang.ClassCastException: java.lang.Integer cannot be cast to java.lang.Long

  1. Handemelindo 4 times, last 3 months ago
  2. rp 5 times, last 4 months ago
  3. tyson925 5 times, last 5 months ago
  4. kid 3 times, last 7 months ago
  5. poroszd 2 times, last 8 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