cloud-fan commented on a change in pull request #25771: [SPARK-28970][SQL] 
Implement USE CATALOG/NAMESPACE for Data Source V2
URL: https://github.com/apache/spark/pull/25771#discussion_r325966998
 
 

 ##########
 File path: 
sql/catalyst/src/main/scala/org/apache/spark/sql/catalyst/analysis/Analyzer.scala
 ##########
 @@ -60,22 +60,10 @@ object SimpleAnalyzer extends Analyzer(
   },
   new SQLConf().copy(SQLConf.CASE_SENSITIVE -> true))
 
-object FakeV2SessionCatalog extends TableCatalog {
+object FakeV2SessionCatalog extends CatalogPlugin {
   private def fail() = throw new UnsupportedOperationException
-  override def listTables(namespace: Array[String]): Array[Identifier] = fail()
-  override def loadTable(ident: Identifier): Table = {
-    throw new NoSuchTableException(ident.toString)
-  }
-  override def createTable(
-      ident: Identifier,
-      schema: StructType,
-      partitions: Array[Transform],
-      properties: util.Map[String, String]): Table = fail()
-  override def alterTable(ident: Identifier, changes: TableChange*): Table = 
fail()
-  override def dropTable(ident: Identifier): Boolean = fail()
-  override def renameTable(oldIdent: Identifier, newIdent: Identifier): Unit = 
fail()
   override def initialize(name: String, options: CaseInsensitiveStringMap): 
Unit = fail()
-  override def name(): String = fail()
+  override def name(): String = "fake_v2_session"
 
 Review comment:
   I think the name should be `CatalogManager.SESSION_CATALOG_NAME`

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


With regards,
Apache Git Services

---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscr...@spark.apache.org
For additional commands, e-mail: reviews-h...@spark.apache.org

Reply via email to