-
Task
-
Resolution: Done
-
Major
-
2.6.0.Alpha2
-
None
-
False
-
None
-
False
-
-
When running DebeziumServerWithApicurioIT with new async engine, the test fails with
2024-02-19 23:03:02,561 ERROR [io.deb.emb.asy.AsyncEmbeddedEngine] (pool-9-thread-1) Engine has failed with : java.util.concurrent.ExecutionException: java.util.concurrent.ExecutionException: io.apicurio.registry.rest.client.exception.RestClientException: io.apicurio.registry.storage.impl.sql.jdb.RuntimeSqlException: org.h2.jdbc.JdbcSQLTimeoutException: Timeout trying to lock table {0}; SQL statement: INSERT INTO sequences (tenantId, name, seq_value) VALUES (?, ?, ?) [50200-220] at java.base/java.util.concurrent.FutureTask.report(FutureTask.java:122) at java.base/java.util.concurrent.FutureTask.get(FutureTask.java:191) at io.debezium.embedded.async.AsyncEmbeddedEngine.runTasksPolling(AsyncEmbeddedEngine.java:454) at io.debezium.embedded.async.AsyncEmbeddedEngine.run(AsyncEmbeddedEngine.java:204) at io.debezium.server.DebeziumServer.lambda$start$1(DebeziumServer.java:174) at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1144) at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:642) at java.base/java.lang.Thread.run(Thread.java:1583) Caused by: java.util.concurrent.ExecutionException: io.apicurio.registry.rest.client.exception.RestClientException: io.apicurio.registry.storage.impl.sql.jdb.RuntimeSqlException: org.h2.jdbc.JdbcSQLTimeoutException: Timeout trying to lock table {0}; SQL statement: INSERT INTO sequences (tenantId, name, seq_value) VALUES (?, ?, ?) [50200-220] at java.base/java.util.concurrent.FutureTask.report(FutureTask.java:122) at java.base/java.util.concurrent.FutureTask.get(FutureTask.java:191) at io.debezium.embedded.async.ParallelSmtAndConvertBatchProcessor.processRecords(ParallelSmtAndConvertBatchProcessor.java:49) at io.debezium.embedded.async.AsyncEmbeddedEngine$PollRecords.doCall(AsyncEmbeddedEngine.java:1122) at io.debezium.embedded.async.AsyncEmbeddedEngine$PollRecords.doCall(AsyncEmbeddedEngine.java:1103) at io.debezium.embedded.async.RetryingCallable.call(RetryingCallable.java:47) at java.base/java.util.concurrent.FutureTask.run(FutureTask.java:317) at java.base/java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:572) at java.base/java.util.concurrent.FutureTask.run(FutureTask.java:317) ... 3 more Caused by: io.apicurio.registry.rest.client.exception.RestClientException: io.apicurio.registry.storage.impl.sql.jdb.RuntimeSqlException: org.h2.jdbc.JdbcSQLTimeoutException: Timeout trying to lock table {0}; SQL statement: INSERT INTO sequences (tenantId, name, seq_value) VALUES (?, ?, ?) [50200-220] at io.apicurio.registry.rest.client.impl.ErrorHandler.handleErrorResponse(ErrorHandler.java:64) at io.apicurio.rest.client.handler.BodyHandler.lambda$toSupplierOfType$1(BodyHandler.java:54) at io.apicurio.rest.client.JdkHttpClient.sendRequest(JdkHttpClient.java:204) at io.apicurio.registry.rest.client.impl.RegistryClientImpl.createArtifact(RegistryClientImpl.java:311) at io.apicurio.registry.rest.client.RegistryClient.createArtifact(RegistryClient.java:147) at io.apicurio.registry.resolver.DefaultSchemaResolver.lambda$handleAutoCreateArtifact$3(DefaultSchemaResolver.java:270) at io.apicurio.registry.resolver.ERCache.lambda$getValue$0(ERCache.java:156) at io.apicurio.registry.resolver.ERCache.retry(ERCache.java:197) at io.apicurio.registry.resolver.ERCache.getValue(ERCache.java:155) at io.apicurio.registry.resolver.ERCache.getByContent(ERCache.java:130) at io.apicurio.registry.resolver.DefaultSchemaResolver.handleAutoCreateArtifact(DefaultSchemaResolver.java:268) at io.apicurio.registry.resolver.DefaultSchemaResolver.getSchemaFromRegistry(DefaultSchemaResolver.java:119) at io.apicurio.registry.resolver.DefaultSchemaResolver.resolveSchema(DefaultSchemaResolver.java:90) at io.apicurio.registry.utils.converter.ExtJsonConverter.fromConnectData(ExtJsonConverter.java:97) at io.apicurio.registry.utils.converter.ExtJsonConverter.fromConnectData(ExtJsonConverter.java:87) at io.debezium.embedded.ConverterBuilder.lambda$toFormat$2(ConverterBuilder.java:101) at io.debezium.embedded.async.ProcessingCallables$TransformAndConvertRecord.call(ProcessingCallables.java:81) ... 4 more
Right now it's not very clear where exactly the issue is as it fails with the same exception also with LOCK_MODE=0 which should disbale H2 locking. Anyway, the issue seems to be either in Apicurio or in H2, so until tracked down and fixed, we need to disable processing of the records in multiple threads.
- relates to
-
DBZ-7518 Run DBZ server tests in mutiple threads
- Open