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

Deprecate the notion of space / SpaceReference (i.e. move more towards real Nested Pages in the platform)

    XMLWordPrintable

Details

    • Idea
    • Resolution: Unresolved
    • Major
    • None
    • 7.4.4
    • Old Core
    • None
    • Unknown

    Description

      With the introduction of Nested Spaces, we are simulating our actual goal of achieving Nested Pages and we did that by using the WebHome page inside a Nested Space.

      However, this introduced the complexity of dealing with terminal (non-WebHome) and non-terminal (WebHome) pages, which leads to a lot of confusion and cruft.

      Perhaps it would have been (/would be) better to have dropped the notion of space altogether and merge the space and name fields of a document into a single reference field.

      Examples:
      1. terminal page
      space: A
      page: B
      => reference: A.B
      2. non-terminal nested page
      space: A.B
      page: WebHome
      => reference: A.B.WebHome
      3. non-terminal top level page
      space: A
      page: WebHome
      => reference: A.WebHome
      4. <new> simply a top level page
      reference: A

      This way we would achieve real NestedPages and we would remove any ambiguities caused by the existence of both a non-terminal page (A.B.WebHome) and a terminal page (A.B), like we have for the wiki link syntax and for which we had to come up with this elaborate algorithm to check for all the possible cases.

      All the existing APIs could be easily modified to accommodate this storage change and many methods that work with spaces and SpaceReferences can be deprecated.

      When importing content in the older storage, the import can easily detect the older xar format and, when importing, also handle the migration to the new storage.

      Of course, existing content needs to be migrated as well.

      IMO, this is something doable and with a minimal impact on the end user.

      It would allow us to kill the space concept completely but also result in properly killing the WebHome problem as well (since the UI will no longer be creating WebHome pages, but will be creating what we used to call terminal pages, which now also happen to support children, so they are no longer terminal).

      Yes, we would be doing Nested Pages with path storage, but we can still use for redundancy (and query performance) what we currently call the XWikiSpaces table, which we can probably rename.

      As tmortagne pointed out, reference resolvers would also need special attention, since they still need to produce the old DocumentReference which contains a SpaceReference. We probably need to introduce some new PageReference and new resolvers/serializers to work with it.

      Attachments

        Activity

          People

            Unassigned Unassigned
            enygma Eduard Moraru
            Votes:
            1 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

              Created:
              Updated: