Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Flaky test TestCachingJdbcClient.testConcurrentSchemaCreateAndDrop #10933

Closed
hashhar opened this issue Feb 3, 2022 · 1 comment · Fixed by #10935
Closed

Flaky test TestCachingJdbcClient.testConcurrentSchemaCreateAndDrop #10933

hashhar opened this issue Feb 3, 2022 · 1 comment · Fixed by #10935
Labels
bug Something isn't working test

Comments

@hashhar
Copy link
Member

hashhar commented Feb 3, 2022

io.trino.plugin.jdbc.TestCachingJdbcClient.testConcurrentSchemaCreateAndDrop  Time elapsed: 0.087 s  <<< FAILURE!
com.google.common.util.concurrent.UncheckedExecutionException: 
io.trino.spi.TrinoException: General error: "java.lang.NullPointerException"; SQL statement:
SELECT SCHEMA_NAME TABLE_SCHEM, CATALOG_NAME TABLE_CATALOG,  IS_DEFAULT FROM INFORMATION_SCHEMA.SCHEMATA WHERE CATALOG_NAME LIKE ? ESCAPE ? AND SCHEMA_NAME LIKE ? ESCAPE ? ORDER BY SCHEMA_NAME [50000-200]
	at com.google.common.util.concurrent.Futures.wrapAndThrowUnchecked(Futures.java:1396)
	at com.google.common.util.concurrent.Futures.getUnchecked(Futures.java:1382)
	at java.base/java.util.ArrayList.forEach(ArrayList.java:1541)
	at io.trino.plugin.jdbc.TestCachingJdbcClient.testConcurrentSchemaCreateAndDrop(TestCachingJdbcClient.java:621)
	at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
	at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
	at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
	at java.base/java.lang.reflect.Method.invoke(Method.java:566)
	at org.testng.internal.MethodInvocationHelper.invokeMethod(MethodInvocationHelper.java:104)
	at org.testng.internal.InvokeMethodRunnable.runOne(InvokeMethodRunnable.java:54)
	at org.testng.internal.InvokeMethodRunnable.run(InvokeMethodRunnable.java:44)
	at java.base/java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:515)
	at java.base/java.util.concurrent.FutureTask.run(FutureTask.java:264)
	at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1128)
	at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:628)
	at java.base/java.lang.Thread.run(Thread.java:829)
Caused by: io.trino.spi.TrinoException: General error: "java.lang.NullPointerException"; SQL statement:
SELECT SCHEMA_NAME TABLE_SCHEM, CATALOG_NAME TABLE_CATALOG,  IS_DEFAULT FROM INFORMATION_SCHEMA.SCHEMATA WHERE CATALOG_NAME LIKE ? ESCAPE ? AND SCHEMA_NAME LIKE ? ESCAPE ? ORDER BY SCHEMA_NAME [50000-200]
	at io.trino.plugin.jdbc.BaseJdbcClient.listSchemas(BaseJdbcClient.java:155)
	at io.trino.plugin.jdbc.BaseJdbcClient.getSchemaNames(BaseJdbcClient.java:132)
	at io.trino.plugin.jdbc.ForwardingJdbcClient.getSchemaNames(ForwardingJdbcClient.java:71)
	at io.trino.plugin.jdbc.CachingJdbcClient.lambda$getSchemaNames$1(CachingJdbcClient.java:143)
	at io.trino.plugin.base.cache.EvictableCache.get(EvictableCache.java:109)
	at io.trino.plugin.jdbc.CachingJdbcClient.get(CachingJdbcClient.java:679)
	at io.trino.plugin.jdbc.CachingJdbcClient.getSchemaNames(CachingJdbcClient.java:143)
	at io.trino.plugin.jdbc.TestCachingJdbcClient.lambda$testConcurrentSchemaCreateAndDrop$44(TestCachingJdbcClient.java:614)
	... 4 more
Caused by: org.h2.jdbc.JdbcSQLNonTransientException: General error: "java.lang.NullPointerException"; SQL statement:
SELECT SCHEMA_NAME TABLE_SCHEM, CATALOG_NAME TABLE_CATALOG,  IS_DEFAULT FROM INFORMATION_SCHEMA.SCHEMATA WHERE CATALOG_NAME LIKE ? ESCAPE ? AND SCHEMA_NAME LIKE ? ESCAPE ? ORDER BY SCHEMA_NAME [50000-200]
	at org.h2.message.DbException.getJdbcSQLException(DbException.java:505)
	at org.h2.message.DbException.getJdbcSQLException(DbException.java:429)
	at org.h2.message.DbException.get(DbException.java:194)
	at org.h2.message.DbException.convert(DbException.java:347)
	at org.h2.command.Command.executeQuery(Command.java:212)
	at org.h2.jdbc.JdbcPreparedStatement.executeQuery(JdbcPreparedStatement.java:114)
	at org.h2.jdbc.JdbcDatabaseMetaData.getSchemas(JdbcDatabaseMetaData.java:3176)
	at io.trino.plugin.jdbc.BaseJdbcClient.listSchemas(BaseJdbcClient.java:143)
	... 11 more
Caused by: java.lang.NullPointerException
	at org.h2.table.MetaTable.generateRows(MetaTable.java:1515)
	at org.h2.index.MetaIndex.find(MetaIndex.java:51)
	at org.h2.index.BaseIndex.find(BaseIndex.java:148)
	at org.h2.index.IndexCursor.find(IndexCursor.java:163)
	at org.h2.table.TableFilter.next(TableFilter.java:498)
	at org.h2.command.dml.Select$LazyResultQueryFlat.fetchNextRow(Select.java:1843)
	at org.h2.result.LazyResult.hasNext(LazyResult.java:101)
	at org.h2.result.LazyResult.next(LazyResult.java:60)
	at org.h2.command.dml.Select.queryFlat(Select.java:737)
	at org.h2.command.dml.Select.queryWithoutCache(Select.java:844)
	at org.h2.command.dml.Query.queryWithoutCacheLazyCheck(Query.java:201)
	at org.h2.command.dml.Query.query(Query.java:489)
	at org.h2.command.dml.Query.query(Query.java:451)
	at org.h2.command.CommandContainer.query(CommandContainer.java:285)
	at org.h2.command.Command.executeQuery(Command.java:195)
	... 14 more

observed in https://github.com/trinodb/trino/runs/5048548001?check_suite_focus=true

cc: @kokosing

@findepi
Copy link
Member

findepi commented Feb 3, 2022

Reproduces locally
image

cc @kokosing

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working test
Development

Successfully merging a pull request may close this issue.

2 participants