[DOCS] Clarify changed logger instantiation in scheduler tasks 01/63601/2
authorSusanne Moog <look@susi.dev>
Sat, 7 Mar 2020 11:03:15 +0000 (12:03 +0100)
committerBenni Mack <benni@typo3.org>
Sat, 7 Mar 2020 11:32:53 +0000 (12:32 +0100)
Resolves: #90415
Releases: master, 9.5
Change-Id: Icb403e6ef2892ff7988a34652d6cdfa8f8bd1cfd
Reviewed-on: https://review.typo3.org/c/Packages/TYPO3.CMS/+/63601
Tested-by: TYPO3com <noreply@typo3.com>
Tested-by: Georg Ringer <georg.ringer@gmail.com>
Tested-by: Oliver Bartsch <bo@cedev.de>
Tested-by: Benni Mack <benni@typo3.org>
Reviewed-by: Georg Ringer <georg.ringer@gmail.com>
Reviewed-by: Oliver Bartsch <bo@cedev.de>
Reviewed-by: Benni Mack <benni@typo3.org>
typo3/sysext/core/Documentation/Changelog/9.5.x/Important-86785-CallingSchedulerTaskThrowsLoggerError.rst [deleted file]
typo3/sysext/core/Documentation/Changelog/9.5.x/Important-86785-ExcludeLoggerFromSerialisationForSchedulerTasks.rst [new file with mode: 0644]

diff --git a/typo3/sysext/core/Documentation/Changelog/9.5.x/Important-86785-CallingSchedulerTaskThrowsLoggerError.rst b/typo3/sysext/core/Documentation/Changelog/9.5.x/Important-86785-CallingSchedulerTaskThrowsLoggerError.rst
deleted file mode 100644 (file)
index 2910e3a..0000000
+++ /dev/null
@@ -1,24 +0,0 @@
-.. include:: ../../Includes.txt
-Important: #86785 - Calling scheduler command on CLI throws error if not in /var/www/html
-See :issue:`86785`
-Calling the scheduler command on CLI or in backend throws an error, if the TYPO3 CMS installation is not running in @/var/www/html/@.
-After saving the scheduler task, the logger instance is serialized to the database with absolute paths (FileWriter::class).
-Exclusion of the logger instance from the record during save to database prevents that error.
-The stored and serialized tasks from upgraded TYPO3 instances and new saved tasks still work as before.
-The logger instance is initialized while running the scheduler task and is not saved to the serialized task
-object anymore. The logger (FileWriter::class) can open and write the log file to the current environment paths.
-.. index:: Backend, ext:scheduler
diff --git a/typo3/sysext/core/Documentation/Changelog/9.5.x/Important-86785-ExcludeLoggerFromSerialisationForSchedulerTasks.rst b/typo3/sysext/core/Documentation/Changelog/9.5.x/Important-86785-ExcludeLoggerFromSerialisationForSchedulerTasks.rst
new file mode 100644 (file)
index 0000000..5fd59be
--- /dev/null
@@ -0,0 +1,34 @@
+.. include:: ../../Includes.txt
+Important: #86785 - Exclude logger from serialisation on save for scheduler task
+See :issue:`86785`
+Calling the scheduler command on CLI or in backend throws an error, when you
+created a scheduler task in one environment (for example one where TYPO3 was
+running in `/var/www/html`) - and then you take that database and move to another
+environment (where TYPO3 is running somewhere else, for example in
+`/var/www/something`). Trying to execute any task in the scheduler resulted
+in an error, because the Logger instance that was stored with the task in the
+database had the wrong log file path.
+To get rid of that problem, the logger is no longer stored with the task in the
+database, but instead re-instantiated when the task is run
+(which means it checks for correct paths on the current environment).
+Exclusion of the logger instance from the record during save to database
+prevents the error.
+The stored and serialized tasks from upgraded TYPO3 instances and new saved tasks still work as before.
+The logger instance is initialized while running the scheduler task and is not saved to the serialized task
+object anymore. The logger (FileWriter::class) can open and write the log file to the current environment paths.
+.. index:: Backend, ext:scheduler