> On Jan. 16, 2016, 8:12 a.m., Lenni Kuff wrote:
> > sentry-tests/sentry-tests-hive/src/test/java/org/apache/sentry/tests/e2e/hive/AbstractTestWithStaticConfiguration.java,
> > line 504
> > <https://reviews.apache.org/r/42364/diff/2/?file=1199038#file1199038line504>
> >
> > Do we want to swallow the exception here and on lne 525?
The reason to swallow is because our testing cluster/enviroments are not well
created, they are havig issues with cm created monitoring tables. These cm
created tables occasionally pop up when sentry tests are cleaning up
databases/tables, when sentry tests actually delete them, exceptions occurred.
It causes many e2e test failures. I need to spend time investigating why these
cm tables get visible, but before it, in a normal situation, we never have
cleanup exceptions unless the sentry/hive servers are encountering serious
issues, which worthy a furthur debug.
org.apache.hive.service.cli.HiveSQLException: Error while compiling statement:
FAILED: SemanticException [Error 10001]: Table not found cm_test_table
at org.apache.hive.jdbc.Utils.verifySuccess(Utils.java:235)
at org.apache.hive.jdbc.Utils.verifySuccessWithInfo(Utils.java:221)
at org.apache.hive.jdbc.HiveStatement.execute(HiveStatement.java:244)
at
org.apache.sentry.tests.e2e.hive.AbstractTestWithStaticConfiguration.clearAll(AbstractTestWithStaticConfiguration.java:484)
at
org.apache.sentry.tests.e2e.hive.AbstractTestWithStaticConfiguration.clearAfterPerTest(AbstractTestWithStaticConfiguration.java:463)
at sun.reflect.GeneratedMethodAccessor21.invoke(Unknown Source)
at
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:606)
at
org.junit.runners.model.FrameworkMethod$1.runReflectiveCall(FrameworkMethod.java:45)
at
org.junit.internal.runners.model.ReflectiveCallable.run(ReflectiveCallable.java:15)
at
org.junit.runners.model.FrameworkMethod.invokeExplosively(FrameworkMethod.java:42)
at
org.junit.internal.runners.statements.RunAfters.evaluate(RunAfters.java:36)
at org.junit.runners.ParentRunner.runLeaf(ParentRunner.java:263)
at
org.junit.runners.BlockJUnit4ClassRunner.runChild(BlockJUnit4ClassRunner.java:68)
at
org.junit.runners.BlockJUnit4ClassRunner.runChild(BlockJUnit4ClassRunner.java:47)
at org.junit.runners.ParentRunner$3.run(ParentRunner.java:231)
at org.junit.runners.ParentRunner$1.schedule(ParentRunner.java:60)
at org.junit.runners.ParentRunner.runChildren(ParentRunner.java:229)
at org.junit.runners.ParentRunner.access$000(ParentRunner.java:50)
at org.junit.runners.ParentRunner$2.evaluate(ParentRunner.java:222)
at
org.junit.internal.runners.statements.RunBefores.evaluate(RunBefores.java:28)
at
org.junit.internal.runners.statements.RunAfters.evaluate(RunAfters.java:30)
at org.junit.runners.ParentRunner.run(ParentRunner.java:300)
at
org.apache.maven.surefire.junit4.JUnit4Provider.execute(JUnit4Provider.java:264)
at
org.apache.maven.surefire.junit4.JUnit4Provider.executeTestSet(JUnit4Provider.java:153)
at
org.apache.maven.surefire.junit4.JUnit4Provider.invoke(JUnit4Provider.java:124)
at
org.apache.maven.surefire.booter.ForkedBooter.invokeProviderInSameClassLoader(ForkedBooter.java:200)
at
org.apache.maven.surefire.booter.ForkedBooter.runSuitesInProcess(ForkedBooter.java:153)
at
org.apache.maven.surefire.booter.ForkedBooter.main(ForkedBooter.java:103)
Caused by: org.apache.hive.service.cli.HiveSQLException: Error while compiling
statement: FAILED: SemanticException [Error 10001]: Table not found
cm_test_table
- Anne
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/42364/#review114849
-----------------------------------------------------------
On Jan. 16, 2016, 12:11 a.m., Anne Yu wrote:
>
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/42364/
> -----------------------------------------------------------
>
> (Updated Jan. 16, 2016, 12:11 a.m.)
>
>
> Review request for sentry and Hao Hao.
>
>
> Bugs: SENTRY-1009
> https://issues.apache.org/jira/browse/SENTRY-1009
>
>
> Repository: sentry
>
>
> Description
> -------
>
> We started to see many TestDatabaseProvider test failures because it
> validates number of test objects instead of test object names. Because there
> are some system roles created in the environment, so the number of objects
> are usually larger than expected. Improved the test cases. Also catch the
> exception whenever cleanup fails since we don't need to do anything.
>
>
> Diffs
> -----
>
>
> sentry-tests/sentry-tests-hive/src/test/java/org/apache/sentry/tests/e2e/dbprovider/TestDatabaseProvider.java
> 98de57d3d749c3f887632ff1461ef05dd29376c1
>
> sentry-tests/sentry-tests-hive/src/test/java/org/apache/sentry/tests/e2e/hive/AbstractTestWithStaticConfiguration.java
> dc8c1eb802adbf198e8623b02bd77bb8aff7fa41
>
> Diff: https://reviews.apache.org/r/42364/diff/
>
>
> Testing
> -------
>
> mvn test -Dtest=TestDatabaseProvider passed locally testing enviroments.
>
>
> Thanks,
>
> Anne Yu
>
>