Project

General

Profile

Actions

Feature #72583

closed

get unified log levels

Added by Bernd Wilke almost 9 years ago. Updated about 7 years ago.

Status:
Rejected
Priority:
Should have
Assignee:
Category:
Logging
Target version:
-
Start date:
2016-01-08
Due date:
% Done:

0%

Estimated time:
PHP Version:
Tags:
Complexity:
Sprint Focus:

Description

there are two functions for logging: TYPO3\CMS\Core\Utility\GeneralUtility::devLog() and TYPO3\CMS\Core\Utility\GeneralUtility::sysLog()
both have a parameter $severity.

for sysLog() there are constants:

    // Severity constants used by \TYPO3\CMS\Core\Utility\GeneralUtility::sysLog()
    const SYSLOG_SEVERITY_INFO = 0;
    const SYSLOG_SEVERITY_NOTICE = 1;
    const SYSLOG_SEVERITY_WARNING = 2;
    const SYSLOG_SEVERITY_ERROR = 3;
    const SYSLOG_SEVERITY_FATAL = 4;

devLog() (should) accept the values -1 to 3 as stated in the doc-header:

* @param integer $severity Severity: 0 is info, 1 is notice, 2 is warning, 3 is fatal error, -1 is "OK" message

it would be nice to have unique values and one set of constants like:

    // Severity constants used by \TYPO3\CMS\Core\Utility\GeneralUtility::sysLog() 
        //    and \TYPO3\CMS\Core\Utility\GeneralUtility::devLog()
    const LOG_SEVERITY_OK = -1;
    const LOG_SEVERITY_INFO = 0;
    const LOG_SEVERITY_NOTICE = 1;
    const LOG_SEVERITY_WARNING = 2;
    const LOG_SEVERITY_ERROR = 3;
    const LOG_SEVERITY_FATAL = 4;


Related issues 1 (0 open1 closed)

Related to TYPO3 Core - Task #82430: Replace GeneralUtility::syslog with Logging APIClosedMarkus Klein2017-09-10

Actions
Actions #1

Updated by Markus Klein almost 9 years ago

This should all be replaced by the Logging API!

Actions #2

Updated by Markus Klein about 7 years ago

  • Assignee set to Markus Klein
Actions #3

Updated by Markus Klein about 7 years ago

  • Status changed from New to Rejected
Actions #4

Updated by Markus Klein about 7 years ago

  • Related to Task #82430: Replace GeneralUtility::syslog with Logging API added
Actions

Also available in: Atom PDF