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

When importing a document identical to the already existing one no version is added

    XMLWordPrintable

Details

    • Unknown

    Description

      What happen in practice if that metadata dirty will stay false if you keep calling XWikiDocument#set* with something identical to the value already in XWikiDocument (at least for the set* method properly doing their job).

      Let's call that an unintended feature but since it's unintended I'm setting it as a bug for now. Also setting "regression" label since old package plugin does not behave the same way (it create a XWikiDocument instance from the XAR which is always "dirty" and save this one while instance output filter load the existing document and update it).

      We need to decide if we want to keep this feature or force metadata dirty to true before calling XWiki#saveDocument in output instance filter or optimize a bit the current situation and not call XWiki#saveDocument at all when nothing changed.

      See http://markmail.org/message/646n4u7uu7m5ubac

      Attachments

        Activity

          People

            tmortagne Thomas Mortagne
            tmortagne Thomas Mortagne
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: