Skip to content

Commit

Permalink
Update ClaimGeneratorSparkHelper.scala
Browse files Browse the repository at this point in the history
  • Loading branch information
cpp-cat committed Jan 14, 2015
1 parent bd9b2b8 commit a55810b
Showing 1 changed file with 6 additions and 6 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -48,11 +48,11 @@ object ClaimGeneratorSparkHelper {
*/
def generateClaims(generator: ClaimGeneratorHelper, configTxt: String): ClaimGeneratorCounts = {

val conf = new SparkConf()
var conf = new SparkConf()
.setMaster(SparkConfig.master)
.setAppName(SparkConfig.appName)
.set("spark.executorEnv.BC4ME_DATA_DIR", SparkConfig.dataDir)
.set("spark.executorEnv.BC4ME_CASSANDRA_CONFIG", SparkConfig.cassandraConf)
if(SparkConfig.dataDir != "") conf = conf.set("spark.executorEnv.BC4ME_DATA_DIR", SparkConfig.dataDir)
if(SparkConfig.cassandraConf != "") conf = conf.set("spark.executorEnv.BC4ME_CASSANDRA_CONFIG", SparkConfig.cassandraConf)

val sc = new SparkContext(conf)
Logger.info("generateClaims: Spark master: " + sc.master)
Expand Down Expand Up @@ -93,11 +93,11 @@ object ClaimGeneratorSparkHelper {

def processGeneratedClaims(generator: ClaimGeneratorHelper, configTxt: String): HEDISScoreSummary = {

val conf = new SparkConf()
var conf = new SparkConf()
.setMaster(SparkConfig.master)
.setAppName(SparkConfig.appName)
.set("spark.executorEnv.BC4ME_DATA_DIR", SparkConfig.dataDir)
.set("spark.executorEnv.BC4ME_CASSANDRA_CONFIG", SparkConfig.cassandraConf)
if(SparkConfig.dataDir != "") conf = conf.set("spark.executorEnv.BC4ME_DATA_DIR", SparkConfig.dataDir)
if(SparkConfig.cassandraConf != "") conf = conf.set("spark.executorEnv.BC4ME_CASSANDRA_CONFIG", SparkConfig.cassandraConf)

val sc = new SparkContext(conf)
Logger.info("processGeneratedClaims: Spark master: " + sc.master)
Expand Down

0 comments on commit a55810b

Please sign in to comment.