A blog about software development, primarily in Java and about web applications.

Wednesday, September 1, 2010

Confluence children and pagetree macros breaking

One of my side tasks is to provide some technical support for our Confluence wiki instance. We recently had a space stop working. The symptom was that the children and pagetree macros would never load. Because of this it made it impossible to view the space pages in tree view mode and move pages out of there to find the problem page.

The problem seems to have boiled down to a page somehow getting created without a page name. From Confluence's knowledge base: http://confluence.atlassian.com/display/CONFKB/Accessing+a+Space+via+Webdav+Returns+a+Blank+Page

Resolution

You need to identify the page title(s) that is null.

Run the following database query:

SELECT CONTENTID
FROM SPACES s, CONTENT c
WHERE s.SPACEID = c.SPACEID AND s.SPACEKEY = 'YourSpaceKey' AND c.CONTENTTYPE = 'PAGE' AND c.TITLE IS NULL;

Once identified, you can delete the page from the database or update it via these queries:

update content set title = 'title' where contentid = ;

Make sure that the titles are unique to the space.

No comments: