Bug #63750

Bug #63692: Memory consumption while bulk inserting

Avoid calling getUserObj in DataHandler->checkValue_input_Eval

Added by Stephan Großberndt 8 months ago. Updated 6 months ago.

Status:Resolved Start date:2014-12-10
Priority:Should have Due date:
Assigned To:- % Done:

100%

Category:Performance Spent time: -
Target version:next-patchlevel
TYPO3 Version:6.2 Is Regression:No
PHP Version: Sprint Focus:
Complexity:easy

Description

If the eval field is empty in a TCA input definition there is no NULL or empty check:

default:
    $evalObj = GeneralUtility::getUserObj($GLOBALS['TYPO3_CONF_VARS']['SC_OPTIONS']['tce']['formevals'][$func] . ':&' . $func);
    if (is_object($evalObj) && method_exists($evalObj, 'evaluateFieldValue')) {
        $value = $evalObj->evaluateFieldValue($value, $is_in, $set);
    }

If $func is empty, this leads to a call to unnecessary call to GeneralUtility::getUserObj(':&');

Associated revisions

Revision 61878ada
Added by Stephan Großberndt 6 months ago

[BUGFIX] Avoid getUserObj-call for eval 'null' and non-existing hooks

If the 'eval' definition of a TCA input or text does contain 'null' or
a value without a matching hook, we skip the useless call to
GeneralUtility::getUserObj().

This improves performance especially for bulk inserts with many text
fields.

Resolves: #63750
Releases: master, 6.2
Change-Id: I328f6b3f5e737fa472f7385afc0a2407d16eb1f8
Reviewed-on: http://review.typo3.org/35287
Reviewed-by: Oliver Klee <>
Reviewed-by: Georg Ringer <>
Tested-by: Georg Ringer <>
Reviewed-by: Andreas Fernandez <>
Tested-by: Andreas Fernandez <>
Reviewed-by: Markus Klein <>
Tested-by: Markus Klein <>

Revision c9bc5ef4
Added by Stephan Großberndt 6 months ago

[BUGFIX] Avoid getUserObj-call for eval 'null' and non-existing hooks

If the 'eval' definition of a TCA input or text does contain 'null' or
a value without a matching hook, we skip the useless call to
GeneralUtility::getUserObj().

This improves performance especially for bulk inserts with many text
fields.

Resolves: #63750
Releases: master, 6.2
Change-Id: I328f6b3f5e737fa472f7385afc0a2407d16eb1f8
Reviewed-on: http://review.typo3.org/36188
Reviewed-by: Markus Klein <>
Tested-by: Markus Klein <>

History

#1 Updated by Mathias Schreiber 8 months ago

  • Parent task set to #63692

#2 Updated by Gerrit Code Review 8 months ago

  • Status changed from New to Under Review

Patch set 1 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at http://review.typo3.org/35287

#3 Updated by Gerrit Code Review 8 months ago

Patch set 2 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at http://review.typo3.org/35287

#4 Updated by Gerrit Code Review 7 months ago

Patch set 3 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at http://review.typo3.org/35287

#5 Updated by Gerrit Code Review 7 months ago

Patch set 4 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at http://review.typo3.org/35287

#6 Updated by Gerrit Code Review 7 months ago

Patch set 5 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at http://review.typo3.org/35287

#7 Updated by Gerrit Code Review 6 months ago

Patch set 6 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at http://review.typo3.org/35287

#8 Updated by Gerrit Code Review 6 months ago

Patch set 7 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at http://review.typo3.org/35287

#9 Updated by Gerrit Code Review 6 months ago

Patch set 8 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at http://review.typo3.org/35287

#10 Updated by Gerrit Code Review 6 months ago

Patch set 9 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at http://review.typo3.org/35287

#11 Updated by Gerrit Code Review 6 months ago

Patch set 1 for branch TYPO3_6-2 of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at http://review.typo3.org/36188

#12 Updated by Stephan Großberndt 6 months ago

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

Also available in: Atom PDF