Space Admin is slow to load on large spaces

Still need help?

The Atlassian Community is here for you.

Ask the community

Problem

  1. Space Admin takes several seconds (or longer) to load.
  2. The space in question has several thousand pages.
  3. Smaller spaces do not appear to have the same long load time.

Cause

Viewing the Space Admin page invokes the editspace.action. One of the classes called in this process makes a call to get all pages in a space. This is done to populate the drop-down for setting the space home page. The code looks something like this (taken from version 3.4.3):

public class EditSpaceEntryAction extends AbstractEditSpaceAction
{
    public List getAvailablePages()
    {
        if ((availablePages == null) && (getSpace() != null))
        {
            availablePages = new ArrayList(pageManager.getPages(getSpace(), true));
            Page blankPageAtTop = new Page();
            blankPageAtTop.setTitle("");
            availablePages.add(0, blankPageAtTop); // Give user the option not to select any home page
        }
        Collections.sort(availablePages);

        return availablePages;
    }

    public void setSpaceManager()
    {
    }
}

Workaround

We have provided a patched version of the class responsible for the getPages() call. This patch was created for Confluence 3.4.x and might be compatible with other versions. Please test it on a development instance before implementing it on your production instance. Also, as a precaution, make a backup of your instance before proceeding.

To implement the patch:

  1. Download the attached EditSpaceEntryAction.class.
  2. Create the following directory path (you may need to create one or more of the directories):

    <confluence-install>/confluence/WEB-INF/classes/com/atlassian/confluence/spaces/actions/
    
  3. Copy the EditSpaceEntryAction.class into the new actions/ directory.
  4. Restart Confluence.

Resolution

There is currently no elegant solution to this problem. A bug report has been raised to address the issue of scaling. You are encouraged to watch and vote for this bug.

 

 

 

 

 

 

 

 

 

 

 

 

 

   

 

 

 

 

 

 

 

 

 

 

 

 

 

Last modified on Feb 26, 2016

Was this helpful?

Yes
No
Provide feedback about this article
Powered by Confluence and Scroll Viewport.