Uploaded image for project: 'Jira Service Management Data Center'
  1. Jira Service Management Data Center
  2. JSDSERVER-65

Restoring data in Oracle containing Service Desk data fails in 5.2 - 6.0.x

    XMLWordPrintable

Details

    • Bug
    • Resolution: Done
    • High
    • None
    • 1.0
    • None

    Description

      The root cause of this issue is: https://ecosystem.atlassian.net/browse/AO-264 and is caused by the Active Objects plugin.

      JIRA 6.1 contains a version change in Active Objects and this issue is not present in JIRA 6.1

      Symptoms

      During a data restore - the following stack trace is present:

      [INFO] [talledLocalContainer] com.atlassian.activeobjects.spi.ActiveObjectsImportExportException: There was an error during import/export with plugin JIRA Service Desk(com.atlassian.servicedesk) #1.0.1-SNAPSHOT (table AO_54307E_SERVICEDESK):There has been a SQL exception importing row #0 for table 'AO_54307E_SERVICEDESK' see  the cause of this exception for more detail about it.
      [INFO] [talledLocalContainer] 	at com.atlassian.activeobjects.backup.ImportExportErrorServiceImpl.newRowImportSqlException(ImportExportErrorServiceImpl.java:36)
      [INFO] [talledLocalContainer] 	at com.atlassian.dbexporter.importer.DataImporter.importTable(DataImporter.java:131)
      [INFO] [talledLocalContainer] 	at com.atlassian.dbexporter.importer.DataImporter.access$000(DataImporter.java:33)
      [INFO] [talledLocalContainer] 	at com.atlassian.dbexporter.importer.DataImporter$1.call(DataImporter.java:73)
      [INFO] [talledLocalContainer] 	at com.atlassian.dbexporter.importer.DataImporter$1.call(DataImporter.java:62)
      [INFO] [talledLocalContainer] 	at com.atlassian.dbexporter.jdbc.JdbcUtils.withConnection(JdbcUtils.java:31)
      [INFO] [talledLocalContainer] 	at com.atlassian.dbexporter.importer.DataImporter.doImportNode(DataImporter.java:61)
      [INFO] [talledLocalContainer] 	at com.atlassian.dbexporter.importer.AbstractImporter.importNode(AbstractImporter.java:49)
      [INFO] [talledLocalContainer] 	at com.atlassian.dbexporter.DbImporter.importData(DbImporter.java:73)
      [INFO] [talledLocalContainer] 	at com.atlassian.activeobjects.backup.ActiveObjectsBackup.restore(ActiveObjectsBackup.java:158)
      [INFO] [talledLocalContainer] 	at com.atlassian.jira.bc.dataimport.DefaultDataImportService.restoreActiveObjects(DefaultDataImportService.java:439)
      [INFO] [talledLocalContainer] 	at com.atlassian.jira.bc.dataimport.DefaultDataImportService.performImport(DefaultDataImportService.java:627)
      [INFO] [talledLocalContainer] 	at com.atlassian.jira.bc.dataimport.DefaultDataImportService.doImport(DefaultDataImportService.java:251)
      [INFO] [talledLocalContainer] 	at com.atlassian.jira.web.action.setup.DataImportAsyncCommand.call(DataImportAsyncCommand.java:65)
      [INFO] [talledLocalContainer] 	at com.atlassian.jira.web.action.setup.DataImportAsyncCommand.call(DataImportAsyncCommand.java:28)
      [INFO] [talledLocalContainer] 	at com.atlassian.jira.task.ImportTaskManagerImpl$TaskCallableDecorator.call(ImportTaskManagerImpl.java:147)
      [INFO] [talledLocalContainer] 	at java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:303)
      [INFO] [talledLocalContainer] 	at java.util.concurrent.FutureTask.run(FutureTask.java:138)
      [INFO] [talledLocalContainer] 	at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:439)
      [INFO] [talledLocalContainer] 	at java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:303)
      [INFO] [talledLocalContainer] 	at java.util.concurrent.FutureTask.run(FutureTask.java:138)
      [INFO] [talledLocalContainer] 	at com.atlassian.multitenant.impl.DefaultMultiTenantManager.runForTenant(DefaultMultiTenantManager.java:61)
      [INFO] [talledLocalContainer] 	at com.atlassian.multitenant.juc.MultiTenantExecutors$WrappedRunnable.run(MultiTenantExecutors.java:160)
      [INFO] [talledLocalContainer] 	at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:895)
      [INFO] [talledLocalContainer] 	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:918)
      [INFO] [talledLocalContainer] 	at java.lang.Thread.run(Thread.java:680)
      [INFO] [talledLocalContainer] Caused by: java.sql.SQLException: Invalid column type: 16
      [INFO] [talledLocalContainer] 	at oracle.jdbc.driver.OracleStatement.getInternalType(OracleStatement.java:3879)
      [INFO] [talledLocalContainer] 	at oracle.jdbc.driver.OraclePreparedStatement.setNullCritical(OraclePreparedStatement.java:4406)
      [INFO] [talledLocalContainer] 	at oracle.jdbc.driver.OraclePreparedStatement.setNull(OraclePreparedStatement.java:4388)
      [INFO] [talledLocalContainer] 	at oracle.jdbc.driver.OraclePreparedStatementWrapper.setNull(OraclePreparedStatementWrapper.java:993)
      [INFO] [talledLocalContainer] 	at org.apache.commons.dbcp.DelegatingPreparedStatement.setNull(DelegatingPreparedStatement.java:108)
      [INFO] [talledLocalContainer] 	at org.apache.commons.dbcp.DelegatingPreparedStatement.setNull(DelegatingPreparedStatement.java:108)
      [INFO] [talledLocalContainer] 	at com.atlassian.dbexporter.importer.DataImporter$BaseInserter.setBoolean(DataImporter.java:344)
      [INFO] [talledLocalContainer] 	at com.atlassian.dbexporter.importer.DataImporter$BaseInserter.setValue(DataImporter.java:413)
      [INFO] [talledLocalContainer] 	at com.atlassian.dbexporter.importer.DataImporter.importTable(DataImporter.java:123)
      [INFO] [talledLocalContainer] 	... 24 more
      

      Workaround

      This can be fixed with the instructions in our Restore into Oracle database fails to import into AO table KB, or as per the below:

      1. Locate the activeobjects.xml file in the backup data
      2. Locate the line that contains:
        <data tableName="AO_54307E_SERVICEDESK">
      3. Replace all instances of
        <boolean xsi:nil="true"/>

        in the rows with

        <boolean>false</boolean>
      4. Rezip your backup files and import the backup

      Attachments

        Issue Links

          Activity

            People

              Unassigned Unassigned
              ezhang Ed Zhang (Automation)
              Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved:

                Backbone Issue Sync