[ 
https://issues.apache.org/jira/browse/SQOOP-2396?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14580227#comment-14580227
 ] 

Dian Fu commented on SQOOP-2396:
--------------------------------

Thanks [~liguirong98] for report this issue. I have taken some time to 
investigate this issue and have the following result: 
1. The reason to the exception is that the {{PurgeThread}} of {{JobManager}} 
received an interrupt signal when it's still execute {{purgeSubmissions}}, this 
caused the SQL connection closed.
2. The reason of verification shows successfully is that the exception in #1 is 
thrown in {{PurgeThread}} which is a sub-thread, main thread didn't catch this 
exception.

Based on the above analysis, have posted a quick patch for this issue.

> verify successful but has error
> -------------------------------
>
>                 Key: SQOOP-2396
>                 URL: https://issues.apache.org/jira/browse/SQOOP-2396
>             Project: Sqoop
>          Issue Type: Bug
>          Components: sqoop2-build
>            Reporter: liguirong
>
> Exception in thread "PurgeThread" org.apache.sqoop.common.SqoopException: 
> JDBCREPO_0009:Failed to finalize transaction
>       at 
> org.apache.sqoop.repository.JdbcRepositoryTransaction.close(JdbcRepositoryTransaction.java:115)
>       at 
> org.apache.sqoop.repository.JdbcRepository.doWithConnection(JdbcRepository.java:109)
>       at 
> org.apache.sqoop.repository.JdbcRepository.doWithConnection(JdbcRepository.java:61)
>       at 
> org.apache.sqoop.repository.JdbcRepository.purgeSubmissions(JdbcRepository.java:589)
>       at 
> org.apache.sqoop.driver.JobManager$PurgeThread.run(JobManager.java:648)
> Caused by: java.sql.SQLNonTransientConnectionException: No current connection.
>       at 
> org.apache.derby.impl.jdbc.SQLExceptionFactory40.getSQLException(Unknown 
> Source)
>       at org.apache.derby.impl.jdbc.Util.newEmbedSQLException(Unknown Source)
>       at org.apache.derby.impl.jdbc.Util.newEmbedSQLException(Unknown Source)
>       at org.apache.derby.impl.jdbc.Util.noCurrentConnection(Unknown Source)
>       at org.apache.derby.impl.jdbc.EmbedConnection.checkIfClosed(Unknown 
> Source)
>       at org.apache.derby.impl.jdbc.EmbedConnection.setupContextStack(Unknown 
> Source)
>       at org.apache.derby.impl.jdbc.EmbedConnection.commit(Unknown Source)
>       at 
> org.apache.commons.dbcp.DelegatingConnection.commit(DelegatingConnection.java:334)
>       at 
> org.apache.commons.dbcp.DelegatingConnection.commit(DelegatingConnection.java:334)
>       at 
> org.apache.commons.dbcp.PoolingDataSource$PoolGuardConnectionWrapper.commit(PoolingDataSource.java:211)
>       at 
> org.apache.sqoop.repository.JdbcRepositoryTransaction.close(JdbcRepositoryTransaction.java:112)
>       ... 4 more
> Caused by: java.sql.SQLException: No current connection.
>       at 
> org.apache.derby.impl.jdbc.SQLExceptionFactory.getSQLException(Unknown Source)
>       at 
> org.apache.derby.impl.jdbc.SQLExceptionFactory40.wrapArgsForTransportAcrossDRDA(Unknown
>  Source)
>       ... 15 more
> Verification was successful.
> Tool class org.apache.sqoop.tools.tool.VerifyTool has finished correctly.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Reply via email to