Skip to content

sinso/typo3-log-rotation

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

4 Commits
 
 
 
 
 
 

Repository files navigation

Backports RotatingFileWriter for TYPO3 v12

TYPO3 v13 comes with a RotatingFileWriter which is a great way to handle log rotation. This extension backports the RotatingFileWriter for your TYPO3 v12 installation.

The extension is technically compatible with TYPO3 v12 and v13, but will trigger a deprecation warning in TYPO3 v13 if the RotatingFileWriter of this extension is used.

Usage

Use just as it is described in the official documentation of the feature.

Just replace the following classes:

Original class name Class provided by this extension
\TYPO3\CMS\Core\Log\Writer\RotatingFileWriter \Sinso\LogRotation\Log\Writer\RotatingFileWriter
\TYPO3\CMS\Core\Log\Writer\Enum\Interval \Sinso\LogRotation\Log\Writer\Enum\Interval

Example

$GLOBALS['TYPO3_CONF_VARS']['LOG']['TYPO3']['CMS']['Core']['Resource']['ResourceStorage']['writerConfiguration'][\Psr\Log\LogLevel::ERROR] = [
    \Sinso\LogRotation\Log\Writer\RotatingFileWriter::class => [
        'interval' => \Sinso\LogRotation\Log\Writer\Enum\Interval::DAILY,
        'maxFiles' => 5,
    ],
];

Migration to TYPO3 v13

When you migrate your installation to TYPO3 v13 change your logging configuration to use the core classes. Afterwards you can remove this extension.

About

Backporting RotatingFileWriter to TYPO3 v12

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages