big fetch and time/memory problems

Author Message

Jorge estévez

Thursday 16 July 2009 10:26:04 am

I need to do a fetch of nodes, about 5000 scatered over a big tree structure of the site just to display th node´s names. I takes very long just to "fetch" them all, and my PC memory gets exhausted.

How can I fetch them not affecting the memory of my PC and speeding up the fetch

Any code that iterates and can help me clean memory...

Any solutions/tips please!

thanks

Diseño Web Cuba
Web Design Cuba
www.elfosdesign.com

André R.

Thursday 16 July 2009 1:35:51 pm

The best would probaly be to use custom fetch function / template operator (with custom sql).

eZ Online Editor 5: http://projects.ez.no/ezoe || eZJSCore (Ajax): http://projects.ez.no/ezjscore || eZ Publish EE http://ez.no/eZPublish/eZ-Publish-Enterprise-Subscription
@: http://twitter.com/andrerom

Jorge estévez

Friday 17 July 2009 8:46:04 am

Thanks,

The operation I am trying to make consumes time, but this operation will not me made often, so time is not a matter at all.

Memory is still my main issue (I am developing under windows and the OS tells me that I am consuming memory resources)

Can I somehow fetch blocks of nodes and in between clean memory and start over again using offset (within the fetch function)?

Any pseudocode I coul use please...

I am trying to avoid a custom fetch.

thanks, jorge

Diseño Web Cuba
Web Design Cuba
www.elfosdesign.com

Jean-Luc Nguyen

Wednesday 22 July 2009 2:35:00 am

Hello,

What about using ezfind to do your fetch?
http://ez.no/developer/forum/extensions/ez_find/use_ezfind_as_regular_fetch

http://www.acidre.com

Powered by eZ Publish™ CMS Open Source Web Content Management. Copyright © 1999-2014 eZ Systems AS (except where otherwise noted). All rights reserved.

eZ debug

Timing: Jan 18 2025 15:09:53
Script start
Timing: Jan 18 2025 15:09:53
Module start 'layout'
Timing: Jan 18 2025 15:09:53
Module start 'content'
Timing: Jan 18 2025 15:09:54
Module end 'content'
Timing: Jan 18 2025 15:09:54
Script end

Main resources:

Total runtime0.5779 sec
Peak memory usage4,096.0000 KB
Database Queries62

Timing points:

CheckpointStart (sec)Duration (sec)Memory at start (KB)Memory used (KB)
Script start 0.00000.0053 589.0313152.6250
Module start 'layout' 0.00530.0018 741.656339.4453
Module start 'content' 0.00710.5694 781.1016588.1797
Module end 'content' 0.57650.0014 1,369.281312.1563
Script end 0.5779  1,381.4375 

Time accumulators:

 Accumulator Duration (sec) Duration (%) Count Average (sec)
Ini load
Load cache0.00310.5403160.0002
Check MTime0.00140.2420160.0001
Mysql Total
Database connection0.00070.128410.0007
Mysqli_queries0.526691.1149620.0085
Looping result0.00060.1003600.0000
Template Total0.554195.920.2770
Template load0.00210.359220.0010
Template processing0.552095.509920.2760
Template load and register function0.00010.021310.0001
states
state_id_array0.00070.118210.0007
state_identifier_array0.00120.210320.0006
Override
Cache load0.00170.2980240.0001
Sytem overhead
Fetch class attribute can translate value0.00060.097030.0002
Fetch class attribute name0.00120.206760.0002
XML
Image XML parsing0.00140.248030.0005
class_abstraction
Instantiating content class attribute0.00000.002860.0000
General
dbfile0.00100.1735230.0000
String conversion0.00000.001440.0000
Note: percentages do not add up to 100% because some accumulators overlap

Templates used to render the page:

UsageRequested templateTemplateTemplate loadedEditOverride
1node/view/full.tplfull/forum_topic.tplextension/sevenx/design/simple/override/templates/full/forum_topic.tplEdit templateOverride template
4content/datatype/view/ezxmltext.tpl<No override>extension/community_design/design/suncana/templates/content/datatype/view/ezxmltext.tplEdit templateOverride template
5content/datatype/view/ezxmltags/paragraph.tpl<No override>extension/ezwebin/design/ezwebin/templates/content/datatype/view/ezxmltags/paragraph.tplEdit templateOverride template
2content/datatype/view/ezimage.tpl<No override>extension/sevenx/design/simple/templates/content/datatype/view/ezimage.tplEdit templateOverride template
1content/datatype/view/ezxmltags/line.tpl<No override>design/standard/templates/content/datatype/view/ezxmltags/line.tplEdit templateOverride template
1print_pagelayout.tpl<No override>extension/community/design/community/templates/print_pagelayout.tplEdit templateOverride template
 Number of times templates used: 14
 Number of unique templates used: 6

Time used to render debug report: 0.0001 secs