[PHPCR-65] find with uuid creates duplicate of document Created: 23/Apr/12  Updated: 20/Jul/12  Resolved: 20/Jul/12

Status: Closed
Project: Doctrine PHPCR
Component/s: None
Affects Version/s: None
Fix Version/s: None

Type: Bug Priority: Major
Reporter: David Buchmann Assignee: Lukas Kahwe
Resolution: Fixed Votes: 0
Labels: None


i am pretty sure the DocumentManager::find() method creates a duplicate document each time you request the document by uuid. it should not just load the node but convert that node to a path and then do the check if the document is cached. if the node is already cached the lookup by uuid is cheap. if not, it is now cached and the lookup by path is cheap. so no overhead, but eliminate the risk of having several instances of the same document.


Comment by Lukas Kahwe [ 19/Jul/12 ]

this issue seems to be fixed https://github.com/doctrine/phpcr-odm/blob/master/lib/Doctrine/ODM/PHPCR/DocumentManager.php#L289

Comment by David Buchmann [ 20/Jul/12 ]

thanks, looks good to me now.

Generated at Thu Oct 08 16:09:16 EDT 2015 using JIRA 6.4.10#64025-sha1:5b8b74079161cd76a20ab66dda52747ee6701bd6.