Skip to content

Comments

[5] add2scheduler-deleteactionlogs#41064

Merged
HLeithner merged 42 commits intojoomla:5.0-devfrom
alikon:add2scheduleractionlogsdelete
Sep 3, 2023
Merged

[5] add2scheduler-deleteactionlogs#41064
HLeithner merged 42 commits intojoomla:5.0-devfrom
alikon:add2scheduleractionlogsdelete

Conversation

@alikon
Copy link
Contributor

@alikon alikon commented Jun 27, 2023

split from #40519

Summary of Changes

add the plg_system_actionlogs feature "Days to delete logs after" to a proper scheduled task plugin

Testing Instructions

Hint: The execution times and hours shown for tasks in the administrator are in the UTC timezone.

New installation

Make a new installation with this PR applied.

Check if there is an enabled task scheduler plugin "Task - Delete Action Logs".

Check if there is any scheduled task using that plugin.

Update

On a Joomla 4.4-dev version or 4.4.0 alpha 4, note the endabled status and the configuration parameters of the of the "System - User Actions Log" plugin.

Now either disable that plugin or enable it and optionally change some of the configuration parameters to a value different to the default.

Update to the patched package or custom update URL created by Drone for this PR.

Check if the configuration parameters of the "System - User Actions Log" plugin have been removed.

Check if there is a task scheduler plugin "Task - Delete Action Logs".

Check enabled status and configuration parameters of that plugin.

Check if there is a scheduled task "DeleteActionLogs" using that plugin. If so, check the configuration parameters, too.

Repeat the previous steps with different endabled status of the "System - User Actions Log" plugin and - if enabled - different configuration parameters.

Actual result BEFORE applying this Pull Request

Deletion of outdated user action logs is done by the "System - User Actions Log" plugin.

Expected result AFTER applying this Pull Request

New installation

The "Task - Delete Action Logs" plugin is enabled.

There is no scheduled task using that plugin because on a new installation old user action logs are not configured to be deleted (parameter "Days to delete logs after" = 0).

Update

The configuration parameters of the "System - User Actions Log" plugin have been removed by the update.

A new task scheduler plugin "Task - Delete Action Logs" has been created and is enabled.

If the "System - User Actions Log" plugin was enabled and field "Days to delete action logs after" was set to a value greater than zero in the parameters of that plugin before the update, a new scheduled task "DeleteActionLogs" has been created and is enabled.

The task will execute every 24 hours at the hour of the Joomla installation.

The configuration parameter "Days to delete action logs after" of that task is set to the same value of the same parameter of the old system plugin.

If the old "System - User Actions Log" plugin was disabled or field "Days to delete action logs after" was set to zero in the parameters of that plugin before the update, there is no task for that plugin.

Link to documentations

Please select:

  • Documentation link for docs.joomla.org: link will be added later

  • No documentation changes for docs.joomla.org needed

  • Pull Request link for manual.joomla.org:

  • No documentation changes for manual.joomla.org needed

@joomla-cms-bot joomla-cms-bot added Language Change This is for Translators PR-5.0-dev labels Jun 27, 2023
@alikon alikon changed the title add2schedulerdeleteactionlogs [5] add2scheduler-deleteactionlogs Jun 27, 2023
@richard67
Copy link
Member

@alikon I've allowed myself to update your branch to latest 5.0-dev and fix the conflict. Please pull the changes before you continue to work on your local clone.

@richard67
Copy link
Member

@alikon Could you rename the update SQL scripts to something newer than "5.0.0-2023-07-12.sql" (= newest update SQL right now in the 5.0-dev branch), e.g. to "5.0.0-2023-07-27.sql"? Thanks in advance.

@alikon alikon marked this pull request as ready for review August 3, 2023 11:41
@richard67
Copy link
Member

@alikon It needs again to rename the update SQL scripts, this time to something newer than "5.0.0-2023-08-21.sql". I suggest to use "5.0.0-2023-08-25.sql" for this PR here.

@alikon
Copy link
Contributor Author

alikon commented Aug 26, 2023

done

@HLeithner
Copy link
Member

please resolve conflicts, since the checkin task has been merged.

Building multiple PRs editing the same files would better be done based on each other.

@richard67
Copy link
Member

@alikon I've solved the merge conflict caused by the recently merged globalcheckin task plugin, so before you continue to work locally on your branch you have to pull the changes from remote.

alikon and others added 3 commits August 27, 2023 11:03
Co-authored-by: heelc29 <66922325+heelc29@users.noreply.github.com>
@richard67
Copy link
Member

@heelc29 The PR is ready for testing. Code style error is not related to the PR but to the current 5.0-dev branch. Could you test again? Testing instructions can be found in the description of this PR. Thanks in advance.

@richard67
Copy link
Member

I've updated the testing instructions by more detailed tests.

@richard67
Copy link
Member

I have tested this item ✅ successfully on f422632


This comment was created with the J!Tracker Application at issues.joomla.org/tracker/joomla-cms/41064.

@HLeithner HLeithner merged commit 9ea35c7 into joomla:5.0-dev Sep 3, 2023
@HLeithner
Copy link
Member

thanks richard awesome work

@alikon
Copy link
Contributor Author

alikon commented Sep 4, 2023

thank you all for your help

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants