Skip to content

Conversation

@windpiger
Copy link
Contributor

What changes were proposed in this pull request?

merge renameTable to alterTable in ExternalCatalog has some reasons:

In Hive, we rename a Table by alterTable
Currently when we create / rename a managed table, we should get the defaultTablePath for them in ExternalCatalog, then we have two defaultTablePath logic in its two subclass HiveExternalCatalog and InMemoryCatalog, additionally there is also a defaultTablePath in SessionCatalog, so till now we have three defaultTablePath in three classes.
we'd better to unify them up to SessionCatalog
To unify them, we should move some logic from ExternalCatalog to SessionCatalog, renameTable is one of this.

while limit to the simple parameters in renameTable

  def renameTable(db: String, oldName: String, newName: String): Unit

even if we move the defaultTablePath logic to SessionCatalog, we can not pass it to renameTable.

So we can merge the renameTable to alterTable, and rename it in alterTable.

How was this patch tested?

delete some tests in ExternalCatalogSuite which already existed in SessionCatalogSuite,
and move some other tests in ExternalCatalogSuite which does not exist in SessionCatalogSuite

@SparkQA
Copy link

SparkQA commented Apr 21, 2017

Test build #76038 has finished for PR 17721 at commit 2ea645c.

  • This patch fails Scala style tests.
  • This patch does not merge cleanly.
  • This patch adds no public classes.

@hvanhovell
Copy link
Contributor

@windpiger could you make sure that the freshly added events still work after this change.

@HyukjinKwon
Copy link
Member

ping @windpiger

@gatorsmile
Copy link
Member

We are closing it due to inactivity. please do reopen if you want to push it forward. Thanks!

@asfgit asfgit closed this in b32bd00 Jun 27, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants