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

Improve performances for displaying the history tab

    XMLWordPrintable

    Details

    • Type: Improvement
    • Status: Open
    • Priority: Critical
    • Resolution: Unresolved
    • Affects Version/s: 5.3
    • Fix Version/s: None
    • Component/s: Old Core
    • Labels:
    • Difficulty:
      Unknown
    • Similar issues:

      Description

      The issue is that pages with a large history take a very long time to display. Said differently the display time of a page depends on the number of versions it has. That shouldn't be the case!

      Right now:

      • In historyinline.vm there are calls to retrieve all versions:
      #set ($criteria = $xwiki.criteriaService.revisionCriteriaFactory.createRevisionCriteria('', $minorVersions))
      #set ($versions = $tdoc.getRevisions($criteria))
      

      We should never get all versions, only the versions that need to be displayed!

      • In addition on the API side, XWikiDocument.getRevisions(RevisionCriteria criteria, XWikiContext context) is badly written since it starts to get all revisions and then only filter according to the passed criteria.

      What needs to be done is add some new API in XWikiHibernateVersioningStore that accepts an offset and number of items to retrieve and then use that API from XWikiDocument.getRevisions and then modify historyinline.vm to only ask for what's needed to be displayed.

        Attachments

          Issue Links

            Activity

              People

              Assignee:
              Unassigned Unassigned
              Reporter:
              vmassol Vincent Massol
              Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

                Dates

                Created:
                Updated:
                Date of First Response: