Skip to content
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@

package org.apache.spark.sql.catalyst.analysis

import java.util.concurrent.ConcurrentHashMap
import java.util.concurrent.{ConcurrentHashMap, ConcurrentMap}

import scala.collection.JavaConverters._
import scala.collection.mutable
Expand Down Expand Up @@ -80,7 +80,8 @@ trait Catalog {
}

class SimpleCatalog(val conf: CatalystConf) extends Catalog {
private[this] val tables = new ConcurrentHashMap[String, LogicalPlan]
private[this] val tables: ConcurrentMap[String, LogicalPlan] =
new ConcurrentHashMap[String, LogicalPlan]

override def registerTable(tableIdent: TableIdentifier, plan: LogicalPlan): Unit = {
tables.put(getTableName(tableIdent), plan)
Expand Down Expand Up @@ -129,7 +130,8 @@ class SimpleCatalog(val conf: CatalystConf) extends Catalog {
* lost when the JVM exits.
*/
trait OverrideCatalog extends Catalog {
private[this] val overrides = new ConcurrentHashMap[String, LogicalPlan]
private[this] val overrides: ConcurrentMap[String, LogicalPlan] =
new ConcurrentHashMap[String, LogicalPlan]

private def getOverriddenTable(tableIdent: TableIdentifier): Option[LogicalPlan] = {
if (tableIdent.database.isDefined) {
Expand Down