Skip to content

Feature 10786 #901

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 3 commits into from
May 7, 2025
Merged

Feature 10786 #901

merged 3 commits into from
May 7, 2025

Conversation

mmoqui
Copy link
Member

@mmoqui mmoqui commented Apr 30, 2025

Implement a scheduled bins purger for the Kmelia instances. This purger is disabled by default. To enable it, just set the following properties kmelia.autoDeletionDelay and kmelia.autoDeletionCron in the configuration file kmeliaSettings.properties. The first property is to specify the threshold in days a contribution can be kept in a bin before its definitive deletion, and the second property is a CRON statement to plan the execution of the purger.

For its working, the purger uses the new NodeDetail and PublicationDetail removal attributes to compute the number of days the topics and the publications are in the bins in order to know if they have exceeded the delay.

This PR requires the following one Silverpeas/Silverpeas-Core#1403

mmoqui added 3 commits April 17, 2025 17:01
Add the KmeliaBinsScheduledPurger to purge periodically the all the bins
of the different Kmelia instances of the items (both publications and
topics) that have been removed (place in the bin) at a date older than a
given delay in days. The recurrence of the task and the delay are set in
the org/silverpeas/kmelia/settings/kmeliaSettings.properties
configuration file.
Take into account the PublicatonService#removePublication and
NodeService#removeNode are renamed to
PublicationService#deletePublication and NodeService#deleteNode.

Take use of the new removal state for publication and node when such a
contribution is put in the bin or restored from the bin in Kmelia.
In Kmelia, take into account topics and publications can be moved or
copied from/to bins in the same or in another Kmelia instances; their
removal status have to be modified consequently of the move or copy
operation.

In the Kmelia bin purger, take into account of the removal properties of
both NodeDetails and PublicationDetails. For all publications and nodes
previously removed (put in the bin) before this feature, the purger will
erase them automatically (we don't know their removal date so, as such,
we make the assumption their deletion are older than the purge delay
setting).
Fix a bug with the Kmelia instance ids: globalize them to be taken by
NodeService and PublicationService to identify the nodes and the
publications in the different Kmelia instances.
Copy link

@mmoqui mmoqui merged commit 6a76240 into master May 7, 2025
3 checks passed
@mmoqui mmoqui deleted the feature-10786 branch June 2, 2025 09:49
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant