Last modified by Thomas Mortagne on 2017/03/24

Show last authors
1 {{box cssClass="floatinginfobox" title="**Contents**"}}
2 {{toc/}}
3 {{/box}}
4
5 This is the release notes for XWiki Platform, XWiki Enterprise and XWiki Enterprise Manager. They share the same release notes as they are released together and have the same version.
6
7 This is the second milestone of the XWiki 4.2 version ([[Roadmap>>Main.Roadmap]]). This release adds support for storing an email address and a list of wiki page names in XWiki objects using dedicated xclass property types. It also adds the ability to have an object property whose value is computed from the other properties. For developers this release introduces default custom displayers for easier customization of the way XWiki object properties are displayed.
8
9 = New and Noteworthy (since XWiki 4.2 Milestone 1) =
10
11 == New field types for email and list of pages ==
12
13 Two new types of class properties have been added:
14
15 * The //Email// type extends the normal //String// type, adding by default a validation regular expression that should accept only a valid email address
16 * The //Page// type extends the normal //DBList// type, and allows to select one or more documents from the current wiki
17
18 These two new properties are still in development, and further improvements will be implemented in the next milestone.
19
20 == Computed class fields ==
21
22 Another new type of class fields adds support for //virtual values// computed live from other class values, data from the database, data obtained from an external service, or practically any other source of data. These fields are non-editable and aren't stored in the database, since they only provide some wiki content that will be rendered each time such a property is displayed.
23
24 Traditionally, this kind of computation would have been written directly in the sheet used to display instances of that class, but putting it in a class field allows easier reuse of the code, since the property will be //displayed// in livetables, when indexing the document in Lucene, when displaying documents in an index page, and so on.
25
26 == Improvements to the Extension Repository Application ==
27
28 We modified the extension sheet to display the release notes for all the available versions of an extension. Check for instance the release notes for the [[Extended TODO Application>>extensions:Extension.Extended Todo Application#HReleaseNotes]]:
29
30 {{image reference="ER-releaseNotes.png"/}}
31
32 == Improvements to Extension Manager ==
33
34 An administrator of a subwiki can now install XAR extension (as long as it does not require a JAR extension).
35
36 = For Developers =
37
38 == Default custom displayers for Easier customization of the way object fields are displayed ==
39
40 While XWiki allowed to specify a custom display for a given field, it was impossible to change the way field types, such as //DateProperty// or //IntegerProperty//, are displayed in general. Now it is possible to define custom displayers at the farm or wiki level, which gives the administrators more power to change the look and feel of the wiki. For example, this allows to use HTML5 input types for dates and numbers, to use custom suggestions for //list of users// fields, or to always add a validation input for all the //password// field types.
41
42 To use this feature, first you need to compute a //type// name for your property type. This is obtained from the java class simple name, removing the ##Class## suffix, and lowercasing. For example, for numbers the java class used is ##com.xpn.xwiki.objects.classes.NumberClass##, with the simple name ##NumberClass##, which gives ##number## as the type name. For a database list, we get ##dblist## from ##DBListClass##.
43
44 Next, there are three places where a default custom displayer can be defined.
45
46 1. If a document whose name is the //type// capitalized and suffixed with ##Displayer## exists in the ##XWiki## space in the current wiki, then its content is used as the default custom displayer for that type of property. For example, ##localwiki:XWiki.NumberDisplayer## and ##localwiki:XWiki.DblistDisplayer##.
47 1. If a document whose name is the //type// capitalized and suffixed with ##Displayer## exists in the ##XWiki## space in the main wiki, then its content is used as the default custom displayer for that type of property. For example, ##xwiki:XWiki.NumberDisplayer## and ##xwiki:XWiki.DblistDisplayer##.
48 1. If a velocity template whose name is the //type// suffixed with ##.vm## exists in the current skin, then it is evaluated as the default custom displayer for that type of property. A skin file can be defined in many places, such as an attachment of a skin document, a file in a named skin on the filesystem, or a file in the ##templates/## directory.
49
50 If a specific class property provides custom display code in the XClass, then that code takes priority over an eventual default custom displayer for that property.
51
52 As with property custom displayers, when evaluating the display code several objects are placed in the context:
53
54 * ##name## is the name of the property being displayed
55 * ##prefix## is the HTML name prefix to append to an eventual input field name, and contains the XClass name, an underscore, the object number, and another underscore, for example ##XWiki.XWikiUsers_0_##
56 * ##object## is the object owning the displayed property, an instance of the public ##com.xpn.xwiki.api.Object## class
57 * ##type## is the target display type, one of ##view##, ##edit##, ##hidden## or ##search##
58
59 == New API to manipulate log level ==
60
61 Several method as been added to ##org.xwiki.logging.LoggerManager## to manipulate the log level of registered loggers.
62
63 {{code language="java"}}
64 /**
65 * Associate the passed logger to the passed log level.
66 *
67 * @param loggerName the logger
68 * @param level the level of the logger
69 */
70 void setLoggerLevel(String loggerName, LogLevel level);
71
72 /**
73 * @param loggerName the logger
74 * @return the log level associated to the logger
75 */
76 LogLevel getLoggerLevel(String loggerName);
77
78 /**
79 * @return all the registered loggers
80 */
81 Collection<Logger> getLoggers();
82 {{/code}}
83
84 == Upgrades ==
85
86 The following dependencies have been upgraded:
87
88 * GWT 2.5 RC1
89 * Selenium 2.25
90
91 == Miscellaneous ==
92
93 * Office Importer/Exporter encoding issues have been fixed ({{jira style="enum" url="https://jira.xwiki.org"}}XWIKI-6377
94 XWIKI-8007{{/jira}}).
95
96 == Translations ==
97
98 The following translations have been updated:
99
100 {{language codes="da, fr, hu, it, lv, pt_BR, ru, sv"/}}
101
102 = Tested Browsers =
103
104 Here's the list of browsers tested with this version (i.e. browsers that we've tested as working - Check the list of [[supported browsers>>dev:Community.BrowserSupportStrategy]]):
105
106 {{velocity}}
107 ## name = iexplorer, firefox, chrome, safari, opera
108 {{/velocity}}
109
110 {{browser name="firefox" version="11.0"/}}
111
112 = Known issues =
113
114 * [[Bugs we know about>>https://jira.xwiki.org/secure/IssueNavigator.jspa?reset=true&jqlQuery=category+%3D+%22Top+Level+Projects%22+AND+issuetype+%3D+Bug+AND+resolution+%3D+Unresolved+ORDER+BY+updated+DESC]]
115
116 = Backward Compatibility and Migration Notes =
117
118 == General Notes ==
119
120 You may also want to [[import the default wiki XAR>>Main.Download]] in order to benefit from all the improvements listed above.
121
122 {{warning}}
123 Always make sure you compare your ##xwiki.cfg## and ##xwiki.properties## files with the newest version since some configuration parameters were 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.
124 {{/warning}}
125
126 == API Breakages ==
127
128 The following APIs were modified since 4.1.3:
129
130 * The logging module is new and is still considered a "young API". Added new methods to manipulate loggers levels.(((
131 {{code language="none"}}
132 org.xwiki.logging.LoggerManager: Method 'public org.xwiki.logging.LogLevel getLoggerLevel(java.lang.String)' has been added to an interface
133 org.xwiki.logging.LoggerManager: Method 'public java.util.Collection getLoggers()' has been added to an interface
134 org.xwiki.logging.LoggerManager: Method 'public void setLoggerLevel(java.lang.String, org.xwiki.logging.LogLevel)' has been added to an interface
135 {{/code}}
136 )))
137 * The Job module is new and is still considered a "young API". Moved from Exception to Throwable parameter for extending jobs. Also added two new methods to check and remove custom properties.(((
138 {{code language="none"}}
139 org.xwiki.job.AbstractJob: Parameter 1 of 'protected void jobFinished(java.lang.Exception)' has changed its type to java.lang.Throwable
140 org.xwiki.job.Request: Method 'public boolean containsProperty(java.lang.String)' has been added to an interface
141 org.xwiki.job.Request: Method 'public java.lang.Object removeProperty(java.lang.String)' has been added to an interface
142 {{/code}}
143 )))
144 * New ##InstalledExtension#isValid()## method.(((
145 {{code language="none"}}
146 org.xwiki.extension.InstalledExtension: Method 'public boolean isValid(java.lang.String)' has been added to an interface
147 {{/code}}
148 )))
149 * The Extension module is relatively new and is still undergoing some API tuning. New method to access environment extension. Also added new methods to execute custom checking before installing/uninstalling an extension.(((
150 {{code language="none"}}
151 org.xwiki.extension.repository.CoreExtensionRepository: Method 'public org.xwiki.extension.CoreExtension getEnvironmentExtension()' has been added to an interface
152 org.xwiki.extension.handler.ExtensionHandler: Method 'public void checkInstall(org.xwiki.extension.Extension, java.lang.String, org.xwiki.job.Request)' has been added to an interface
153 org.xwiki.extension.handler.ExtensionHandler: Method 'public void checkUninstall(org.xwiki.extension.InstalledExtension, java.lang.String, org.xwiki.job.Request)' has been added to an interface
154 {{/code}}
155 )))
156 * Fix method name typo (adding new method). This interface is not really supposed to be implemented except by internal class.(((
157 {{code language="none"}}
158 org.xwiki.properties.PropertyDescriptor: Method 'public java.lang.reflect.Field getField()' has been added to an interface
159 {{/code}}
160 )))
161 * Added method to get the author of the macro.(((
162 {{code language="none"}}
163 org.xwiki.rendering.macro.wikibridge.WikiMacro: Method 'public org.xwiki.model.reference.DocumentReference getAuthorReference()' has been added to an interface
164 {{/code}}
165 )))
166 * Add a method to the oldcore/wikimacro bridge.(((
167 {{code language="none"}}
168 org.xwiki.rendering.macro.wikibridge.WikiMacroFactory: Method 'public boolean isAllowed(org.xwiki.model.reference.DocumentReference, org.xwiki.rendering.macro.wikibridge.WikiMacroVisibility)' has been added to an interface
169 {{/code}}
170 )))
171 * These classes below have never been used. It was supposed to be the start of the removal of Struts but since it hasn't progressed so far we're removing stray code from master. Experiments should be done on feature branches.(((
172 {{code language="none"}}
173 org.xwiki.container.servlet.XWikiServlet: Class org.xwiki.container.servlet.XWikiServlet removed
174 {{/code}}
175 )))
176 * Removed protected method (registerWikiMacros) that was not supposed to be used from outside (was protected for unit tests hacks).(((
177 {{code language="none"}}
178 com.xpn.xwiki.XWiki: Method 'protected void registerWikiMacros()' has been removed
179 {{/code}}
180 )))
181 * Chart plugin has been moved from oldcore to its own module. There's no API breakage for the user.(((
182 {{code language="none"}}
183 com.xpn.xwiki.plugin.charts.Chart: Class com.xpn.xwiki.plugin.charts.Chart removed
184 com.xpn.xwiki.plugin.charts.ChartCustomizer: Class com.xpn.xwiki.plugin.charts.ChartCustomizer removed
185 com.xpn.xwiki.plugin.charts.ChartImpl: Class com.xpn.xwiki.plugin.charts.ChartImpl removed
186 com.xpn.xwiki.plugin.charts.ChartingMacro: Class com.xpn.xwiki.plugin.charts.ChartingMacro removed
187 com.xpn.xwiki.plugin.charts.ChartingPlugin: Class com.xpn.xwiki.plugin.charts.ChartingPlugin removed
188 com.xpn.xwiki.plugin.charts.ChartingPluginApi: Class com.xpn.xwiki.plugin.charts.ChartingPluginApi removed
189 com.xpn.xwiki.plugin.charts.CustomXWikiRenderingEngine: Class com.xpn.xwiki.plugin.charts.CustomXWikiRenderingEngine removed
190 com.xpn.xwiki.plugin.charts.RadeoxHelper: Class com.xpn.xwiki.plugin.charts.RadeoxHelper removed
191 com.xpn.xwiki.plugin.charts.actions.ChartingAction: Class com.xpn.xwiki.plugin.charts.actions.ChartingAction removed
192 com.xpn.xwiki.plugin.charts.exceptions.ChartingException: Class com.xpn.xwiki.plugin.charts.exceptions.ChartingException removed
193 com.xpn.xwiki.plugin.charts.exceptions.ColumnIndexOutOfBoundsException: Class com.xpn.xwiki.plugin.charts.exceptions.ColumnIndexOutOfBoundsException removed
194 com.xpn.xwiki.plugin.charts.exceptions.DataSourceException: Class com.xpn.xwiki.plugin.charts.exceptions.DataSourceException removed
195 com.xpn.xwiki.plugin.charts.exceptions.EmptyDataSourceException: Class com.xpn.xwiki.plugin.charts.exceptions.EmptyDataSourceException removed
196 com.xpn.xwiki.plugin.charts.exceptions.GenerateException: Class com.xpn.xwiki.plugin.charts.exceptions.GenerateException removed
197 com.xpn.xwiki.plugin.charts.exceptions.InvalidArgumentException: Class com.xpn.xwiki.plugin.charts.exceptions.InvalidArgumentException removed
198 com.xpn.xwiki.plugin.charts.exceptions.InvalidParamException: Class com.xpn.xwiki.plugin.charts.exceptions.InvalidParamException removed
199 com.xpn.xwiki.plugin.charts.exceptions.MissingArgumentException: Class com.xpn.xwiki.plugin.charts.exceptions.MissingArgumentException removed
200 com.xpn.xwiki.plugin.charts.exceptions.MissingDataSourceException: Class com.xpn.xwiki.plugin.charts.exceptions.MissingDataSourceException removed
201 com.xpn.xwiki.plugin.charts.exceptions.MissingMandatoryParamException: Class com.xpn.xwiki.plugin.charts.exceptions.MissingMandatoryParamException removed
202 com.xpn.xwiki.plugin.charts.exceptions.NoHeaderColumnException: Class com.xpn.xwiki.plugin.charts.exceptions.NoHeaderColumnException removed
203 com.xpn.xwiki.plugin.charts.exceptions.NoHeaderRowException: Class com.xpn.xwiki.plugin.charts.exceptions.NoHeaderRowException removed
204 com.xpn.xwiki.plugin.charts.exceptions.ParamException: Class com.xpn.xwiki.plugin.charts.exceptions.ParamException removed
205 com.xpn.xwiki.plugin.charts.exceptions.RowIndexOutOfBoundsException: Class com.xpn.xwiki.plugin.charts.exceptions.RowIndexOutOfBoundsException removed
206 com.xpn.xwiki.plugin.charts.params.AbstractChartParam: Class com.xpn.xwiki.plugin.charts.params.AbstractChartParam removed
207 com.xpn.xwiki.plugin.charts.params.BooleanChartParam: Class com.xpn.xwiki.plugin.charts.params.BooleanChartParam removed
208 com.xpn.xwiki.plugin.charts.params.CategoryLabelPositionsChartParam: Class com.xpn.xwiki.plugin.charts.params.CategoryLabelPositionsChartParam removed
209 com.xpn.xwiki.plugin.charts.params.ChartParam: Class com.xpn.xwiki.plugin.charts.params.ChartParam removed
210 com.xpn.xwiki.plugin.charts.params.ChartParams: Class com.xpn.xwiki.plugin.charts.params.ChartParams removed
211 com.xpn.xwiki.plugin.charts.params.ChoiceChartParam: Class com.xpn.xwiki.plugin.charts.params.ChoiceChartParam removed
212 com.xpn.xwiki.plugin.charts.params.ColorChartParam: Class com.xpn.xwiki.plugin.charts.params.ColorChartParam removed
213 com.xpn.xwiki.plugin.charts.params.DateChartParam: Class com.xpn.xwiki.plugin.charts.params.DateChartParam removed
214 com.xpn.xwiki.plugin.charts.params.DateFormatChartParam: Class com.xpn.xwiki.plugin.charts.params.DateFormatChartParam removed
215 com.xpn.xwiki.plugin.charts.params.DateTickMarkPositionChartParam: Class com.xpn.xwiki.plugin.charts.params.DateTickMarkPositionChartParam removed
216 com.xpn.xwiki.plugin.charts.params.DateTickUnitChartParam: Class com.xpn.xwiki.plugin.charts.params.DateTickUnitChartParam removed
217 com.xpn.xwiki.plugin.charts.params.DefaultChartParams: Class com.xpn.xwiki.plugin.charts.params.DefaultChartParams removed
218 com.xpn.xwiki.plugin.charts.params.DefaultChartParams2: Class com.xpn.xwiki.plugin.charts.params.DefaultChartParams2 removed
219 com.xpn.xwiki.plugin.charts.params.DoubleChartParam: Class com.xpn.xwiki.plugin.charts.params.DoubleChartParam removed
220 com.xpn.xwiki.plugin.charts.params.FloatChartParam: Class com.xpn.xwiki.plugin.charts.params.FloatChartParam removed
221 com.xpn.xwiki.plugin.charts.params.FontChartParam: Class com.xpn.xwiki.plugin.charts.params.FontChartParam removed
222 com.xpn.xwiki.plugin.charts.params.HorizontalAlignmentChartParam: Class com.xpn.xwiki.plugin.charts.params.HorizontalAlignmentChartParam removed
223 com.xpn.xwiki.plugin.charts.params.IntegerChartParam: Class com.xpn.xwiki.plugin.charts.params.IntegerChartParam removed
224 com.xpn.xwiki.plugin.charts.params.ListChartParam: Class com.xpn.xwiki.plugin.charts.params.ListChartParam removed
225 com.xpn.xwiki.plugin.charts.params.LocaleChartParam: Class com.xpn.xwiki.plugin.charts.params.LocaleChartParam removed
226 com.xpn.xwiki.plugin.charts.params.MapChartParam: Class com.xpn.xwiki.plugin.charts.params.MapChartParam removed
227 com.xpn.xwiki.plugin.charts.params.NumberFormatChartParam: Class com.xpn.xwiki.plugin.charts.params.NumberFormatChartParam removed
228 com.xpn.xwiki.plugin.charts.params.NumberTickUnitChartParam: Class com.xpn.xwiki.plugin.charts.params.NumberTickUnitChartParam removed
229 com.xpn.xwiki.plugin.charts.params.PlotOrientationChartParam: Class com.xpn.xwiki.plugin.charts.params.PlotOrientationChartParam removed
230 com.xpn.xwiki.plugin.charts.params.Point2DChartParam: Class com.xpn.xwiki.plugin.charts.params.Point2DChartParam removed
231 com.xpn.xwiki.plugin.charts.params.RangeTypeChartParam: Class com.xpn.xwiki.plugin.charts.params.RangeTypeChartParam removed
232 com.xpn.xwiki.plugin.charts.params.RectangleAnchorChartParam: Class com.xpn.xwiki.plugin.charts.params.RectangleAnchorChartParam removed
233 com.xpn.xwiki.plugin.charts.params.RectangleEdgeChartParam: Class com.xpn.xwiki.plugin.charts.params.RectangleEdgeChartParam removed
234 com.xpn.xwiki.plugin.charts.params.RectangleInsetsChartParam: Class com.xpn.xwiki.plugin.charts.params.RectangleInsetsChartParam removed
235 com.xpn.xwiki.plugin.charts.params.RendererClassChartParam: Class com.xpn.xwiki.plugin.charts.params.RendererClassChartParam removed
236 com.xpn.xwiki.plugin.charts.params.ShapeChartParam: Class com.xpn.xwiki.plugin.charts.params.ShapeChartParam removed
237 com.xpn.xwiki.plugin.charts.params.StringChartParam: Class com.xpn.xwiki.plugin.charts.params.StringChartParam removed
238 com.xpn.xwiki.plugin.charts.params.StrokeChartParam: Class com.xpn.xwiki.plugin.charts.params.StrokeChartParam removed
239 com.xpn.xwiki.plugin.charts.params.TimePeriodClassChartParam: Class com.xpn.xwiki.plugin.charts.params.TimePeriodClassChartParam removed
240 com.xpn.xwiki.plugin.charts.params.VerticalAlignmentChartParam: Class com.xpn.xwiki.plugin.charts.params.VerticalAlignmentChartParam removed
241 com.xpn.xwiki.plugin.charts.plots.AreaPlotFactory: Class com.xpn.xwiki.plugin.charts.plots.AreaPlotFactory removed
242 com.xpn.xwiki.plugin.charts.plots.BarPlotFactory: Class com.xpn.xwiki.plugin.charts.plots.BarPlotFactory removed
243 com.xpn.xwiki.plugin.charts.plots.CategoryPlotFactory: Class com.xpn.xwiki.plugin.charts.plots.CategoryPlotFactory removed
244 com.xpn.xwiki.plugin.charts.plots.LinePlotFactory: Class com.xpn.xwiki.plugin.charts.plots.LinePlotFactory removed
245 com.xpn.xwiki.plugin.charts.plots.PiePlotFactory: Class com.xpn.xwiki.plugin.charts.plots.PiePlotFactory removed
246 com.xpn.xwiki.plugin.charts.plots.PlotFactory: Class com.xpn.xwiki.plugin.charts.plots.PlotFactory removed
247 com.xpn.xwiki.plugin.charts.plots.TableXYDatasetFactory: Class com.xpn.xwiki.plugin.charts.plots.TableXYDatasetFactory removed
248 com.xpn.xwiki.plugin.charts.plots.TimePlotFactory: Class com.xpn.xwiki.plugin.charts.plots.TimePlotFactory removed
249 com.xpn.xwiki.plugin.charts.plots.TimeSeriesCollectionFactory: Class com.xpn.xwiki.plugin.charts.plots.TimeSeriesCollectionFactory removed
250 com.xpn.xwiki.plugin.charts.plots.XYPlotFactory: Class com.xpn.xwiki.plugin.charts.plots.XYPlotFactory removed
251 com.xpn.xwiki.plugin.charts.source.DataSource: Class com.xpn.xwiki.plugin.charts.source.DataSource removed
252 com.xpn.xwiki.plugin.charts.source.DataSourceFactory: Class com.xpn.xwiki.plugin.charts.source.DataSourceFactory removed
253 com.xpn.xwiki.plugin.charts.source.DefaultDataSource: Class com.xpn.xwiki.plugin.charts.source.DefaultDataSource removed
254 com.xpn.xwiki.plugin.charts.source.MainDataSourceFactory: Class com.xpn.xwiki.plugin.charts.source.MainDataSourceFactory removed
255 com.xpn.xwiki.plugin.charts.source.ObjectDataSourceFactory: Class com.xpn.xwiki.plugin.charts.source.ObjectDataSourceFactory removed
256 com.xpn.xwiki.plugin.charts.source.ObjectidDataSourceFactory: Class com.xpn.xwiki.plugin.charts.source.ObjectidDataSourceFactory removed
257 com.xpn.xwiki.plugin.charts.source.TableDataSource: Class com.xpn.xwiki.plugin.charts.source.TableDataSource removed
258 com.xpn.xwiki.plugin.charts.source.TableDataSourceFactory: Class com.xpn.xwiki.plugin.charts.source.TableDataSourceFactory removed
259 com.xpn.xwiki.plugin.charts.wizard.DatasourceDefaultsHelper: Class com.xpn.xwiki.plugin.charts.wizard.DatasourceDefaultsHelper removed
260 com.xpn.xwiki.plugin.charts.wizard.FontHelper: Class com.xpn.xwiki.plugin.charts.wizard.FontHelper removed
261 {{/code}}
262 )))
263 * {{todo/}}Andreas, please explain why we have to break backward compatibility for the Chart module.(((
264 {{code language="none"}}
265 org.xwiki.chart.model.ChartModel: Method 'public org.jfree.chart.axis.Axis getAxis(int)' has been added to an interface
266 org.xwiki.chart.model.ChartModel: Method 'public java.lang.Number getCellValue(int, int)' has been removed
267 org.xwiki.chart.model.ChartModel: Method 'public int getColumnCount()' has been removed
268 org.xwiki.chart.model.ChartModel: Method 'public java.lang.String getColumnHeader(int)' has been removed
269 org.xwiki.chart.model.ChartModel: Method 'public org.jfree.data.general.Dataset getDataset()' has been added to an interface
270 org.xwiki.chart.model.ChartModel: Method 'public int getRowCount()' has been removed
271 org.xwiki.chart.model.ChartModel: Method 'public java.lang.String getRowHeader(int)' has been removed
272 org.xwiki.chart.model.DefaultChartModel: Class org.xwiki.chart.model.DefaultChartModel removed
273 org.xwiki.rendering.macro.chart.ChartDataSource: Field PARAMS has been removed, but it was previously a constant
274 org.xwiki.rendering.macro.chart.ChartDataSource: Field SOURCE has been removed, but it was previously a constant
275 {{/code}}
276 )))

Get Connected