View Revisions: Issue #4920

Summary 0004920: Initial load blocking
Revision 2021-04-06 12:53 by elong
Description Initial load won't start because it can't get next batch number due to some kind of blocking. Appears to affect SQL-Server the most. As a workaround, set datareload.batch.insert.transactional=false parameter.

2021-03-25 22:16:16,560 ERROR [AWSSASMSSQL] [InitialLoadService] [AWSSASMSSQL-job-3] Error while queuing initial loads StackTraceKey.init [SqlException:751401462] org.jumpmind.db.sql.SqlException: The query has timed out.
    at org.jumpmind.db.sql.AbstractSqlTemplate.translate(AbstractSqlTemplate.java:306)
    at org.jumpmind.db.sql.AbstractSqlTemplate.translate(AbstractSqlTemplate.java:295)
    at org.jumpmind.db.sql.JdbcSqlTransaction.executeCallback(JdbcSqlTransaction.java:398)
    at org.jumpmind.db.sql.JdbcSqlTransaction.queryForObject(JdbcSqlTransaction.java:217)
    at org.jumpmind.db.sql.JdbcSqlTransaction.queryForLong(JdbcSqlTransaction.java:209)
    at org.jumpmind.symmetric.service.impl.SequenceService.currVal(SequenceService.java:289)
    at org.jumpmind.symmetric.service.impl.SequenceService.tryToGetNextVal(SequenceService.java:154)
    at org.jumpmind.symmetric.service.impl.SequenceService.nextValFromDatabase(SequenceService.java:141)
    at org.jumpmind.symmetric.service.impl.SequenceService$2.execute(SequenceService.java:128)
    at org.jumpmind.symmetric.service.impl.SequenceService$2.execute(SequenceService.java:126)
    at org.jumpmind.symmetric.service.impl.SequenceService$DoTransaction.execute(SequenceService.java:364)
    at org.jumpmind.symmetric.service.impl.SequenceService.nextValFromDatabase(SequenceService.java:130)
    at org.jumpmind.symmetric.service.impl.SequenceService.nextRange(SequenceService.java:239)
    at org.jumpmind.symmetric.service.impl.SequenceService.nextRange(SequenceService.java:251)
    at org.jumpmind.symmetric.service.impl.DataService.insertRequestedOutgoingBatches(DataService.java:696)
    at org.jumpmind.symmetric.service.impl.DataService.insertLoadBatchesForReload(DataService.java:1535)
    at org.jumpmind.symmetric.service.impl.DataService.insertReloadEvents(DataService.java:1022)
    at org.jumpmind.symmetric.service.impl.InitialLoadService.processTableRequestLoads(InitialLoadService.java:282)
    at org.jumpmind.symmetric.service.impl.InitialLoadService.queueLoads(InitialLoadService.java:98)
    at org.jumpmind.symmetric.job.InitialLoadJob.doJob(InitialLoadJob.java:43)
    at org.jumpmind.symmetric.job.AbstractJob.invoke(AbstractJob.java:227)
    at org.jumpmind.symmetric.job.AbstractJob.run(AbstractJob.java:298)
    at org.springframework.scheduling.support.DelegatingErrorHandlingRunnable.run(DelegatingErrorHandlingRunnable.java:54)
    at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511)
    at java.util.concurrent.FutureTask.runAndReset(FutureTask.java:308)
    at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.access$301(ScheduledThreadPoolExecutor.java:180)
    at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:294)
    at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
    at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
    at java.lang.Thread.run(Thread.java:748)
Caused by: java.sql.SQLTimeoutException: The query has timed out.
    at net.sourceforge.jtds.jdbc.TdsCore.wait(TdsCore.java:4131)
    at net.sourceforge.jtds.jdbc.TdsCore.executeSQL(TdsCore.java:1086)
    at net.sourceforge.jtds.jdbc.MSCursorResultSet.cursorCreate(MSCursorResultSet.java:536)
    at net.sourceforge.jtds.jdbc.MSCursorResultSet.<init>(MSCursorResultSet.java:154)
    at net.sourceforge.jtds.jdbc.JtdsStatement.executeSQLQuery(JtdsStatement.java:452)
    at net.sourceforge.jtds.jdbc.JtdsPreparedStatement.executeQuery(JtdsPreparedStatement.java:1029)
    at org.apache.commons.dbcp.DelegatingPreparedStatement.executeQuery(DelegatingPreparedStatement.java:96)
    at org.apache.commons.dbcp.DelegatingPreparedStatement.executeQuery(DelegatingPreparedStatement.java:96)
    at org.jumpmind.db.sql.JdbcSqlTransaction$1.execute(JdbcSqlTransaction.java:230)
    at org.jumpmind.db.sql.JdbcSqlTransaction.executeCallback(JdbcSqlTransaction.java:396)
    ... 27 more
Revision 2021-03-25 23:10 by elong
Description Initial load won't start because it can't get next batch number due to some kind of blocking.

2021-03-25 22:16:16,560 ERROR [AWSSASMSSQL] [InitialLoadService] [AWSSASMSSQL-job-3] Error while queuing initial loads StackTraceKey.init [SqlException:751401462] org.jumpmind.db.sql.SqlException: The query has timed out.
    at org.jumpmind.db.sql.AbstractSqlTemplate.translate(AbstractSqlTemplate.java:306)
    at org.jumpmind.db.sql.AbstractSqlTemplate.translate(AbstractSqlTemplate.java:295)
    at org.jumpmind.db.sql.JdbcSqlTransaction.executeCallback(JdbcSqlTransaction.java:398)
    at org.jumpmind.db.sql.JdbcSqlTransaction.queryForObject(JdbcSqlTransaction.java:217)
    at org.jumpmind.db.sql.JdbcSqlTransaction.queryForLong(JdbcSqlTransaction.java:209)
    at org.jumpmind.symmetric.service.impl.SequenceService.currVal(SequenceService.java:289)
    at org.jumpmind.symmetric.service.impl.SequenceService.tryToGetNextVal(SequenceService.java:154)
    at org.jumpmind.symmetric.service.impl.SequenceService.nextValFromDatabase(SequenceService.java:141)
    at org.jumpmind.symmetric.service.impl.SequenceService$2.execute(SequenceService.java:128)
    at org.jumpmind.symmetric.service.impl.SequenceService$2.execute(SequenceService.java:126)
    at org.jumpmind.symmetric.service.impl.SequenceService$DoTransaction.execute(SequenceService.java:364)
    at org.jumpmind.symmetric.service.impl.SequenceService.nextValFromDatabase(SequenceService.java:130)
    at org.jumpmind.symmetric.service.impl.SequenceService.nextRange(SequenceService.java:239)
    at org.jumpmind.symmetric.service.impl.SequenceService.nextRange(SequenceService.java:251)
    at org.jumpmind.symmetric.service.impl.DataService.insertRequestedOutgoingBatches(DataService.java:696)
    at org.jumpmind.symmetric.service.impl.DataService.insertLoadBatchesForReload(DataService.java:1535)
    at org.jumpmind.symmetric.service.impl.DataService.insertReloadEvents(DataService.java:1022)
    at org.jumpmind.symmetric.service.impl.InitialLoadService.processTableRequestLoads(InitialLoadService.java:282)
    at org.jumpmind.symmetric.service.impl.InitialLoadService.queueLoads(InitialLoadService.java:98)
    at org.jumpmind.symmetric.job.InitialLoadJob.doJob(InitialLoadJob.java:43)
    at org.jumpmind.symmetric.job.AbstractJob.invoke(AbstractJob.java:227)
    at org.jumpmind.symmetric.job.AbstractJob.run(AbstractJob.java:298)
    at org.springframework.scheduling.support.DelegatingErrorHandlingRunnable.run(DelegatingErrorHandlingRunnable.java:54)
    at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511)
    at java.util.concurrent.FutureTask.runAndReset(FutureTask.java:308)
    at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.access$301(ScheduledThreadPoolExecutor.java:180)
    at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:294)
    at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
    at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
    at java.lang.Thread.run(Thread.java:748)
Caused by: java.sql.SQLTimeoutException: The query has timed out.
    at net.sourceforge.jtds.jdbc.TdsCore.wait(TdsCore.java:4131)
    at net.sourceforge.jtds.jdbc.TdsCore.executeSQL(TdsCore.java:1086)
    at net.sourceforge.jtds.jdbc.MSCursorResultSet.cursorCreate(MSCursorResultSet.java:536)
    at net.sourceforge.jtds.jdbc.MSCursorResultSet.<init>(MSCursorResultSet.java:154)
    at net.sourceforge.jtds.jdbc.JtdsStatement.executeSQLQuery(JtdsStatement.java:452)
    at net.sourceforge.jtds.jdbc.JtdsPreparedStatement.executeQuery(JtdsPreparedStatement.java:1029)
    at org.apache.commons.dbcp.DelegatingPreparedStatement.executeQuery(DelegatingPreparedStatement.java:96)
    at org.apache.commons.dbcp.DelegatingPreparedStatement.executeQuery(DelegatingPreparedStatement.java:96)
    at org.jumpmind.db.sql.JdbcSqlTransaction$1.execute(JdbcSqlTransaction.java:230)
    at org.jumpmind.db.sql.JdbcSqlTransaction.executeCallback(JdbcSqlTransaction.java:396)
    ... 27 more