Skip to content

Commit

Permalink
fix compile issue
Browse files Browse the repository at this point in the history
  • Loading branch information
scwf committed Apr 30, 2015
1 parent 56034ca commit 5472b08
Show file tree
Hide file tree
Showing 6 changed files with 18 additions and 20 deletions.
14 changes: 7 additions & 7 deletions pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -192,7 +192,7 @@
<id>central</id>
<!-- This should be at top, it makes maven try the central repo first and then others and hence faster dep resolution -->
<name>Maven Repository</name>
<url>https://repo1.maven.org/maven2</url>
<url>http://repo1.maven.org/maven2</url>
<releases>
<enabled>true</enabled>
</releases>
Expand All @@ -203,7 +203,7 @@
<repository>
<id>apache-repo</id>
<name>Apache Repository</name>
<url>https://repository.apache.org/content/repositories/releases</url>
<url>http://repository.apache.org/content/repositories/releases</url>
<releases>
<enabled>true</enabled>
</releases>
Expand All @@ -214,7 +214,7 @@
<repository>
<id>jboss-repo</id>
<name>JBoss Repository</name>
<url>https://repository.jboss.org/nexus/content/repositories/releases</url>
<url>http://repository.jboss.org/nexus/content/repositories/releases</url>
<releases>
<enabled>true</enabled>
</releases>
Expand All @@ -225,7 +225,7 @@
<repository>
<id>mqtt-repo</id>
<name>MQTT Repository</name>
<url>https://repo.eclipse.org/content/repositories/paho-releases</url>
<url>http://repo.eclipse.org/content/repositories/paho-releases</url>
<releases>
<enabled>true</enabled>
</releases>
Expand All @@ -236,7 +236,7 @@
<repository>
<id>cloudera-repo</id>
<name>Cloudera Repository</name>
<url>https://repository.cloudera.com/artifactory/cloudera-repos</url>
<url>http://repository.cloudera.com/artifactory/cloudera-repos</url>
<releases>
<enabled>true</enabled>
</releases>
Expand All @@ -258,7 +258,7 @@
<repository>
<id>spring-releases</id>
<name>Spring Release Repository</name>
<url>https://repo.spring.io/libs-release</url>
<url>http://repo.spring.io/libs-release</url>
<releases>
<enabled>true</enabled>
</releases>
Expand All @@ -270,7 +270,7 @@
<pluginRepositories>
<pluginRepository>
<id>central</id>
<url>https://repo1.maven.org/maven2</url>
<url>http://repo1.maven.org/maven2</url>
<releases>
<enabled>true</enabled>
</releases>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -36,19 +36,21 @@ private[spark] trait CatalystConf {
* relations are already filled in and the analyser needs only to resolve attribute references.
*/
object EmptyConf extends CatalystConf {
def setConf(key: String, value: String) : Unit = {
override def caseSensitiveAnalysis: Boolean = true

override def setConf(key: String, value: String) : Unit = {
throw new UnsupportedOperationException
}

def getConf(key: String) : String = {
override def getConf(key: String) : String = {
throw new UnsupportedOperationException
}

def getConf(key: String, defaultValue: String) : String = {
override def getConf(key: String, defaultValue: String) : String = {
throw new UnsupportedOperationException
}

def getAllConfs: immutable.Map[String, String] = {
override def getAllConfs: immutable.Map[String, String] = {
throw new UnsupportedOperationException
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ import org.apache.spark.sql.types._
* when all relations are already filled in and the analyzer needs only to resolve attribute
* references.
*/
object SimpleAnalyzer extends Analyzer(EmptyCatalog, EmptyFunctionRegistry, new SimpleConf)
object SimpleAnalyzer extends Analyzer(EmptyCatalog, EmptyFunctionRegistry, new SimpleConf(true))

/**
* Provides a logical query plan analyzer, which translates [[UnresolvedAttribute]]s and
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -23,9 +23,11 @@ import scala.collection.immutable
import scala.collection.mutable

/** A CatalystConf that can be used for local testing. */
class SimpleConf(caseSensitiveAnalysis: Boolean) extends CatalystConf {
class SimpleConf(caseSensitive: Boolean) extends CatalystConf {
val map = mutable.Map[String, String]()

def caseSensitiveAnalysis: Boolean = caseSensitive

def setConf(key: String, value: String) : Unit = {
map.put(key, value)
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ import org.apache.spark.sql.catalyst.test.SimpleConf
import org.scalatest.{BeforeAndAfter, FunSuite}

class DecimalPrecisionSuite extends FunSuite with BeforeAndAfter {
val conf = new SimpleConf
val conf = new SimpleConf(true)
val catalog = new SimpleCatalog(conf)
val analyzer = new Analyzer(catalog, EmptyFunctionRegistry, conf)

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -21,13 +21,7 @@ import org.scalatest.BeforeAndAfterAll

import org.apache.spark.sql.execution.GeneratedAggregate
import org.apache.spark.sql.functions._
<<<<<<< HEAD
import org.apache.spark.sql.catalyst.CatalystConf
import org.apache.spark.sql.catalyst.errors.TreeNodeException
import org.apache.spark.sql.catalyst.plans.logical.LogicalPlan
import org.apache.spark.sql.types._
=======
>>>>>>> 254e0509762937acc9c72b432d5d953bf72c3c52
import org.apache.spark.sql.TestData._
import org.apache.spark.sql.test.TestSQLContext
import org.apache.spark.sql.test.TestSQLContext.{udf => _, _}
Expand Down

0 comments on commit 5472b08

Please sign in to comment.