Skip to content

[stable29] fix(cron): Log long running jobs - #45813

Merged
ChristophWurst merged 1 commit into
stable29from
backport/45804/stable29
Jun 12, 2024
Merged

[stable29] fix(cron): Log long running jobs#45813
ChristophWurst merged 1 commit into
stable29from
backport/45804/stable29

Conversation

@backportbot

Copy link
Copy Markdown

Backport of PR #45804

Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
@ChristophWurstChristophWurst added 4. to release Ready to be released and/or waiting for tests to finish and removed 3. to review Waiting for reviews labels Jun 12, 2024
Comment threadcron.php
$timeSpent = $timeAfter - $timeBefore;
if ($timeSpent > $cronInterval) {
$logLevel = match (true) {
$timeSpent > $cronInterval * 128 => \OCP\ILogger::FATAL,

Check notice

Code scanning / Psalm

DeprecatedClass

Class OCP\ILogger is deprecated
Comment threadcron.php
if ($timeSpent > $cronInterval) {
$logLevel = match (true) {
$timeSpent > $cronInterval * 128 => \OCP\ILogger::FATAL,
$timeSpent > $cronInterval * 64 => \OCP\ILogger::ERROR,

Check notice

Code scanning / Psalm

DeprecatedClass

Class OCP\ILogger is deprecated
Comment threadcron.php
$logLevel = match (true) {
$timeSpent > $cronInterval * 128 => \OCP\ILogger::FATAL,
$timeSpent > $cronInterval * 64 => \OCP\ILogger::ERROR,
$timeSpent > $cronInterval * 16 => \OCP\ILogger::WARN,

Check notice

Code scanning / Psalm

DeprecatedClass

Class OCP\ILogger is deprecated
Comment threadcron.php
$timeSpent > $cronInterval * 128 => \OCP\ILogger::FATAL,
$timeSpent > $cronInterval * 64 => \OCP\ILogger::ERROR,
$timeSpent > $cronInterval * 16 => \OCP\ILogger::WARN,
$timeSpent > $cronInterval * 8 => \OCP\ILogger::INFO,

Check notice

Code scanning / Psalm

DeprecatedClass

Class OCP\ILogger is deprecated
Comment threadcron.php
$timeSpent > $cronInterval * 64 => \OCP\ILogger::ERROR,
$timeSpent > $cronInterval * 16 => \OCP\ILogger::WARN,
$timeSpent > $cronInterval * 8 => \OCP\ILogger::INFO,
default => \OCP\ILogger::DEBUG,

Check notice

Code scanning / Psalm

DeprecatedClass

Class OCP\ILogger is deprecated
@ChristophWurst
ChristophWurst merged commit ba46d03 into stable29Jun 12, 2024
@ChristophWurst
ChristophWurst deleted the backport/45804/stable29 branch June 12, 2024 13:10
@blizzzblizzz mentioned this pull request Jun 12, 2024
3 tasks
Sign up for freeto join this conversation on GitHub. Already have an account? Sign in to comment

Labels

4. to releaseReady to be released and/or waiting for tests to finishbug

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants

@AndyScherzinger@ChristophWurst@github-advanced-security