开发者

Doctrine with large datasets

开发者 https://www.devze.com 2023-01-25 09:15 出处:网络
Does anyone have experience using Doctrine with large datasets? I have a开发者_StackOverflow社区n import script that uses Doctrine and it uses way too much memory. The speed isn\'t a huge problem but

Does anyone have experience using Doctrine with large datasets? I have a开发者_StackOverflow社区n import script that uses Doctrine and it uses way too much memory. The speed isn't a huge problem but the memory usage is. Does anyone have any tips for keeping Doctrine's memory usage down?


In Doctrine 1.2 at least, freeing objects after use frees up memory, which is recommended for long-running scripts:

$my_object->free();

There's a few tips on improving performance at the end of the official guide:

http://www.doctrine-project.org/projects/orm/1.2/docs/manual/improving-performance/en

0

精彩评论

暂无评论...
验证码 换一张
取 消