Uploaded image for project: 'Confluence Data Center'
  1. Confluence Data Center
  2. CONFSERVER-58846

Bulk change ownership during XML Space Import

    XMLWordPrintable

Details

    • 1
    • We collect Confluence feedback from various sources, and we evaluate what we've collected when planning our product roadmap. To understand how this piece of feedback will be reviewed, see our Implementation of New Features Policy.

    Description

      As a system admin
      I want to have a way to change pages owners (author, last modifier) during a Space import operation
      So that If I receive an exported space in XML format, I can easily do a "from-to" operation to assign pages to new owners

      Suggestion Summary

      • Customer company A is bought by company B.
      • Both have Confluence, Directories are not integrated
      • Sysadmins on company B create users for employees from company A, but they do not always match the ones they had in A (such as, A is johnsmith, B is jsmith)
      • Customer would rather have pages assigned correctly, than listing unknown user johnsmith

      Proposed Solution

      Import operation could allow admins to input a from-to CSV file indicating old user names and new ones, to prevent that issue.

      Possible Workarounds

      Replace Name
      sed -i.tmp 's@<property name="name"><!\[CDATA\[oldusername\]\]></property>@<property name="name"><!\[CDATA\[newusername\]\]></property>@g' entities.xml
      
      Replace Lower Name
      sed -i.tmp 's@<property name="lowerName"><!\[CDATA\[oldusername\]\]></property>@<property name="lowerName"><!\[CDATA\[newusername\]\]></property>@g' entities.xml
      

      Again, we must be mindful about the space name. I don't think you gonna have spaces with usernames on it, but, just in case, be mindful about that. If that happens, after you have SED'ed your way, open the entities.xml file and look for the tag below:

       <object class="Space" package="com.atlassian.confluence.spaces">
       <id name="id">3440641</id>
       <property name="name"><![CDATA[OldUserName]]></property>
       <property name="key"><![CDATA[MAR]]></property>
       <property name="lowerKey"><![CDATA[mar]]></property>
      

      Once you found it, just replace the name accordingly to respect the previous space name and save the file. Then follow the steps previously outlined here and we should be fine.

      Attachments

        Activity

          People

            Unassigned Unassigned
            eviana Edson (Inactive)
            Votes:
            2 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated: