[pLog-svn] Add the cache control to menu

Mark Wu markplace at gmail.com
Tue Feb 26 00:05:15 EST 2008


mmm ... it is not quite easy to read the "Parsed Array" from XML_parser, we
need an container like "array_tree" to solve this kind of data structure.
 
So, I decide to reduce the caculation first. After I finish all 2.0 stuff,
then I can have time to deal with this.
 
You can take a look at this menu array parsed from XML, it is quite "big". I
think it not only consumed our time also consumed our memory.
 
Mark


  _____  

From: plog-svn-bounces at devel.lifetype.net
[mailto:plog-svn-bounces at devel.lifetype.net] On Behalf Of Oscar Renalias
Sent: Tuesday, February 26, 2008 4:35 AM
To: LifeType Developer List
Subject: Re: [pLog-svn] Add the cache control to menu


That's still not bad, but what were the problems that you faced when turning
the structure from an XML_Tree object into a plain array? 

On Feb 25, 2008, at 6:16 AM, Mark Wu wrote:


Hi Oscar:
 
In my test, it reduce the total request time from 534 ms to 440 ms. It saved
almost 100ms in my installation.
 
So, I think it worth to try ... :)
 
Mark


  _____  

From: plog-svn-bounces at devel.lifetype.net
[mailto:plog-svn-bounces at devel.lifetype.net] On Behalf Of Oscar Renalias
Sent: Thursday, February 21, 2008 4:58 AM
To: LifeType Developer List
Subject: Re: [pLog-svn] Add the cache control to menu


How about some benchmarks? Would you have some time to look into generating
some benchmarks? Numbers don't lie :) 

On Feb 19, 2008, at 6:59 AM, Mark Wu wrote:


Hi All:
 
After review the code, it is not easy to replace the current XML menu with
array tree. 
 
So, I try to add the cache to XML menu first.
 
1. The menu cache will cache our core xml menus plus plugins' menus. After
lifetype cache it, the menu will load from cache directly until the cache
expired or deleted.
 
2. If the method works, I will add remove cache in plugins centers.
Therefore, the cache will removed when we add/remove/refresh the plugins
center.
 
If any one of you have time, please kindly test this cached version script,
and let me know if it help performance or not.
 
Regards, Mark
<menu.class.php>_______________________________________________
pLog-svn mailing list
pLog-svn at devel.lifetype.net
http://limedaley.com/mailman/listinfo/plog-svn


_______________________________________________
pLog-svn mailing list
pLog-svn at devel.lifetype.net
http://limedaley.com/mailman/listinfo/plog-svn


-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://limedaley.com/pipermail/plog-svn/attachments/20080226/01611382/attachment-0001.htm 
-------------- next part --------------
An embedded and charset-unspecified text was scrubbed...
Name: menu.txt
Url: http://limedaley.com/pipermail/plog-svn/attachments/20080226/01611382/attachment-0001.txt 


More information about the pLog-svn mailing list