spark-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From lordjoe <lordjoe2...@gmail.com>
Subject Re: java.io.NotSerializableException: org.apache.spark.SparkEnv
Date Tue, 04 Nov 2014 18:10:42 GMT
I posted on this issue in 
http://apache-spark-user-list.1001560.n3.nabble.com/How-to-access-objects-declared-and-initialized-outside-the-call-method-of-JavaRDD-td17094.html#a17150

Code starts
public class SparkUtilities extends Serializable 
private transient static ThreadLocal<JavaSparkContext> threadContext; 
    private static String appName = "Anonymous"; 

essentially you need to get a context on the slave machine saving it in a
transient (non serialized) field - at least that is what you want to do in
Java




--
View this message in context: http://apache-spark-user-list.1001560.n3.nabble.com/java-io-NotSerializableException-org-apache-spark-SparkEnv-tp10641p18072.html
Sent from the Apache Spark User List mailing list archive at Nabble.com.

---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@spark.apache.org
For additional commands, e-mail: user-help@spark.apache.org


Mime
View raw message