Confluence XML Import Fails With Discussion Plugin Errors

お困りですか?

アトラシアン コミュニティをご利用ください。

コミュニティに質問

プラットフォームについて: Server および Data Center のみ。この記事は、Server および Data Center プラットフォームのアトラシアン製品にのみ適用されます。

Support for Server* products ended on February 15th 2024. If you are running a Server product, you can visit the Atlassian Server end of support announcement to review your migration options.

*Fisheye および Crucible は除く

    

要約

Confluence XML Import Fails with Discussion Plugin Errors.

環境

  • Confluence server and data center.
  • Third-party app Discussion installed.

診断

The following appears in atlassian-confluence.log

2020-07-29 11:59:24,763 INFO [Long running task: Importing data] [confluence.importexport.actions.ImportLongRunningTask] runInternal Beginning import by user admin
2020-07-29 11:59:24,795 INFO [Long running task: Importing data] [atlassian.plugin.manager.DefaultPluginManager] broadcastPluginDisabling Disabling com.atlassian.confluence.plugins.synchrony-interop
...
2020-07-29 12:20:08,990 ERROR [Long running task: Importing data] [confluence.importexport.actions.ImportLongRunningTask] runInternal Failure during import
 -- url: /c6159/longrunningtaskxml.action | referer: http://localhost:26159/c6159/admin/restore-local-file.action | traceId: 3afdc5b935204c0e | userName: admin | action: longrunningtaskxml
com.atlassian.confluence.importexport.ImportExportException: com.atlassian.activeobjects.spi.ActiveObjectsImportExportException: There was an error during import/export with <unknown plugin> (table AO_0FD6DB_DISCUSSION):
	at com.atlassian.activeobjects.confluence.backup.ActiveObjectsBackupRestoreProvider.restore(ActiveObjectsBackupRestoreProvider.java:49)
	at com.atlassian.confluence.importexport.xmlimport.FileBackupImporter.importPluginData(FileBackupImporter.java:407)
...
Caused by: java.sql.BatchUpdateException: Batch entry 0 INSERT INTO "AO_0FD6DB_DISCUSSION" ("ARCHIVED", "CATEGORY_ID", "CREATION_DATE", "CREATOR", "ID", "LIKES", "PAGE_ID", "RESOLVED_COMMENTS_ID", "SPACE_KEY", "STATUS", "TYPE", "VIEWS") VALUES ('FALSE', NULL, '2015-03-24 16:42:05-05', 'admin', '1', '0', '3572190', NULL, '~admin', 'IN_DISCUSS', 'DISCUSSION', '78') was aborted: ERROR: null value in column "CATEGORY_ID" violates not-null constraint
  Detail: Failing row contains (f, null, 2015-03-24 16:42:05, admin, 1, 0, 3572190, null, ~admin, IN_DISCUSS, DISCUSSION, 78).  Call getNextException to see other errors in the batch.
	at org.postgresql.jdbc.BatchResultHandler.handleError(BatchResultHandler.java:148)
...
Caused by: org.postgresql.util.PSQLException: ERROR: null value in column "CATEGORY_ID" violates not-null constraint
  Detail: Failing row contains (f, null, 2015-03-24 16:42:05, admin, 1, 0, 3572190, null, ~admin, IN_DISCUSS, DISCUSSION, 78).
	at org.postgresql.core.v3.QueryExecutorImpl.receiveErrorResponse(QueryExecutorImpl.java:2476)


原因

Discussions data is corrupted in the XML backup with the error message null value in column "CATEGORY_ID" violates not-null constraint on the table "AO_0FD6DB_DISCUSSION".

ソリューション

If the Discussions data is no longer needed, then the entries can be removed in activeObjectsBackupRestoreProvider.pdata

  1. Unzip the XML backup
  2. Remove the entries related to the discussion data in activeObjectsBackupRestoreProvider.pdata. The following are the headers for related entries to Discussion data

      <table name="AO_0FD6DB_DISCUSSION">
      <table name="AO_0FD6DB_DISCUSSION_CATEGORY">
      <data tableName="AO_0FD6DB_DISCUSSION">
      <data tableName="AO_0FD6DB_DISCUSSION_CATEGORY">
  3. Rezip the files back together and try the restore again.


最終更新日: 2020 年 10 月 19 日

この内容はお役に立ちましたか?

はい
いいえ
この記事についてのフィードバックを送信する
Powered by Confluence and Scroll Viewport.