private JavaSparkContext createContext(){
  SparkConf conf=new SparkConf();
  conf.set("spark.executor.instances",String.valueOf(GRID_CNT));
  return new JavaSparkContext("local[" + GRID_CNT + "]","test",conf);
}

private JavaSparkContext createContext ( ) { SparkConf conf = new SparkConf ( ) ; conf . set ( "spark.executor.instances" , String . valueOf ( GRID_CNT ) ) ; return new JavaSparkContext ( "local[" + GRID_CNT + "]" , "test" , conf ) ; }
creates default spark context
