Task #53607

Only persist recursive node changes once

Added by Bastian Waidelich over 1 year ago. Updated over 1 year ago.

Status:Resolved Start date:2013-11-13
Priority:Should have Due date:
Assigned To:Christian Müller % Done:

100%

Category:Node handling
Target version:-
Sprint:

Description

https://review.typo3.org/#/c/25300/ fixed moving of nodes, but it leads to the situation that NodeDataRepository::persistEntities() is called recursively for every child node of moved/renamed nodes.
This has a negative effect on performance and it could break the complete sub tree if errors happen during persistence.

One way to solve this would be to remove the persistEntities() call from Node::setPath() and call it after invoking that method from the move*() and setName methods.

Associated revisions

Revision 40d2c05c
Added by Christian Müller over 1 year ago

[!!!][TASK] Prevent multiple persistence commits on setPath

Currently nodes are persisted after every call of setPath, even
recursively which is unneeded. With this change persist happens
only at the end of a recursive setPath call chain.

This is only breaking if you use Node::setPath() in your own
code as persisting the changes is no longer happening
automatically.

Change-Id: Ie21be14ffaeb161232fcb631dc467c2040e2040a
Resolves: #53607
Reviewed-on: https://review.typo3.org/25749
Reviewed-by: Bastian Waidelich
Reviewed-by: Aske Ertmann
Reviewed-by: Christian Mueller
Tested-by: Christian Mueller
Reviewed-by: Dominique Feyer
Tested-by: Dominique Feyer
Reviewed-by: Karsten Dambekalns
Tested-by: Karsten Dambekalns

History

#1 Updated by Gerrit Code Review over 1 year ago

  • Status changed from New to Under Review

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

#2 Updated by Gerrit Code Review over 1 year ago

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

#3 Updated by Christian Müller over 1 year ago

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

Also available in: Atom PDF