开发者社区> 问答> 正文

canal在docker的swarm下报错

com.alibaba.otter.canal.parse.exception.CanalParseException: apply failed caused by : SqlMapClient operation; uncategorized SQLException for SQL []; SQL state [90098]; error code [90098]; --- The error occurred in spring/tsdb/sql-map/sqlmap_snapshot.xml. --- The error occurred while applying a parameter map. --- Check the meta_snapshot.findByTimestamp-InlineParameterMap. --- Check the statement (query failed). --- Cause: org.h2.jdbc.JdbcSQLException: The database has been closed [90098-196]; nested exception is com.ibatis.common.jdbc.exception.NestedSQLException: --- The error occurred in spring/tsdb/sql-map/sqlmap_snapshot.xml. --- The error occurred while applying a parameter map. --- Check the meta_snapshot.findByTimestamp-InlineParameterMap. --- Check the statement (query failed). --- Cause: org.h2.jdbc.JdbcSQLException: The database has been closed [90098-196] Caused by: org.springframework.jdbc.UncategorizedSQLException: SqlMapClient operation; uncategorized SQLException for SQL []; SQL state [90098]; error code [90098]; --- The error occurred in spring/tsdb/sql-map/sqlmap_snapshot.xml. --- The error occurred while applying a parameter map. --- Check the meta_snapshot.findByTimestamp-InlineParameterMap. --- Check the statement (query failed). --- Cause: org.h2.jdbc.JdbcSQLException: The database has been closed [90098-196]; nested exception is com.ibatis.common.jdbc.exception.NestedSQLException: --- The error occurred in spring/tsdb/sql-map/sqlmap_snapshot.xml. --- The error occurred while applying a parameter map. --- Check the meta_snapshot.findByTimestamp-InlineParameterMap. --- Check the statement (query failed). --- Cause: org.h2.jdbc.JdbcSQLException: The database has been closed [90098-196] at org.springframework.jdbc.support.AbstractFallbackSQLExceptionTranslator.translate(AbstractFallbackSQLExceptionTranslator.java:83) ~[spring-jdbc-3.2.18.RELEASE.jar:3.2.18.RELEASE] at org.springframework.jdbc.support.AbstractFallbackSQLExceptionTranslator.translate(AbstractFallbackSQLExceptionTranslator.java:80) ~[spring-jdbc-3.2.18.RELEASE.jar:3.2.18.RELEASE] at org.springframework.jdbc.support.AbstractFallbackSQLExceptionTranslator.translate(AbstractFallbackSQLExceptionTranslator.java:80) ~[spring-jdbc-3.2.18.RELEASE.jar:3.2.18.RELEASE] at org.springframework.orm.ibatis.SqlMapClientTemplate.execute(SqlMapClientTemplate.java:206) ~[spring-orm-3.2.18.RELEASE.jar:3.2.18.RELEASE] at org.springframework.orm.ibatis.SqlMapClientTemplate.queryForObject(SqlMapClientTemplate.java:271) ~[spring-orm-3.2.18.RELEASE.jar:3.2.18.RELEASE] at com.alibaba.otter.canal.parse.inbound.mysql.tsdb.dao.MetaSnapshotDAO.findByTimestamp(MetaSnapshotDAO.java:29) ~[canal.parse-1.1.4.jar:na] at com.alibaba.otter.canal.parse.inbound.mysql.tsdb.DatabaseTableMeta.buildMemFromSnapshot(DatabaseTableMeta.java:403) ~[canal.parse-1.1.4.jar:na] at com.alibaba.otter.canal.parse.inbound.mysql.tsdb.DatabaseTableMeta.rollback(DatabaseTableMeta.java:174) ~[canal.parse-1.1.4.jar:na] at com.alibaba.otter.canal.parse.inbound.mysql.AbstractMysqlEventParser.processTableMeta(AbstractMysqlEventParser.java:137) ~[canal.parse-1.1.4.jar:na] at com.alibaba.otter.canal.parse.inbound.AbstractEventParser$3.run(AbstractEventParser.java:200) ~[canal.parse-1.1.4.jar:na] at java.lang.Thread.run(Thread.java:748) [na:1.8.0_181] Caused by: com.ibatis.common.jdbc.exception.NestedSQLException: --- The error occurred in spring/tsdb/sql-map/sqlmap_snapshot.xml. --- The error occurred while applying a parameter map. --- Check the meta_snapshot.findByTimestamp-InlineParameterMap. --- Check the statement (query failed). --- Cause: org.h2.jdbc.JdbcSQLException: The database has been closed [90098-196] at com.ibatis.sqlmap.engine.mapping.statement.MappedStatement.executeQueryWithCallback(MappedStatement.java:201) ~[ibatis-sqlmap-2.3.4.726.jar:na] at com.ibatis.sqlmap.engine.mapping.statement.MappedStatement.executeQueryForObject(MappedStatement.java:120) ~[ibatis-sqlmap-2.3.4.726.jar:na] at com.ibatis.sqlmap.engine.impl.SqlMapExecutorDelegate.queryForObject(SqlMapExecutorDelegate.java:518) ~[ibatis-sqlmap-2.3.4.726.jar:na] at com.ibatis.sqlmap.engine.impl.SqlMapExecutorDelegate.queryForObject(SqlMapExecutorDelegate.java:493) ~[ibatis-sqlmap-2.3.4.726.jar:na] at com.ibatis.sqlmap.engine.impl.SqlMapSessionImpl.queryForObject(SqlMapSessionImpl.java:106) ~[ibatis-sqlmap-2.3.4.726.jar:na] at org.springframework.orm.ibatis.SqlMapClientTemplate$1.doInSqlMapClient(SqlMapClientTemplate.java:273) ~[spring-orm-3.2.18.RELEASE.jar:3.2.18.RELEASE] at org.springframework.orm.ibatis.SqlMapClientTemplate.execute(SqlMapClientTemplate.java:203) ~[spring-orm-3.2.18.RELEASE.jar:3.2.18.RELEASE] ... 7 common frames omitted Caused by: org.h2.jdbc.JdbcSQLException: The database has been closed [90098-196] at org.h2.message.DbException.getJdbcSQLException(DbException.java:345) ~[h2-1.4.196.jar:1.4.196] at org.h2.message.DbException.get(DbException.java:179) ~[h2-1.4.196.jar:1.4.196] at org.h2.message.DbException.get(DbException.java:155) ~[h2-1.4.196.jar:1.4.196] at org.h2.message.DbException.get(DbException.java:144) ~[h2-1.4.196.jar:1.4.196] at org.h2.engine.Database.checkPowerOff(Database.java:524) ~[h2-1.4.196.jar:1.4.196] at org.h2.command.Command.executeQuery(Command.java:227) ~[h2-1.4.196.jar:1.4.196] at org.h2.jdbc.JdbcPreparedStatement.execute(JdbcPreparedStatement.java:200) ~[h2-1.4.196.jar:1.4.196] at com.alibaba.druid.pool.DruidPooledPreparedStatement.execute(DruidPooledPreparedStatement.java:498) ~[druid-1.1.9.jar:1.1.9] at com.ibatis.sqlmap.engine.execution.SqlExecutor.executeQuery(SqlExecutor.java:185) ~[ibatis-sqlmap-2.3.4.726.jar:na] at com.ibatis.sqlmap.engine.mapping.statement.MappedStatement.sqlExecuteQuery(MappedStatement.java:221) ~[ibatis-sqlmap-2.3.4.726.jar:na] at com.ibatis.sqlmap.engine.mapping.statement.MappedStatement.executeQueryWithCallback(MappedStatement.java:189) ~[ibatis-sqlmap-2.3.4.726.jar:na] ... 13 common frames omitted 2019-11-04 08:43:44.348 [destination = example , address = /172.21.32.111:3306 , EventParser] ERROR com.alibaba.otter.canal.common.alarm.LogAlarmHandler - destination:example[com.alibaba.otter.canal.parse.exception.CanalParseException: apply failed caused by : SqlMapClient operation; uncategorized SQLException for SQL []; SQL state [90098]; error code [90098]; --- The error occurred in spring/tsdb/sql-map/sqlmap_snapshot.xml. --- The error occurred while applying a parameter map. --- Check the meta_snapshot.findByTimestamp-InlineParameterMap. --- Check the statement (query failed). --- Cause: org.h2.jdbc.JdbcSQLException: The database has been closed [90098-196]; nested exception is com.ibatis.common.jdbc.exception.NestedSQLException: --- The error occurred in spring/tsdb/sql-map/sqlmap_snapshot.xml. --- The error occurred while applying a parameter map. --- Check the meta_snapshot.findByTimestamp-InlineParameterMap. --- Check the statement (query failed). --- Cause: org.h2.jdbc.JdbcSQLException: The database has been closed [90098-196] Caused by: org.springframework.jdbc.UncategorizedSQLException: SqlMapClient operation; uncategorized SQLException for SQL []; SQL state [90098]; error code [90098]; --- The error occurred in spring/tsdb/sql-map/sqlmap_snapshot.xml. --- The error occurred while applying a parameter map. --- Check the meta_snapshot.findByTimestamp-InlineParameterMap. --- Check the statement (query failed). --- Cause: org.h2.jdbc.JdbcSQLException: The database has been closed [90098-196]; nested exception is com.ibatis.common.jdbc.exception.NestedSQLException: --- The error occurred in spring/tsdb/sql-map/sqlmap_snapshot.xml. --- The error occurred while applying a parameter map. --- Check the meta_snapshot.findByTimestamp-InlineParameterMap. --- Check the statement (query failed). --- Cause: org.h2.jdbc.JdbcSQLException: The database has been closed [90098-196] at org.springframework.jdbc.support.AbstractFallbackSQLExceptionTranslator.translate(AbstractFallbackSQLExceptionTranslator.java:83) at org.springframework.jdbc.support.AbstractFallbackSQLExceptionTranslator.translate(AbstractFallbackSQLExceptionTranslator.java:80) at org.springframework.jdbc.support.AbstractFallbackSQLExceptionTranslator.translate(AbstractFallbackSQLExceptionTranslator.java:80) at org.springframework.orm.ibatis.SqlMapClientTemplate.execute(SqlMapClientTemplate.java:206) at org.springframework.orm.ibatis.SqlMapClientTemplate.queryForObject(SqlMapClientTemplate.java:271) at com.alibaba.otter.canal.parse.inbound.mysql.tsdb.dao.MetaSnapshotDAO.findByTimestamp(MetaSnapshotDAO.java:29) at com.alibaba.otter.canal.parse.inbound.mysql.tsdb.DatabaseTableMeta.buildMemFromSnapshot(DatabaseTableMeta.java:403) at com.alibaba.otter.canal.parse.inbound.mysql.tsdb.DatabaseTableMeta.rollback(DatabaseTableMeta.java:174) at com.alibaba.otter.canal.parse.inbound.mysql.AbstractMysqlEventParser.processTableMeta(AbstractMysqlEventParser.java:137) at com.alibaba.otter.canal.parse.inbound.AbstractEventParser$3.run(AbstractEventParser.java:200) at java.lang.Thread.run(Thread.java:748) Caused by: com.ibatis.common.jdbc.exception.NestedSQLException: --- The error occurred in spring/tsdb/sql-map/sqlmap_snapshot.xml. --- The error occurred while applying a parameter map. --- Check the meta_snapshot.findByTimestamp-InlineParameterMap. --- Check the statement (query failed). --- Cause: org.h2.jdbc.JdbcSQLException: The database has been closed [90098-196] at com.ibatis.sqlmap.engine.mapping.statement.MappedStatement.executeQueryWithCallback(MappedStatement.java:201) at com.ibatis.sqlmap.engine.mapping.statement.MappedStatement.executeQueryForObject(MappedStatement.java:120) at com.ibatis.sqlmap.engine.impl.SqlMapExecutorDelegate.queryForObject(SqlMapExecutorDelegate.java:518) at com.ibatis.sqlmap.engine.impl.SqlMapExecutorDelegate.queryForObject(SqlMapExecutorDelegate.java:493) at com.ibatis.sqlmap.engine.impl.SqlMapSessionImpl.queryForObject(SqlMapSessionImpl.java:106) at org.springframework.orm.ibatis.SqlMapClientTemplate$1.doInSqlMapClient(SqlMapClientTemplate.java:273) at org.springframework.orm.ibatis.SqlMapClientTemplate.execute(SqlMapClientTemplate.java:203) ... 7 more Caused by: org.h2.jdbc.JdbcSQLException: The database has been closed [90098-196] at org.h2.message.DbException.getJdbcSQLException(DbException.java:345) at org.h2.message.DbException.get(DbException.java:179) at org.h2.message.DbException.get(DbException.java:155) at org.h2.message.DbException.get(DbException.java:144) at org.h2.engine.Database.checkPowerOff(Database.java:524) at org.h2.command.Command.executeQuery(Command.java:227) at org.h2.jdbc.JdbcPreparedStatement.execute(JdbcPreparedStatement.java:200) at com.alibaba.druid.pool.DruidPooledPreparedStatement.execute(DruidPooledPreparedStatement.java:498) at com.ibatis.sqlmap.engine.execution.SqlExecutor.executeQuery(SqlExecutor.java:185) at com.ibatis.sqlmap.engine.mapping.statement.MappedStatement.sqlExecuteQuery(MappedStatement.java:221) at com.ibatis.sqlmap.engine.mapping.statement.MappedStatement.executeQueryWithCallback(MappedStatement.java:189) ... 13 more ]

原提问者GitHub用户kervin521

展开
收起
Java工程师 2023-05-03 15:58:36 131 0
1 条回答
写回答
取消 提交回答
  • Caused by: org.h2.jdbc.JdbcSQLException: The database has been closed [90098-196]

    清空一下h2文件再重启吧

    原回答者GitHub用户agapple

    2023-05-04 17:07:58
    赞同 展开评论 打赏
问答排行榜
最热
最新

相关电子书

更多
应用 Docker 进行持续交付:用技术改变交付路程 立即下载
从Docker到容器服务 立即下载
Docker@Alibaba——超大规模Docker化的实战经验 立即下载