Skip to content

Commit

Permalink
getAbsolutePath
Browse files Browse the repository at this point in the history
  • Loading branch information
marmbrus committed May 7, 2015
1 parent 5a259f5 commit e56fd4a
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 6 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -74,11 +74,6 @@ private[hive] object SparkSQLCLIDriver {
System.exit(1)
}

val localMetastore = {
val temp = Utils.createTempDir()
temp.delete()
temp
}
val cliConf = new HiveConf(classOf[SessionState])
// Override the location of the metastore since this is only used for local execution.
HiveContext.newTemporaryConfiguration().foreach {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -465,7 +465,7 @@ private[hive] object HiveContext {
/** Constructs a configuration for hive, where the metastore is located in a temp directory. */
def newTemporaryConfiguration(): Map[String, String] = {
val tempDir = Utils.createTempDir()
val localMetastore = new File(tempDir, "metastore")
val localMetastore = new File(tempDir, "metastore").getAbsolutePath
Map(
"javax.jdo.option.ConnectionURL" -> s"jdbc:derby:;databaseName=$localMetastore;create=true")
}
Expand Down

0 comments on commit e56fd4a

Please sign in to comment.