Release Notes for XWiki 7.2 Milestone 2

Version 27.1 by Vincent Massol on 2015/08/07

This is the release notes for XWiki Commons, XWiki Rendering, XWiki Platform and XWiki Enterprise. They share the same release notes as they are released together and have the same version.

The focus of this release was on fixing issues introduced in 7.2 Milestone 1 with the new Nested Document/Nested Spaces features and to continue adding support for this feature in various existing features (using a tree for the Import UI instead of a list, new DB table to have performant Space queries, start of Nested Spaces support in the XWiki JS APIs, etc). Another major feature added was the new Script permission to allow forbidding Script execution to specific Users or Groups.

New and Noteworthy (since XWiki 7.2 Milestone 1)

Full list of issues fixed and Dashboard for 7.2.

Script Right

The Script Right is now set to DENY by default, meaning that if you do not have it explicitly, you will not be able to execute the scripts that you write with your user account.

However, for backward-compatibility reasons, the standard XWiki Enterprise distribution comes with the Script Right being allowed for all users at the main wiki level, so that, unless you (as an Admin) explicitly revoke the right for some users or explicitly deny it, they will be able to execute the scripts they wrote, just like before.

scriptRightsExplicitlyAllowedInXWikiPreferences.png

Hiding of the Parent-Child Relationship

Following our decision to drop the Parent-Child relationship, it's now been turned off by default in favor of Nested Documents.

Note that it's possible to go back to the previous behavior, in which the Breadcrumb was following the Parent/Child relationship, by setting the core.hierarchyMode property to parentchild in the xwiki.properties configuration file.

New Breadcrumb

The Breadcrumb has been reworked to reflect the location of a Document in the reference hierarchy. For example for a Document "CEO" inside a Document "Boarding" inside a Document "Management" inside a Document "Staff" you would have the following Breadcrumb:

breadcrumb.png

New Index Tree

The Index Tree is now using the reworked Document Tree Macro and is thus now honoring the Nested Document hierarchy. For example:

indextree.png

Updated Edit Mode

In Edit mode, the ability to change the Parent has been removed by default since we're now honoring the Nested Document hierarchy. For example:

editmode.png

Miscellaneous

  • Import UI move to new standard tree

    import.png

  • The size of the Job status cache is now configurable. See job.statusCacheSize property in xwiki.properties files.
  • The Spaces macro (which lists all Spaces) is now working fine when there are Nested Spaces (some links were failing).
  • The LiveTable macro is now working fine when there are Nested Spaces (some links were failing).

See the full list of JIRA issues fixed in this release.

For Developers

New Space/XWikiSpace table

A new table dedicated to Spaces has been introduced, in order to have performant and scalable Space-related queries (like supporting getting paginated Space which is useful for the Document Tree macro for example).

Queries improvement

Allow executing complete SELECT queries

In HQL and XWQL it's now possible to execute full SELECT queries without Programming Right as long as you follow some rules currently defined in com.xpn.xwiki.internal.store.hibernate.query.HqlQueryUtils, which contains a list of the database field allowed in the SELECT clause. Namely:

  • For the Document/XWikiDocument table: fullName, name, space, language, defaultLanguage, translation, hidden
  • For the Space/XWikiSpace table: reference, name, parent, hidden

This is also true for the Named Queries located in the queries.hbm.xml file.

New Secure Query

The right to execute or not some Query is now controlled by each org.xwiki.query.QueryExecutor.

Anyone can ask the executor to check or ignore Right through the new org.xwiki.query.SecureQuery extending org.xwiki.query.Query:

  • checkCurrentAuthor(): indicate if the current author right should be checked
  • checkCurrentUser(): indicate if the result should be filtered based on current user Right (only implemented by SOLR right now)

JS API Improvements

  • It's now possible to create a Nested Spaces Reference using XWiki's Javascript API. For example:
    // Construct a Nested Space reference
    var reference = new XWiki.SpaceReference('wiki', ['space1', 'space2']);
    expect(XWiki.Model.serialize(reference)).toEqual('wiki:space1.space2');
    reference = new XWiki.DocumentReference('wiki', ['space1', 'space2'], 'page');
    expect(XWiki.Model.serialize(reference)).toEqual('wiki:space1.space2.page');
    // Construct a non-Nested Space reference
    reference = new XWiki.SpaceReference('wiki', 'space');
    expect(XWiki.Model.serialize(reference)).toEqual('wiki:space');
    // Try passing non-valid space parameters
    expect(function() {new XWiki.SpaceReference('wiki', [])}).toThrow('Missing mandatory space name or invalid type for: []');
    expect(function() {new XWiki.SpaceReference('wiki', 12)}).toThrow('Missing mandatory space name or invalid type for: [12]');
  • A new XWiki.EntityReference.equals() method has been added. For example:
    var reference1 = new XWiki.DocumentReference('wiki', ['space1', 'space2'], 'page');
    var reference2 = new XWiki.DocumentReference('wiki', ['space1', 'space2'], 'page');
    var reference3 = new XWiki.DocumentReference('wiki2', ['space1', 'space2'], 'page');
    expect(reference1.equals(reference2)).toBe(true);
    expect(reference1.equals(reference3)).toBe(false);
  • A new XWiki.EntityReference.fromJSONObject(obejct) has been added to create a Javascript XWiki.EntityReference from a Java EntityReference directly serialized as JSON:
    var reference = XWiki.EntityReference.fromJSONObject(jsonText.evalJSON());
  • A new XWiki.EntityReferenceTree JS class has been added, which partially mimics the Java EntityReferenceTree Class. It's still missing features though as it was introduced mostly to make it easier to manipulate a serialized Java EntityReferenceTree.

Miscellaneous

  • Custom displayers are now executed with the Rights of the user who wrote them (i.e. author of the class document or content author of the displayer document), and not the Rights of the user who wrote the script that uses them (i.e. current context document's content author). See XWIKI-12306 for more details.
  • In the Active Install Extension, a new Velocity Macro has been introduced to compute the number of Active Installs having a specific Extension. Example usage:
    {{include reference="ActiveInstalls.ExtensionCount"/}}

    {{velocity}}
      #set ($extensionIds = [
        'org.xwiki.contrib:xwiki-totem-application',
        'jsimard:event-reporter-application',
        'mouhb:likeapplication'
      ])
      |=Extension Id|=Count
      #foreach($extensionId in $extensionIds)
        #countActiveInstallsUsingExtension($extensionId $count)
        |$extensionId|$count
      #end
    {{/velocity}}
  • Better support of non-DOCUMENT EntityReferences in DocumentReferenceConverter. It now behaves like XWiki#getDocument(EntityReference)

Deprecated and Retired projects

  • The OSCache-based Cache Extension has been moved to xwiki-contrib since we've been using the Infinispan implementation for a while now and the XWiki Core developers don't intend to continue supporting the OSCache-based one (it can be maintained by the Community, by whoever's interested in supporting it).

Upgrades

The following dependencies have been upgraded:

Translations

The following translations have been updated: 

Tested Browsers & Databases

Performances tests compared to <last super stable version>

<a summary of the comparison with latest super stable version>

More details on <link to the test report>.

Known issues

Backward Compatibility and Migration Notes

General Notes

When upgrading make sure you compare your xwiki.cfg, xwiki.properties and web.xml files with the newest version since some configuration parameters may have been modified or added. Note that you should add xwiki.store.migration=1 so that XWiki will attempt to automatically migrate your current database to the new schema. Make sure you backup your Database before doing anything.

Issues specific to XWiki 7.2 Milestone 2

<issues specific to the project>

API Breakages

The following APIs were modified since XWiki 7.2 Milestone 1:

<clirr output here>

Get Connected