Bug: java.io.InvalidClassException: org.apache.hadoop.hbase.spark.HBaseRelation
Status: Resolved | Priority: Major | Resolution: Invalid
Created: 16/Feb/22 13:00
Affects Version/s: 2.4.4

Hi , 

I am getting below errors , yesterday i got same error but re-triggered the job it went fine. 
can u please help me to find the reason ?

 

org.apache.spark.SparkException: Job aborted due to stage failure: Task 0 in stage 1140.0 failed 4 times, most recent failure: Lost task 0.3 in stage 1140.0 (TID 138700, elr5hz1-09-s37.uhc.com, executor 4): java.io.InvalidClassException: org.apache.hadoop.hbase.spark.HBaseRelation; local class incompatible: stream classdesc serialVersionUID = 6538481011051402884, local class serialVersionUID = -5296968177686166695
        at java.io.ObjectStreamClass.initNonProxy(ObjectStreamClass.java:699)
        at java.io.ObjectInputStream.readNonProxyDesc(ObjectInputStream.java:1940)
        at java.io.ObjectInputStream.readClassDesc(ObjectInputStream.java:1806)
        at java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:2097)
        at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1625)
        at java.io.ObjectInputStream.defaultReadFields(ObjectInputStream.java:2342)
        at java.io.ObjectInputStream.readSerialData(ObjectInputStream.java:2266)
        at java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:2124)
        at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1625)
        at java.io.ObjectInputStream.defaultReadFields(ObjectInputStream.java:2342)
        at java.io.ObjectInputStream.readSerialData(ObjectInputStream.java:2266)
        at java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:2124)
        at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1625)
        at java.io.ObjectInputStream.readObject(ObjectInputStream.java:465)
        at java.io.ObjectInputStream.readObject(ObjectInputStream.java:423)
        at scala.collection.immutable.List$SerializationProxy.readObject(List.scala:490)
        at sun.reflect.GeneratedMethodAccessor8.invoke(Unknown Source)
        at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
        at java.lang.reflect.Method.invoke(Method.java:498)
        at java.io.ObjectStreamClass.invokeReadObject(ObjectStreamClass.java:1170)
        at java.io.ObjectInputStream.readSerialData(ObjectInputStream.java:2233)
        at java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:2124)
        at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1625)
        at java.io.ObjectInputStream.defaultReadFields(ObjectInputStream.java:2342)
        at java.io.ObjectInputStream.readSerialData(ObjectInputStream.java:2266)
        at java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:2124)
        at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1625)
        at java.io.ObjectInputStream.defaultReadFields(ObjectInputStream.java:2342)
        at java.io.ObjectInputStream.readSerialData(ObjectInputStream.java:2266)
        at java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:2124)
        at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1625)
        at java.io.ObjectInputStream.readObject(ObjectInputStream.java:465)
        at java.io.ObjectInputStream.readObject(ObjectInputStream.java:423)
        at scala.collection.immutable.List$SerializationProxy.readObject(List.scala:490)
        at sun.reflect.GeneratedMethodAccessor8.invoke(Unknown Source)
        at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
        at java.lang.reflect.Method.invoke(Method.java:498)
        at java.io.ObjectStreamClass.invokeReadObject(ObjectStreamClass.java:1170)
        at java.io.ObjectInputStream.readSerialData(ObjectInputStream.java:2233)
        at java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:2124)
        at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1625)
        at java.io.ObjectInputStream.defaultReadFields(ObjectInputStream.java:2342)
        at java.io.ObjectInputStream.readSerialData(ObjectInputStream.java:2266)
        at java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:2124)
        at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1625)
        at java.io.ObjectInputStream.defaultReadFields(ObjectInputStream.java:2342)
        at java.io.ObjectInputStream.readSerialData(ObjectInputStream.java:2266)
        at java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:2124)
        at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1625)
        at java.io.ObjectInputStream.readObject(ObjectInputStream.java:465)
        at java.io.ObjectInputStream.readObject(ObjectInputStream.java:423)
        at scala.collection.immutable.List$SerializationProxy.readObject(List.scala:490)
        at sun.reflect.GeneratedMethodAccessor8.invoke(Unknown Source)
        at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
        at java.lang.reflect.Method.invoke(Method.java:498)
        at java.io.ObjectStreamClass.invokeReadObject(ObjectStreamClass.java:1170)
        at java.io.ObjectInputStream.readSerialData(ObjectInputStream.java:2233)
        at java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:2124)
        at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1625)
        at java.io.ObjectInputStream.defaultReadFields(ObjectInputStream.java:2342)
        at java.io.ObjectInputStream.readSerialData(ObjectInputStream.java:2266)
        at java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:2124)
        at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1625)
        at java.io.ObjectInputStream.defaultReadFields(ObjectInputStream.java:2342)
        at java.io.ObjectInputStream.readSerialData(ObjectInputStream.java:2266)
        at java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:2124)
        at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1625)
        at java.io.ObjectInputStream.readObject(ObjectInputStream.java:465)
        at java.io.ObjectInputStream.readObject(ObjectInputStream.java:423)
        at scala.collection.immutable.List$SerializationProxy.readObject(List.scala:490)
        at sun.reflect.GeneratedMethodAccessor8.invoke(Unknown Source)
        at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
        at java.lang.reflect.Method.invoke(Method.java:498)
        at java.io.ObjectStreamClass.invokeReadObject(ObjectStreamClass.java:1170)
        at java.io.ObjectInputStream.readSerialData(ObjectInputStream.java:2233)
        at java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:2124)
        at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1625)
        at java.io.ObjectInputStream.defaultReadFields(ObjectInputStream.java:2342)
        at java.io.ObjectInputStream.readSerialData(ObjectInputStream.java:2266)
        at java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:2124)
        at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1625)
        at java.io.ObjectInputStream.defaultReadFields(ObjectInputStream.java:2342)
        at java.io.ObjectInputStream.readSerialData(ObjectInputStream.java:2266)
        at java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:2124)
        at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1625)
        at java.io.ObjectInputStream.readObject(ObjectInputStream.java:465)
        at java.io.ObjectInputStream.readObject(ObjectInputStream.java:423)
        at scala.collection.immutable.List$SerializationProxy.readObject(List.scala:490)
        at sun.reflect.GeneratedMethodAccessor8.invoke(Unknown Source)
        at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
        at java.lang.reflect.Method.invoke(Method.java:498)
        at java.io.ObjectStreamClass.invokeReadObject(ObjectStreamClass.java:1170)
        at java.io.ObjectInputStream.readSerialData(ObjectInputStream.java:2233)
        at java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:2124)
        at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1625)
        at java.io.ObjectInputStream.defaultReadFields(ObjectInputStream.java:2342)
        at java.io.ObjectInputStream.readSerialData(ObjectInputStream.java:2266)
        at java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:2124)
        at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1625)
        at java.io.ObjectInputStream.defaultReadFields(ObjectInputStream.java:2342)
        at java.io.ObjectInputStream.readSerialData(ObjectInputStream.java:2266)
        at java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:2124)
        at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1625)
        at java.io.ObjectInputStream.readObject(ObjectInputStream.java:465)
        at java.io.ObjectInputStream.readObject(ObjectInputStream.java:423)
        at org.apache.spark.serializer.JavaDeserializationStream.readObject(JavaSerializer.scala:75)
        at org.apache.spark.serializer.JavaSerializerInstance.deserialize(JavaSerializer.scala:114)
        at org.apache.spark.scheduler.ResultTask.runTask(ResultTask.scala:83)
        at org.apache.spark.scheduler.Task.run(Task.scala:123)
        at org.apache.spark.executor.Executor$TaskRunner$$anonfun$10.org$apache$spark$executor$Executor$TaskRunner$$anonfun$$res$1(Executor.scala:412)
        at org.apache.spark.executor.Executor$TaskRunner$$anonfun$10.apply(Executor.scala:419)
        at org.apache.spark.util.Utils$.tryWithSafeFinally(Utils.scala:1359)
        at org.apache.spark.executor.Executor$TaskRunner.run(Executor.scala:430)
        at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
        at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
        at java.lang.Thread.run(Thread.java:748)