Are the parameters for Divisor and Probability still necessary after convert plugin to task (#41326) where it is possible to set execution rules?
Labels |
Added:
No Code Attached Yet
|
I only found references in the plugin itself
joomla-cms/plugins/task/sessiongc/src/Extension/SessionGC.php
Lines 122 to 129 in 03da48b
If i see it right this function ($this->getApplication()->getSession()->gc()
) calls only session_gc
in the session framework
https://github.com/joomla-framework/session/blob/95c74bd3c8546b73c49440c426eef734a30ea97b/src/Storage/NativeStorage.php#L134
And the task parameter have nothing to do with the php parameter
https://www.php.net/manual/en/session.configuration.php#ini.session.gc-probability
If I search in the code there is only one result: session.gc_maxlifetime
@heelc29 From what I can see you are right. It was once implemented in Joomla 3.8.6 in that way so it behaves same as the PHP sessiongc, as far as I understand: #19687 . But the parameters are not really related to those used by PHP, and now as we have a scheduled task I also think it should not need that.
However, I am not really an expert on our session handling. I only took the task to finish the scheduler task plugins for J5 because of the beta 1 with the feature freeze being so close and the author of the PRs having been busy with his regular, daily job. So for me it would be ok if someone else takes that task and fixes that. But it should be tested with real tests, not just by code review, so it needs to write good testing instructions.
I am not really an expert on our session handling
Me neither
Parameters can be removed, they are only used to not run the garbage collection with each request.
Parameters can be removed, they are only used to not run the garbage collection with each request.
@HLeithner Can the corresponding language strings be removed, too? Or shall they be deprecated?
can be removed too since they are new in j5
Labels |
Added:
bug
|
Status | New | ⇒ | Closed |
Closed_Date | 0000-00-00 00:00:00 | ⇒ | 2023-09-08 16:10:55 |
Closed_By | ⇒ | heelc29 |
It might depend on the configured session handler, if file or database. I think for file they might still be needed because these parameters are passed to php built in methods, and php handles deletion. For database where Joomla handles deletion they might not be necessary. But I am not really sure, I just remember something like that.