Uploaded image for project: 'XWiki Platform'
  1. XWiki Platform
  2. XWIKI-9821

Confluence import and XAR export: output written as XML, not xar

    Details

    • Tests:
      Unit
    • Difficulty:
      Unknown
    • Documentation:
      N/A
    • Documentation in Release Notes:
      N/A
    • Similar issues:

      Description

      If triggering a confluence import / XWiki xar export via the WikiStream converter, the result is not written into a file in xar format, but all pages are written into one big xml file.

      There are two "reasons" for this:

      • the ConfluenceInputWikiStream never sends beginWiki /endWiki events (makes somewhat sense, as the format seems ont to export spaces, not complete wikis
      • the XAROutputWikiStream creates a XARWikiWriter on "beginWiki", however. If it does not have such a writer when starting to create the content, it uses a WikiStreamXMLStreamWriter instead.

      I would like to work on a pull request here, but I am not sure at which end this should be fixed (if it should be fixed at all and is not considered a feature). The simplest thing (that "works for me") is to add "beginWiki"/"endWiki" calls in the ConfluenceInputWikiStream.read method, even though one has to invent a name for the wiki (I can see no such data serving as a wiki name in the *.xml.zip file, and I guess Confluence has no need for wiki names either, as it has no multi-wiki feature.

        Attachments

          Activity

            People

            • Assignee:
              tmortagne Thomas Mortagne
              Reporter:
              camil7 Clemens Robbenhaar
            • Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved:
                Date of First Response: