diff options
author | Andrew Or <andrew@databricks.com> | 2016-03-24 22:59:35 -0700 |
---|---|---|
committer | Andrew Or <andrew@databricks.com> | 2016-03-24 22:59:35 -0700 |
commit | 20ddf5fddf40b543edc61d6e4687988489dea64c (patch) | |
tree | 9bfac66a6e754af29b06ce5529a473795c005a8e /sql/hive/compatibility/src/test/scala | |
parent | 1c70b7650f21fc51a07db1e4f28cebbc1fb47e94 (diff) | |
download | spark-20ddf5fddf40b543edc61d6e4687988489dea64c.tar.gz spark-20ddf5fddf40b543edc61d6e4687988489dea64c.tar.bz2 spark-20ddf5fddf40b543edc61d6e4687988489dea64c.zip |
[SPARK-14014][SQL] Integrate session catalog (attempt #2)
## What changes were proposed in this pull request?
This reopens #11836, which was merged but promptly reverted because it introduced flaky Hive tests.
## How was this patch tested?
See `CatalogTestCases`, `SessionCatalogSuite` and `HiveContextSuite`.
Author: Andrew Or <andrew@databricks.com>
Closes #11938 from andrewor14/session-catalog-again.
Diffstat (limited to 'sql/hive/compatibility/src/test/scala')
-rw-r--r-- | sql/hive/compatibility/src/test/scala/org/apache/spark/sql/hive/execution/HiveCompatibilitySuite.scala | 23 |
1 files changed, 13 insertions, 10 deletions
diff --git a/sql/hive/compatibility/src/test/scala/org/apache/spark/sql/hive/execution/HiveCompatibilitySuite.scala b/sql/hive/compatibility/src/test/scala/org/apache/spark/sql/hive/execution/HiveCompatibilitySuite.scala index 05f59f1545..650797f768 100644 --- a/sql/hive/compatibility/src/test/scala/org/apache/spark/sql/hive/execution/HiveCompatibilitySuite.scala +++ b/sql/hive/compatibility/src/test/scala/org/apache/spark/sql/hive/execution/HiveCompatibilitySuite.scala @@ -60,16 +60,19 @@ class HiveCompatibilitySuite extends HiveQueryFileTest with BeforeAndAfter { } override def afterAll() { - TestHive.cacheTables = false - TimeZone.setDefault(originalTimeZone) - Locale.setDefault(originalLocale) - TestHive.setConf(SQLConf.COLUMN_BATCH_SIZE, originalColumnBatchSize) - TestHive.setConf(SQLConf.IN_MEMORY_PARTITION_PRUNING, originalInMemoryPartitionPruning) - TestHive.sessionState.functionRegistry.restore() - - // For debugging dump some statistics about how much time was spent in various optimizer rules. - logWarning(RuleExecutor.dumpTimeSpent()) - super.afterAll() + try { + TestHive.cacheTables = false + TimeZone.setDefault(originalTimeZone) + Locale.setDefault(originalLocale) + TestHive.setConf(SQLConf.COLUMN_BATCH_SIZE, originalColumnBatchSize) + TestHive.setConf(SQLConf.IN_MEMORY_PARTITION_PRUNING, originalInMemoryPartitionPruning) + TestHive.sessionState.functionRegistry.restore() + + // For debugging dump some statistics about how much time was spent in various optimizer rules. + logWarning(RuleExecutor.dumpTimeSpent()) + } finally { + super.afterAll() + } } /** A list of tests deemed out of scope currently and thus completely disregarded. */ |