Bug #40580

Exception when using SQL logger in Production Context

Added by Adrian Föder about 9 years ago. Updated about 9 years ago.

Status:
Resolved
Priority:
Should have
Assignee:
Category:
Log
Target version:
-
Start date:
2012-09-04
Due date:
% Done:

100%

Estimated time:
PHP Version:
Has patch:
No
Complexity:

Description

when having the SQL logger active in Prodution context, an exception occur, saying that

Uncaught Exception

Catchable Fatal Error: Argument 4 passed to
TYPO3\FLOW3\Log\LoggerFactory::create() must be of the type array, null
given, called in...

which makes sense, since the mentioned argument 4 is a setting (http://git.typo3.org/FLOW3/Packages/TYPO3.FLOW3.git?a=blob;f=Configuration/Objects.yaml;h=d6ed6e3040311d08a48062a7bc547147695ec102;hb=master#l188):

'TYPO3\FLOW3\Persistence\Doctrine\Logging\SqlLogger':
  properties:
    logger:
      object:
        factoryObjectName: TYPO3\FLOW3\Log\LoggerFactory
        arguments:
          1:
            value: 'Sql_Queries'
          2:
            value: 'TYPO3\FLOW3\Log\Logger'
          3:
            value: 'TYPO3\FLOW3\Log\Backend\FileBackend'
          4:
            setting: TYPO3.FLOW3.log.sqlLogger.backendOptions

but the mentioned section is only available in Developmnent/Settings.yaml (http://git.typo3.org/FLOW3/Packages/TYPO3.FLOW3.git?a=blob;f=Configuration/Development/Settings.yaml;h=332c4daabc94c75523012d0b8e0ac88289a130d4;hb=master#l43):

TYPO3:
  FLOW3:
# [...]
      sqlLogger:
        backendOptions:
          logFileURL: %FLOW3_PATH_DATA%Logs/Query_Development.log
          createParentDirectories: TRUE
          severityThreshold: %LOG_DEBUG%

#1

Updated by Gerrit Code Review about 9 years ago

  • Status changed from New to Under Review

Patch set 1 for branch master has been pushed to the review server.
It is available at http://review.typo3.org/14328

#2

Updated by Gerrit Code Review about 9 years ago

Patch set 2 for branch master has been pushed to the review server.
It is available at http://review.typo3.org/14328

#3

Updated by Gerrit Code Review about 9 years ago

Patch set 1 for branch FLOW3-1.1 has been pushed to the review server.
It is available at http://review.typo3.org/14494

#4

Updated by Adrian Föder about 9 years ago

  • Status changed from Under Review to Resolved
  • % Done changed from 0 to 100

Also available in: Atom PDF