Survey
* Your assessment is very important for improving the workof artificial intelligence, which forms the content of this project
* Your assessment is very important for improving the workof artificial intelligence, which forms the content of this project
[QTZ-478] When disk space is full, there will be a problem! Created: 17/May/15 Updated: 17/May/15 Status: Project: Component/s: Affects Version/s: Fix Version/s: New Quartz Scheduler (Historical - Do Not File New Issues Here - See GitHub) JDBC JobStores 2.1.7 Type: Reporter: Resolution: Labels: Remaining Estimate: Time Spent: Original Estimate: Bug xing wei Unresolved None Not Specified Terracotta Target: Bug Found In Detail: Unknown None Priority: Assignee: Votes: 2 Major Issue Review Board 0 Not Specified Not Specified quartz-all-2.1.7.jar Description Will use quartz to schedule out timed-jobs, we found a problem(possible is a bug). When the disk sapce is full, t database(Database is on the same server), so the transaction will't commit, the data of table fired_triggers will no be excute even then the disk has clean up! Othes jobs work fine. If restart the process, it can be resume.During th automatically. org.quartz.JobPersistenceException: Couldn't acquire next trigger: No operations allowed after connection close com.mysql.jdbc.exceptions.jdbc4.MySQLNonTransientConnectionException: No operations allowed after conn at org.quartz.impl.jdbcjobstore.JobStoreSupport.acquireNextTrigger(JobStoreSupport.java:2827) at org.quartz.impl.jdbcjobstore.JobStoreSupport$40.execute(JobStoreSupport.java:2746) at org.quartz.impl.jdbcjobstore.JobStoreSupport.executeInNonManagedTXLock(JobStoreSupport.java:3798) at org.quartz.impl.jdbcjobstore.JobStoreSupport.acquireNextTriggers(JobStoreSupport.java:2742) at org.quartz.core.QuartzSchedulerThread.run(QuartzSchedulerThread.java:264) Caused by: com.mysql.jdbc.exceptions.jdbc4.MySQLNonTransientConnectionException: No operations allowe at sun.reflect.GeneratedConstructorAccessor44.newInstance(Unknown Source) at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(Unknown Source) at java.lang.reflect.Constructor.newInstance(Unknown Source) at com.mysql.jdbc.Util.handleNewInstance(Util.java:411) at com.mysql.jdbc.Util.getInstance(Util.java:386) at com.mysql.jdbc.SQLError.createSQLException(SQLError.java:1015) at com.mysql.jdbc.SQLError.createSQLException(SQLError.java:989) at com.mysql.jdbc.SQLError.createSQLException(SQLError.java:975) at com.mysql.jdbc.SQLError.createSQLException(SQLError.java:920) at com.mysql.jdbc.ConnectionImpl.throwConnectionClosedException(ConnectionImpl.java:1311) at com.mysql.jdbc.ConnectionImpl.checkClosed(ConnectionImpl.java:1303) at com.mysql.jdbc.ConnectionImpl.prepareStatement(ConnectionImpl.java:4530) at com.mysql.jdbc.ConnectionImpl.prepareStatement(ConnectionImpl.java:4495) at org.apache.commons.dbcp.DelegatingConnection.prepareStatement(DelegatingConnection.java:248) at org.apache.commons.dbcp.PoolingDataSource$PoolGuardConnectionWrapper.prepareStatement(PoolingData at sun.reflect.GeneratedMethodAccessor8.invoke(Unknown Source) at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source) at java.lang.reflect.Method.invoke(Unknown Source) at org.quartz.impl.jdbcjobstore.AttributeRestoringConnectionInvocationHandler.invoke(AttributeRestoringConn at com.sun.proxy.$Proxy20.prepareStatement(Unknown Source) at org.quartz.impl.jdbcjobstore.StdJDBCDelegate.selectTriggerToAcquire(StdJDBCDelegate.java:2557) at org.quartz.impl.jdbcjobstore.JobStoreSupport.acquireNextTrigger(JobStoreSupport.java:2778) ... 4 more Caused by: com.mysql.jdbc.exceptions.jdbc4.CommunicationsException: Communications link failure The last packet successfully received from the server was 20,012 milliseconds ago. The last packet sent successf ago. at sun.reflect.GeneratedConstructorAccessor45.newInstance(Unknown Source) at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(Unknown Source) at java.lang.reflect.Constructor.newInstance(Unknown Source) at com.mysql.jdbc.Util.handleNewInstance(Util.java:411) at com.mysql.jdbc.SQLError.createCommunicationsException(SQLError.java:1129) at com.mysql.jdbc.MysqlIO.reuseAndReadPacket(MysqlIO.java:3720) at com.mysql.jdbc.MysqlIO.reuseAndReadPacket(MysqlIO.java:3609) at com.mysql.jdbc.MysqlIO.checkErrorPacket(MysqlIO.java:4160) at com.mysql.jdbc.MysqlIO.sendCommand(MysqlIO.java:2617) at com.mysql.jdbc.MysqlIO.sqlQueryDirect(MysqlIO.java:2778) at com.mysql.jdbc.ConnectionImpl.execSQL(ConnectionImpl.java:2819) at com.mysql.jdbc.ConnectionImpl.setAutoCommit(ConnectionImpl.java:5355) at org.apache.commons.dbcp.DelegatingConnection.setAutoCommit(DelegatingConnection.java:331) at org.apache.commons.dbcp.PoolingDataSource$PoolGuardConnectionWrapper.setAutoCommit(PoolingDataS at org.quartz.impl.jdbcjobstore.AttributeRestoringConnectionInvocationHandler.setAutoCommit(AttributeRestorin at org.quartz.impl.jdbcjobstore.AttributeRestoringConnectionInvocationHandler.invoke(AttributeRestoringConn at com.sun.proxy.$Proxy20.setAutoCommit(Unknown Source) at org.quartz.impl.jdbcjobstore.JobStoreSupport.getConnection(JobStoreSupport.java:788) at org.quartz.impl.jdbcjobstore.JobStoreTX.getNonManagedTXConnection(JobStoreTX.java:71) at org.quartz.impl.jdbcjobstore.JobStoreSupport.executeInNonManagedTXLock(JobStoreSupport.java:3788) ... 2 more Caused by: java.io.EOFException: Can not read response from server. Expected to read 4 bytes, read 0 bytes bef at com.mysql.jdbc.MysqlIO.readFully(MysqlIO.java:3166) at com.mysql.jdbc.MysqlIO.reuseAndReadPacket(MysqlIO.java:3620) ... 16 more Thanks! Comments Comment by xing wei [ 17/May/15 ] JobStoreSupport protected boolean doCheckin() throws JobPersistenceException { boolean transOwner = false; boolean transStateOwner = false; boolean recovered = false; Connection conn = getNonManagedTXConnection(); try { // Other than the first time, always checkin first to make sure there is // work to be done before we acquire the lock (since that is expensive, // and is almost never necessary). This must be done in a separate // transaction to prevent a deadlock under recovery conditions. List<SchedulerStateRecord> failedRecords = null; if (firstCheckIn == false) { failedRecords = clusterCheckIn(conn); commitConnection(conn); } if (firstCheckIn || (failedRecords.size() > 0)) { getLockHandler().obtainLock(conn, LOCK_STATE_ACCESS); transStateOwner = true; // Now that we own the lock, make sure we still have work to do. // The first time through, we also need to make sure we update/create our state record failedRecords = (firstCheckIn) ? clusterCheckIn(conn) : findFailedInstances(conn); if (failedRecords.size() > 0) { getLockHandler().obtainLock(conn, LOCK_TRIGGER_ACCESS); //getLockHandler().obtainLock(conn, LOCK_JOB_ACCESS); transOwner = true; clusterRecover(conn, failedRecords); recovered = true; } } commitConnection(conn); } catch (JobPersistenceException e) { rollbackConnection(conn); throw e; } finally { try { releaseLock(conn, LOCK_TRIGGER_ACCESS, transOwner); } finally { try { releaseLock(conn, LOCK_STATE_ACCESS, transStateOwner); } finally { cleanupConnection(conn); } } } firstCheckIn = false; return recovered; } everytime check fail records just first checkin, so if transaction commit failure,the records will not be resumed during runtime.Please check it, thanks! Generated at Wed May 10 06:46:50 PDT 2017 using JIRA 6.2.4#6261sha1:4d2e6f6f26064845673c8e7ffe9b6b84b45a6e79.