Uploaded image for project: 'Jira Data Center'
  1. Jira Data Center
  2. JRASERVER-11792

FogBugz importer fails second time around: database connection closed

    XMLWordPrintable

Details

    Description

      After successfully importing a FogBUGZ project, I click the "Return to FogBUGZ importer" button. This takes one back to the screen specifying JDBC connection details. I clicked through the subsequent page to start another import (not changing the configuration file).

      The first time, this blows up with:

      2006-12-19 15:12:16,772 Thread-33 INFO [imports.importer.impl.ImportLogger] *************************************************
      ************* (0.0s)
      2006-12-19 15:12:16,772 Thread-33 INFO [imports.importer.impl.ImportLogger] IMPORTING STARTED (0.0s)
      2006-12-19 15:12:16,773 Thread-33 INFO [imports.importer.impl.ImportLogger] *************************************************
      ************* (0.0010s)
      2006-12-19 15:12:16,773 Thread-33 INFO [imports.importer.impl.ImportLogger] 
       (0.0010s)
      2006-12-19 15:12:16,773 Thread-33 INFO [imports.importer.impl.ImportLogger] Importing with ImportBeanType: com.atlassian.jira
      .imports.fogbugz.FogBugzDataBean (0.0010s)
      2006-12-19 15:12:16,773 Thread-33 INFO [imports.importer.impl.ImportLogger] 
       (0.0010s)
      2006-12-19 15:12:16,773 Thread-33 INFO [imports.importer.impl.ImportLogger] -------------------------- (0.0010s)
      2006-12-19 15:12:16,773 Thread-33 INFO [imports.importer.impl.ImportLogger] Importing of Users started (0.0010s)
      2006-12-19 15:12:16,773 Thread-33 INFO [imports.importer.impl.ImportLogger] Only new Users will be imported (0.0010s)
      2006-12-19 15:12:16,773 Thread-33 ERROR [web.action.util.DatabaseConnectionBean] SQL Exception accessing data. 
      java.sql.SQLException: Invalid state, the Connection object is closed.
              at net.sourceforge.jtds.jdbc.ConnectionJDBC2.checkOpen(ConnectionJDBC2.java:1494)
              at net.sourceforge.jtds.jdbc.ConnectionJDBC2.prepareStatement(ConnectionJDBC2.java:2177)
              at com.atlassian.jira.web.action.util.DatabaseConnectionBean.queryDb(DatabaseConnectionBean.java:245)
              at com.atlassian.jira.web.action.util.DatabaseConnectionBean.queryDb(DatabaseConnectionBean.java:230)
              at com.atlassian.jira.imports.fogbugz.FogBugzDataBean.getUsers(FogBugzDataBean.java:37)
              at com.atlassian.jira.imports.importer.impl.DefaultJiraDataImporter.importUsers(DefaultJiraDataImporter.java:207)
              at com.atlassian.jira.imports.importer.impl.DefaultJiraDataImporter.doImport(DefaultJiraDataImporter.java:78)
              at com.atlassian.jira.imports.importer.impl.ImporterThread.run(ImporterThread.java:21)
      2006-12-19 15:12:16,774 Thread-33 INFO [imports.importer.impl.ImportLogger] 0 users associated with import. (0.0020s)
      2006-12-19 15:12:16,774 Thread-33 INFO [imports.importer.impl.ImportLogger] 0 users successfully imported. (0.0020s)
      2006-12-19 15:12:16,774 Thread-33 INFO [imports.importer.impl.ImportLogger] Importing of Users finished (0.0020s)
      2006-12-19 15:12:16,774 Thread-33 INFO [imports.importer.impl.ImportLogger] --------------------------- (0.0020s)
      2006-12-19 15:12:16,774 Thread-33 INFO [imports.importer.impl.ImportLogger] Retrieving projects... (0.0020s)
      2006-12-19 15:12:16,774 Thread-33 ERROR [web.action.util.DatabaseConnectionBean] SQL Exception accessing data. 
      java.sql.SQLException: Invalid state, the Connection object is closed.
              at net.sourceforge.jtds.jdbc.ConnectionJDBC2.checkOpen(ConnectionJDBC2.java:1494)
              at net.sourceforge.jtds.jdbc.ConnectionJDBC2.prepareStatement(ConnectionJDBC2.java:2177)
              at com.atlassian.jira.web.action.util.DatabaseConnectionBean.queryDb(DatabaseConnectionBean.java:245)
              at com.atlassian.jira.web.action.util.DatabaseConnectionBean.queryDb(DatabaseConnectionBean.java:230)
              at com.atlassian.jira.imports.fogbugz.FogBugzDataBean.getProjects(FogBugzDataBean.java:44)
              at com.atlassian.jira.imports.importer.impl.DefaultJiraDataImporter.doImport(DefaultJiraDataImporter.java:82)
              at com.atlassian.jira.imports.importer.impl.ImporterThread.run(ImporterThread.java:21)
      2006-12-19 15:12:16,775 Thread-33 INFO [imports.importer.impl.ImportLogger] No projects were found to import (0.0030s)
      2006-12-19 15:12:17,540 Thread-33 INFO [imports.importer.impl.ImportLogger] Flushing issue cache (0.768s)
      2006-12-19 15:12:17,544 Thread-33 INFO [imports.importer.impl.ImportLogger] No issues need to be reindexed. (0.772s)
      2006-12-19 15:12:17,544 Thread-33 INFO [imports.importer.impl.ImportLogger] 
       (0.772s)
      2006-12-19 15:12:17,544 Thread-33 INFO [imports.importer.impl.ImportLogger] *************************************************
      ************* (0.772s)
      2006-12-19 15:12:17,544 Thread-33 INFO [imports.importer.impl.ImportLogger] IMPORTING FINISHED (0.772s)
      2006-12-19 15:12:17,544 Thread-33 INFO [imports.importer.impl.ImportLogger] *************************************************
      ************* (0.772s)
      

      The second time, it worked, and reimported all the issues again. Third time it blew up again.

      It looks like we need to make sure the connection bean is properly closed before imports.

      Attachments

        Activity

          People

            dylan@atlassian.com Dylan Etkin [Atlassian]
            7ee5c68a815f Jeff Turner
            Votes:
            1 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: