Confluence AddOn that adds a "Page Tree Copy" action to copy an entire page tree/hierarchy. The Plugin supports adjustments of page names to avoid problems with page name duplication. Copies can be saved to the same space or other spaces.
The Plugin supports adjustments of page names to avoid problems with page name duplication.
There are two versions of the plugin:
- Copy Page Tree (On Premise) - for locally running Confluence instances - 'behind the firewall'
- Copy Page Tree for OnDemand - for Confluence OnDemand
Both operate essentially the same.
Copy Page Tree for 'Confluence Server'
Why does the UI look different than the screenshots on the MarketPlace?
There are actually two completely different add-ons for Copy Page Tree - one is for Server and one is for Cloud. They share no overlapping code.
I have created a JIRA issue to track this: CPT-21
I am hoping to refresh the UI for Server early Q3 2015 though they are functionally basically the same.
Copy Page Tree for OnDemand
(these screenshots are of the OnDemand version of the AddOn currently, though both operate in a similar fashion)
Demo video of the OnDemand version
Because OnDemand AddOns must hosted remotely there is currently a limit of 50 pages and 500k sized attachments for a single copy operation. Once we gather more data around the demands on our servers we may increase these limits.
Issues can be reported here: firstname.lastname@example.org
Longer running issues such as bugs that need fixing and feature requests are tracked in the Copy Page Tree JIRA Project
Copy Page Tree for OnDemand Documentation
Atlassian Confluence Plugin that adds a page action to copy not only the current page but a complete page hierarchy. The Plugin supports adjustments of page names to avoid problems with page name duplication. Copies can be saved to other Spaces as well.
To install this plugin, go to https://marketplace.atlassian.com/plugins/com.nurago.confluence.plugins.treecopy
* Preserves Permissions (View/Edit Restrictions) while copying pages
* Tested Compatibility to 5.4
* Fix: only pages are copied that the authenticated user has the permission to VIEW
* Tested Compatibility to 5.3.1
* Tested Compatibility to 5.1.1
* error handling when page with attachment has missing attachment
* added good base to perform full i18n translation.
* Fix: now it actually uses logging facade(log4j), not System.out.print;
* Fix: now it really does copy the newest attachment;
* Fix: replaced all deprecated methods with their newer versions
* Tested Compatibility from 4.0 to 4.3
* Space Permissions are checked now when executing the Copy, so loopholing the check by fiddling with the HTTP POST is not possible anymore.
* Copying attachment to other spaces is actually possible. That was a false alarm.
* Added a feature to choose what space the copies will be saved in
* Added a feature to choose the parent page the copies will be saved under taking into account the specified space. There is an autocomplete feature with that field to ease the selection of a valid page title.
* All pages are selected by default now
* Added "(De-)Select All" links.
* Applying Prefixes/Suffixes or Replacements to the Page Titles now work for selected pages only.
* Space Permissions are taken into account now. It's not possible anymore to copy pages into a space where the user is not allowed to create pages. (see https://answers.atlassian.com/questions/64948/copy-page-tree-macro-doesn-t-respect-permissions).
* Apparently attachments are not copied to other spaces (see https://jira.atlassian.com/browse/CONF-24678 for a similar issue).
* The autocomplete Feature used in the Parent Page field doesn't allow selections by mouse click at least in Google Chrome. Unfortunately the standard jQuery UI autocomplete cannot be used here because Atlassian tweaked that feature a little bit too much (see https://answers.atlassian.com/questions/3304/success-using-jquery-ui-autocomplete-in-confluence-3-5-3). The substitute I used is causing the issue.
* Missing Space Permissions Check when executing the copy. An attacker could fiddle with the HTTP POST request to inject different space key.
* Errors (unknown pages or page title collisions) are still not handled gracefully.
* Overall Look and Feel is not that great
* Not tested with Confluence Versions other than 4.3 yet
Known issues and work arounds:
"Documentation Blueprint" issue:
Spaces created with the "Documentation Blueprint" do not copy (nor let you roll back history). We've reported a related issue here: https://jira.atlassian.com/browse/CONF-33246
Permission Requirements and Troubleshooting
Both the currently logged in user and the add-on performing the copy need to have read and write permissions for the operation to work.
If you see something like this:
Error: The application was unable to serve your request: com.atlassian.confluence.rpc.RemoteException: You're not allowed to view that page, or it does not exist.
Then most likely the 'add-on' user "addon_com.nurago.confluence.plugins.treecopy" either does not have permission to read the content or write the new content.
Solution: Make sure both the currently logged in user and the user "addon_com.nurago.confluence.plugins.treecopy" (Copy Page Tree system add-on user) have permissions to read and write content. These permissions could be set at the global or space level or the pages might have 'restricted permissions' at the page level.
Lucene index errors:
The following errors are detected in the log many times:
In version 2.4.1 of the add-on we were attempting to make performance improvements. However the add-on created pages as 'anonymous'. This revealed an internal Confluence bug with Lucene which generates these errors.
All later versions of the add-on 2.4.2 and up fix this problem so content is created correctly by the current user. However it appears content that was created by 'anonymous' will cause these errors to continue to appear in the logs each time Confluence attempts to re-index the content. You can either delete the content created by 'anonymous' or it might be possible to squelch these errors by configuring the log4j logging properties.