Wiki source code of XWiki Enterprise 2.2

Last modified by Thomas Mortagne on 2023/10/13

Show last authors
1 {{box cssClass="floatinginfobox" title="**Contents**"}}{{toc/}}{{/box}}
2
3 {{error}}There is several critical bugs in 2.2 around document parents and new importer. It will be fixed and part of the 2.2.1 release in the coming few days.{{/error}}
4
5 This release contains many important UI improvements of existing features (xar import, user registration, comments, etc.), and introduces the new Model API starting with a new ##EntityReference## and related tools to remove all String manipulations around documents and attachment names.
6
7 = New and Noteworthy (since XWiki Enterprise 2.1.2) =
8
9 == New XAR Import UI ==
10
11 The XAR import interface has been completely revamped. The new interface (see screenshots below) now provides:
12
13 * More explicit options regarding revision history handling
14 * The new option to **add a new version to existing documents** instead of overriding them
15 * A rich UI that allows to select/unselect whole spaces at once
16 * Support for importing when no javascript is available. The UI degrades nicely to a less rich interface
17
18 image:import.png
19
20 == UI for Deleted documents & attachments ==
21
22 While deleted documents and attachments have been stored in a trash instead of being completely deleted since XWiki 1.2, there was no general interface for viewing the contents of the trash. This has been remedied by the introduction of two new tabs in the wiki's Document Index, //Deleted Documents// and //Deleted Attachments//.
23
24 image:[email protected]
25
26 Both use the livetable, thus allowing filtering and ordering for easier browsing. A document from the trash can be viewed, permanently deleted, or restored if the location is still available.
27
28 image:[email protected]
29
30 The attachment trash contains only attachments deleted from a document, and not attachments that were deleted together with their owner document; in the latter case, the attachments are kept together with the document in the document trash. For attachments, there is no restore option yet, it will be implemented in a future release.
31
32 image:[email protected]
33
34 == New Profile & WatchList UI ==
35
36 Complete **overhaul of the Profile UI**: better display of the user information, recent changes by the user are shown, different tabs for user details, user settings, and watchlist information:
37
38 image:profile.png
39
40 Improved inline-based editing for modifying profile details:
41
42 image:profileedit.png
43
44 Inclusion of the **WatchList manager** page into the Profile as a tab:
45
46 image:watchlist.png
47
48 Added a tab in the //Profile// for managing **user preferences**, which is currently rather small, but will be improved later to include more settings:
49
50 image:preferences.png
51
52 image:preferencesedit.png
53
54 User profiles have been converted to XWiki Syntax 2.0
55
56 == New Registration page, new CAPTCHA implementation ==
57
58 image:registration.png
59
60 The new features are:
61 * Ability to display a CAPTCHA for spam prevention. Note that by default the CAPTCHA test is disabled, it must be enabled in ##xwiki.properties##.
62 * All fields are checked by client-side script as the user types, then checked by the server for security.(((
63 {{info}}The default minimum password size is now 6 characters.{{/info}}
64 )))
65 * One-click login after registration.(((
66 image:autologin.png
67 )))
68 * Easy for administrators to add new fields, configuration with code.
69 * The registration page can be imported/edited without programming rights, allowing easier customization of the registration in a wiki farm
70 * Works on older wikis if LiveValidation is imported (CAPTCHA won't appear)
71
72 == New Menu in Edit mode ==
73
74 The different edition modes that used to be in a separate Panel are now in a new edit menu (similarly to the menu you get in view mode).
75
76 image:editmenu.png
77
78 == Comments UI improvements ==
79
80 === Preview comment ===
81
82 The users have the possibility to preview their comment before submitting it. A current known limitation is that the preview does not work for unauthenticated users.
83
84 image:commentpreview.png
85
86 image:commentpreviewing.png
87
88 === Edit comment ===
89
90 The users have the possibility to edit their comments. This only works for authenticated users, since there is no way of knowing which unauthenticated user created a guest comment.
91
92 image:commentedit.png
93
94 image:commentediting.png
95
96 == WYSIWYG and Rendering improvements ==
97
98 * Add API to find the syntax of the executing document from scripts
99 * Macro descriptions can now be translated(((
100 image:wysiwygl10n.png
101
102 image:wysiwygl10n2.png
103 )))
104
105 == General UI improvements ==
106
107 * In the wiki source code viewer, allow to toggle line numbers faster from Javascript
108 * Enable full screen view when displaying the wiki source code (viewer=code)
109 * ActionMenu: Add Profile submenu item to the "current user" menu(((
110 image:usermenu.png
111 )))
112 * Reorder the document actions in the "More actions" menu: copy, rename, delete(((
113 image:moreactionsmenu.png
114 )))
115 * More UI components make use of the (recently introduced) color theme
116 * All panels have nice readable names
117 * Allow to copy a document's default language + all translations in the copy menu action(((
118 image:copyl10n.png
119 )))
120
121 == Contextual wiki macros ==
122
123 Previously, [[wiki macros>>Documentation.DevGuide.WikiMacroTutorial]] could only be defined by users with administrator rights, and only in the main wiki (when in a virtual wiki farm). It's now possible for any user to register wiki macros, and in any wiki. However, this follows some user rights restrictions, preventing a limited user to write dangerous scripts available to all other users. For example, if the user does not have the proper rights, only he will see and use the macro he registered. To make the macro available globally, an administrator must re-save it.
124
125 == New Model module with Reference implementation ==
126
127 The goal is to provide {{scm branch="xwiki-core-2.2" path="xwiki-model"}}APIs{{/scm}} to remove all String manipulations around documents and attachment names. It also introduces the concept of Reference for any entity of the model and the parser/serializer associated. For now Wiki, Space, Document and attachment are supported; classes objects and properties should come in 2.3 branch.
128
129 From a user point of view this will result in supporting any character in document names for example. In addition, this is also a step in the direction of supporting nested spaces (the storage would also need to be changed to support that).
130
131 In practice the existing code has not yet been fully refactored to benefit from the new implementation. The work has been started in XWiki Enterprise 2.2 Milestone 1 and will continue in XWiki Enterprise 2.3 and beyond.
132
133 {{warning}}
134 Since the work is partial, and URL parsing is not based on references yet in XWiki Enterprise 2.2, using special character (dot in particular) in space names and document names is not recommended. This could create documents that are unreachable or other weird behaviors.
135 {{/warning}}
136
137 == Development improvements ==
138
139 * Added support for "xcontext" binding in 1.0 groovy macro
140 * Allow set to null in velocity
141 * Add an API method for creating a LinkedHashMap
142 * New APIs for accessing deleted attachments from the trash
143 * The class wizard should propose to add a SheetClass object to the class sheet
144 * Add support for 'on page' style extensions
145
146 == Office import improvements ==
147
148 * Added support for Office2007 document formats
149
150 == Blog improvement ==
151
152 * Added the Create a new post to category pages - when used by default select that category
153
154 == Dependencies upgrade ==
155
156 * Upgraded to Groovy 1.7
157 * Upgrade to GWT 2.0.0
158
159 == Miscellaneous ==
160
161 * Always use UTF-8 for URL encoding
162 * Attachments should produce document modification events
163 * New user profile pages are created in XWiki Syntax 2.0
164 * New zh_TW translation
165
166 * Lots of accessibility fixes
167 * Lots of bug fixes
168
169 = Known issues =
170
171 * [[Bugs we know about>>https://jira.xwiki.org/secure/IssueNavigator.jspa?reset=true&&type=1&pid=10010&resolution=-1&sorter/field=updated&sorter/order=DESC]]
172
173 = Backward Compatibility and Migration Notes =
174
175 == Important non-compatible changes ==
176
177 {{warning}}
178 The way URLs are generated and parsed has changed. While previously the wiki encoding was used to convert non-ASCII bytes to their ##%XY## escapes, as allowed by the older HTTP/URL specifications, now all URLs escape the UTF-8 bytes of the path, to better adhere to the modern URI specification. This should only affect non-UTF-8 wikis, and only by breaking some bookmarks.
179 {{/warning}}
180
181 {{warning}}
182 The velocity configuration has been changed so that setting ##null## values to variables is now allowed. This could break some scripts and macros, please check before upgrading.
183 {{/warning}}
184
185 This means that the following script will generate a different result:
186
187 {{code language="none"}}
188 #set($s = 'abc')
189 $s
190 #set($s = $util.null)
191 $s
192 {{/code}}
193
194 While previously the result would have been ##abc abc##, now it is ##abc $s##.
195
196 Special care must be taken care with constructs like the following:
197
198 {{code language="none"}}
199 #set($var = '')
200 #set($var = $xwiki.methodThatMightReturnNull())
201 #if($var != '')
202 The method succeeded
203 #else
204 The method failed
205 #end
206 {{/code}}
207
208 Since ##null != ''## in Velocity, now a different branch will be executed. The following rewrites work.
209
210 Works in both modes, with or without null allowed:
211 {{code language="none"}}
212 #set($var = '')
213 #set($var = $xwiki.methodThatMightReturnNull())
214 #if("$!var" != '')
215 The method succeeded
216 #else
217 The method failed
218 #end
219 {{/code}}
220
221 Works only in the new mode, with null allowed, but is shorter, slightly faster, and more familiar for java developers:
222 {{code language="none"}}
223 #set($var = $xwiki.methodThatMightReturnNull())
224 #if($!var != $util.null)
225 The method succeeded
226 #else
227 The method failed
228 #end
229 {{/code}}
230
231 == Captcha ==
232
233 Captcha related configuration changed in Struts configuration file. If you keep the old file it will fail silently so make sure to use the proper configuration you can find in the new file (or overwrite it if you don't have any local modification obviously).
234
235 == Removed pages ==
236
237 * Main.RecentMembers has been removed from default XWiki Enterprise xar
238
239 == General Notes ==
240
241 {{warning}}If you're running in a multiwiki setup you'll also need to define the property //xwiki.store.migration.databases=all// to your //xwiki.cfg// file or explicitly name all databases to be migrated as in <tt>xwiki.store.migration.databases=db1,db2,...//.{{/warning}}
242
243 You may also want to [[import the default wiki XAR>>Main.Download]] in order to benefit from the improvements listed above.
244
245 {{warning}}Always make sure you compare your //xwiki.cfg// file with the newest version since some configuration parameters were added. Note 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.{{/warning}}
246
247 == Migration Notes ==
248
249 * The new parser/serializer for document names comes with new features and changes some behaviors:
250 ** introducing escaping means:
251 *** ##\## which is now the escaping character needs to be doubled in full document name, as in ##{{{Space.Docu\\ment}}}##, which means space ##Space## and document ##{{{Docu\\ment}}}##
252 *** some generated documents names will now contains ##\## to escape thing like dot in a document name. For example ##Space.Docu\.ment## means space ##Space## and document ##Docu.ment##
253 ** support for the syntax ##wikiname:Document## has been dropped, so in this example "wikiname:Document" will be seen as the document name because no ##.## has been found
254 * If you had Wiki Macros defined in your wiki before, you might want to edit them to check their visibility field since the notion of visibility was introduced in XE 2.2 and the default value is user-visibility.
255 * CoreConguration#getSyntax now returns a Syntax object instead of a String
256
257 = Dependencies =
258
259 This release includes the following modules in the specified versions since XWiki Enterprise 2.1.2 was released.
260
261 == Core/Web ==
262
263 |=Group Id|=Artifact Id|=New Version|=Old Version|=JIRA URL
264 |##com.xpn.xwiki.platform##|##xwiki-*##|2.2|2.1.2|[[jira>>https://jira.xwiki.org/browse/XWIKI]]
265 |##org.xwiki.platform##|##xwiki-*##|2.2|2.1.2|[[jira>>https://jira.xwiki.org/browse/XWIKI]]
266
267 == Applications ==
268
269 |=Group Id|=Artifact Id|=New Version|=Old Version|=JIRA URL
270 |##com.xpn.xwiki.platform.applications##|##xwiki-application-administration##|1.26|1.21|[[jira>>https://jira.xwiki.org/browse/XAADMINISTRATION]]
271 |##com.xpn.xwiki.platform.applications##|##xwiki-application-blog##|1.20|1.18|[[jira>>https://jira.xwiki.org/browse/XABLOG]]
272 |##com.xpn.xwiki.platform.applications##|##xwiki-application-officeimporter##|1.13|1.12|[[jira>>https://jira.xwiki.org/browse/XAOFFICE]]
273 |##com.xpn.xwiki.platform.applications##|##xwiki-application-panels##|1.34|1.30|[[jira>>https://jira.xwiki.org/browse/XAPANELS]]
274 |##com.xpn.xwiki.platform.applications##|##xwiki-application-scheduler##|1.16|1.15|[[jira>>https://jira.xwiki.org/browse/XASCH]]
275 |##com.xpn.xwiki.platform.applications##|##xwiki-application-statistics##|1.6|1.5|[[jira>>https://jira.xwiki.org/browse/XASTATS]]
276 |##com.xpn.xwiki.platform.applications##|##xwiki-application-tag##|1.10|1.8|[[jira>>https://jira.xwiki.org/browse/XATAG]]
277 |##com.xpn.xwiki.platform.applications##|##xwiki-application-watchlist##|1.26|1.23|[[jira>>https://jira.xwiki.org/browse/XPWATCHLIST]]
278 |##com.xpn.xwiki.platform.applications##|##xwiki-application-webdav##|1.3|1.2|[[jira>>https://jira.xwiki.org/browse/XAWEBDAV]]
279 |##com.xpn.xwiki.platform.applications##|##xwiki-application-wiki-macro-bridge##|1.3|1.2|[[jira>>https://jira.xwiki.org/browse/XAWMB]]
280
281 == Plugins ==
282
283 |=Group Id|=Artifact Id|=New Version|=Old Version|=JIRA URL
284 |##com.xpn.xwiki.platform.plugins##|##xwiki-plugin-activitystream##|1.6|1.5|[[jira>>https://jira.xwiki.org/browse/XPAS]]
285 |##com.xpn.xwiki.platform.plugins##|##xwiki-plugin-jodatime##|1.3|1.3|[[jira>>https://jira.xwiki.org/browse/XPJODA]]
286 |##com.xpn.xwiki.platform.plugins##|##xwiki-plugin-lucene##|1.16|1.12|[[jira>>https://jira.xwiki.org/browse/XPLUCENE]]
287 |##com.xpn.xwiki.platform.plugins##|##xwiki-plugin-mailsender##|1.13|1.13|[[jira>>https://jira.xwiki.org/browse/XPMAIL]]
288 |##com.xpn.xwiki.platform.plugins##|##xwiki-plugin-scheduler##|1.16|1.15|[[jira>>https://jira.xwiki.org/browse/XASCH]]
289 |##com.xpn.xwiki.platform.plugins##|##xwiki-plugin-skinx##|1.13|1.12|[[jira>>https://jira.xwiki.org/browse/XSKINX]]
290 |##com.xpn.xwiki.platform.plugins##|##xwiki-plugin-tag##|1.10|1.8|[[jira>>https://jira.xwiki.org/browse/XATAG]]
291 |##com.xpn.xwiki.platform.plugins##|##xwiki-plugin-watchlist##|1.26|1.23|[[jira>>https://jira.xwiki.org/browse/XPWATCHLIST]]
292
293 == Skins ==
294
295 |=Group Id|=Artifact Id|=New Version|=Old Version|=JIRA URL
296 |##com.xpn.xwiki.platform.skins##|##xwiki-skin-albatross##|1.27|1.26|[[jira>>https://jira.xwiki.org/browse/XSALBATROSS]]
297 |##com.xpn.xwiki.platform.skins##|##xwiki-skin-colibri##|1.12.1|1.8|[[jira>>https://jira.xwiki.org/browse/XSCOLIBRI]]
298 |##com.xpn.xwiki.platform.skins##|##xwiki-skin-toucan##|1.32|1.31|[[jira>>https://jira.xwiki.org/browse/XSTOUCAN]]
299
300 == Top Level POM ==
301
302 |=Group Id|=Artifact Id|=New Version|=Old Version
303 |##com.xpn.xwiki.platform##|##xwiki##|29|29
304
305 == Tools ==
306
307 |=Group Id|=Artifact Id|=New Version|=Old Version|=JIRA URL
308 |##org.xwiki.platform.tools##|##xwiki-configuration-resources##|1.36|1.36|[[jira>>https://jira.xwiki.org/browse/XTCONFRES]]
309 |##org.xwiki.platform.tools##|##xwiki-jetty-resources##|1.17|1.17|[[jira>>https://jira.xwiki.org/browse/XTJETTY]]
310 |##org.xwiki.platform.tools##|##xwiki-license-resources##|1.1|1.1|[[jira>>https://jira.xwiki.org/browse/XTLICENSE]]
311 |##org.xwiki.platform.tools##|##xwiki-packager-plugin##|1.15|1.15|[[jira>>https://jira.xwiki.org/browse/XTPACKAGER]]
312 |##org.xwiki.platform.tools##|##xwiki-rootwebapp##|1.3|1.3|[[jira>>https://jira.xwiki.org/browse/XTROOT]]
313 |##org.xwiki.platform.tools##|##standards-validator##|1.1|1.1|[[jira>>https://jira.xwiki.org/browse/XTVALIDATOR]]
314 |##org.xwiki.platform.tools##|##xwiki-xar-handlers##|1.9|1.9|[[jira>>https://jira.xwiki.org/browse/XTXARHANDLER]]
315 |##org.xwiki.platform.tools##|##xwiki-xar-plugin##|1.13|1.13|[[jira>>https://jira.xwiki.org/browse/XPXARPLUGIN]]
316 |##org.xwiki.platform.tools##|##xwiki-verification-resources##|1.15|1.14|[[jira>>https://jira.xwiki.org/browse/XTVERIFICATIONS]]

Get Connected