Hi, No one has any idea on this topic? Or the question wasn't clear? Thanks, Arpi
> Hi again, > I read my email back and found a little hard to understand :)), so > I thought a code exmplae might help. > It's just pseudo code for explaining how my cache works: > > //simplified "main" code > if page is in cache { > deliver the old one > register_shutdown_function("regenerate") > } else { > regenerate() > deliver > } > > //registered shutdown function > function regenerate() { > if it's locked by another process { > return > } else { > lock > require_once(...); > require_once(...); > require_once(...); > require_once(...); > require_once(...); > creation of many classes > calling of many methods (the code is approx 1,6Megs) > store > unlock > } > } > The main code delivers the page and reigsters the regenerate() > function, and that's all what it should do. It takes about 0.04s, > but this time unfortunately depends on what the regenerate() > function does. If the page is locked then it finishes quickly (the > overall time is 0.04s again), but when it can be regenerated it > takes 0.25s. By the way the whole page regeneration takes 1.1s, > that's why I really don't understand the 0.25s. > I hope it was clearer with the two mails :)), and someone has an > idea of whats happening here. > > Thanks for your help, > Arpi -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php