Hi devs,
Today, changes that nobody made by hand are attributed either to the last person who edited the page (e.g. when a page is updated by an initializer, a migration or a background listener, since XWiki#saveDocument doesn’t set an author) or to superadmin (pages created by the platform or installed by the Distribution Wizard). Users see in their history and notifications changes they never made, “superadmin” means nothing to them, and the actions of an admin using the superadmin account can’t be told apart from automatic changes.
This has been discussed several times (2009, 2015, 2016, 2017) without a decision on a dedicated user. Since 14.0 we have the original metadata author (displayed) separate from the effective metadata author (rights), which makes it possible now without touching rights.
I’ve written the full design here: https://design.xwiki.org/xwiki/bin/view/Proposal/SystemUser
Summary:
- A virtual System user (
SystemUserReference, reserved nameXWikiSystem, stored asXWiki.XWikiSystem): no user page, can’t log in, holds no rights. The name is reserved in all user creation paths. - Only ever the original metadata author, never the effective or content author. The authorization manager denies it every right, unconditionally. No code runs as it.
- Superadmin goes back to being the recovery account: only what a human does while logged in as superadmin is attributed to it.
- Automatic change = a change no human asked for (initializers, migrations, background listeners/stores, Distribution Wizard and wiki creation installs, extensions’ background processing). A side effect of an action a human asked for (e.g. backlinks updated on rename) stays attributed to that human. Extensions installed/upgraded by a user from the EM are unchanged (Thomas has a separate proposal about the user the DW/EM run with; not mixed here).
- For a page created automatically: original author and creator = System, effective and content author = superadmin as today (no change in rights). For an update: only the original author changes.
- Display: a translated “System”, no link, a dedicated icon (and dedicated icons for superadmin and Guest too, UI by the UI/UX team). The “last author” livetable / Live Data column and a few templates switch from the effective to the original author, like the page header and history already do.
- Notifications: the “hide system changes” filter hides System and, during a transition with no end date for now, superadmin too (configurable), with a deprecation warning to find extensions still saving as superadmin.
- API:
SystemUserReference.INSTANCE+ one Java helper; a read-only$services.user.systemUserReference, no script API to save as System. - No data migration: existing history keeps its authors.
It’s compatible with, and independent from, Michael’s proposal to deprecate the effective metadata author.
The design page has the details, the implementation phases and the open questions.
The first phase is independent from the System user (it also fixes existing inconsistencies) and I’ve already filed it:
- XWIKI-25307: Display the original metadata author in the “last author” livetable and Live Data column
- XWIKI-25308: Use the original metadata author in the HTML author meta tag, the PDF cover and the document index
- XWIKI-25309: Display virtual users (superadmin, Guest) with their user properties instead of their page name
- XWIKI-25310: Add dedicated icons for the superadmin and Guest users (discussed in Dedicated icons for the superadmin, Guest and System users)
WDYT?
Here’s my +1
Thanks
PS: This post was co-written with Claude Code.