A few mistakes were revealed when testing using a real application; 1) I'd forgotten to hook up the classFor: method to the proxy creation methods, so it was never actually used... 2) Since copyFrom: is just a pseudo-forwardBecome:, we need to explicitly replace existing references to the value returned by selectOne: ... I hope the repository cache is the only place it is stored during selectOne:, if there are more, additional fixup post copyFrom: in becomeForwardWithSameShape: is needed.
The attached version should fix the above two issues.
Cheers, Henry |
Voyage-Mongo-Core-HenrikSperreJohansen.56.mcz
Description: Binary data
cool, thanks! copied and merged :P
Esteban
Hi Esteban! As we talked about on IRC yesterday, I had hoped to employ the fast become discussed in to bring faster proxy loading untill Spur arrives. Sadly, it's not present in any current VM's, for reasons unknown*.
As I don't have write-access to Voyage repo, I've attached the package with the changes (which work in both 3.0 and 4.0, but I assume not older, due to using the SlotBuilder for anon subclasses)
The package comment contains a workspace doit for comparision, but long story short, for objects covered by the new fast path, you can now materialize more than million objects in the time it previously took to materialize five.
|