Hello all,
XWIKI-17401 was reported and implemented back in 12.x . It was also discussed on this thread XWIKI-17401 - Option for deleting documents and/or attachments without sending to recycle bin .
I think there was a real misunderstanding about the purpose of XWIKI-17401 when this was implemented, I wonder if we can change it now or we need to add an extra option for it (thus making it a bit more complicated).
I think the original intent (as also expressed by @mleduc in XWIKI-17401 - Option for deleting documents and/or attachments without sending to recycle bin - #20 by mleduc ) was that a user that has the appropriate rights to delete from recycle bin can take a shortcut and delete directly a content skipping the recycle bin.
More specifically, without XWIKI-17401:
As an admin, I can (with admin and/or programming rights):
- delete a page from the UI - this will send it to the recycle bin
- go to the recycle bin administration and delete the page permanently
- also, I don’t have to go to the recycle bin, I can just stay on the page itself and just click “delete” in the recycle bin view.
As a regular user (with delete rights):
- I can delete a page from the UI (or programatically), and it will go to the recycle bin
- I cannot go to the recycle bin to delete the page permanently, the button on the UI of the deleted page is not present to allow me to delete the page from the UI.
With XWIKI-17401, the original intent was to be able to:
As an admin:
- choose to skip the recycle bin when deleting the page in the first place, from the UI, without having to do the 2 operations. Differently said, do the 2 operations in a single one, do only one operation instead of 2.
- this should apply to the UI but also to the refactoring API. It should be possible to write a script that would fire an operation for deletion with skipping the recycle bin.
As a regular user, nothing should change, in the UI or in the API.
What was actually implemented (and it’s a misunderstanding and a complication of the situation, from my pov), is a bypass of the right to delete permanently, applicable to all users once it’s activated, regardless of their rights.
With XWIKI-17401, what is now possible:
There is an option in the administration to allow skipping recycle bin. If this option is not activated, nothing changes compared to before XWIKI-17401.
However, when this option is activated:
As an admin user and as a regular user, I can:
- set my user to be an advanced user, in order to benefit from the option
- from the delete UI, I can check a box to delete while skipping recycle bin, in order to delete a page directly, without having it go to the recycle bin
- from the refactoring API, I can start a job to do a deletion with skipping the recycle bin, and it also will delete permanently.
The problem with the current implementation is that the scenario that was intended — allowing users having rights to do it all at once — is still not possible, and a new option to bypass permanent delete rights was added, unneccessarily if you ask me.
As a corollary of this, today there is a refactoring API to fire a delete job with skipping the recycle bin, but if I use it as an admin, it will still not work as long as the option to allow permanent delete is not activated; activating the option will open it to everyone.
The whole objective of XWIKI-17401 and its urgency was to handle space tight scenarios. Right now, if one wants to do that, they need to open the feature to everyone, not only to rights holders.
Now, the “urgency” turns out to be quite relative, given that it took 5 years for me to find that the initial purpose doesn’t correspond to the result. Or maybe the option in the administration is misunderstood, and many people use it thinking that it will only allow admins to delete permanently, not everyone.
What do you think?
How should we go about the implementation of the actual need described above - new issue, change of the current implementation?
Did anybody use the option added by XWIKI-17401 ?
Do you need it for all users or only for admins? Did you know it’s working for all users or you thought it only works for admins?
Thanks,
Anca