java.lang.ClassCastException using lambda expressions in spark job on remote server
What you have here, is a follow-up error which masks the original error. When lambda instances are serialized, they use writeReplace to dissolve their JRE specific implementation from the persistent form which is a SerializedLambda instance. When the SerializedLambda instance has been restored, its readResolve method will be invoked to reconstitute the appropriate lambda instance. … Read more