Don't have an account yet? You can create one, it is free, just click here
as a registered user you have some advantages like free downloads, comments and posting on our forums, depending upon this site's configuration and options.
I run quite big photoportal based on MD-pro autotheme, pnphpbb2 and smartors album pack.
In album pnphpbb2 module I've changed code not to display images via thumbnails scripts which were checking database than checking whether file exists and than if not resampling thumbnail with code which was first checking whether file exists and than if does not starting thumbnail script. On category page this procedure was performed for each thumbnail - 20 times. With growing number of pictures portal was slower and slower.
Recently I came to the conclusion that this looop if (file_exists ... is unnecesary because it is enough to do it once after uploading photo and resampling thumbnail.
But effect was unbelivable - portal is 2-3 times faster. I think that for each generation of page 20 files was checked and than 20 files loaded - double unnecesary work. Disk making it phisically.
Now I found that during generation of ANY page md-pro and autotheme is performing file_exists check for 30-40 times.
Just change " if (file_exist" and " if (@file_exist" with "echo "x";if (file_exist" in your portal scripts and you will see 30-40 x-es on generated page. And this skips or elseif (file_exist functions (about the same numebr but not all are executed.
I think that it might be very usefull to get rid of those functions in places in which they are unnecesary. That would give extra power to md-pro portal which id very voulnerabe for heavy traffic.
How do you think?
TiMax Project Manager
Joined: July 31, 2003
Posts: 1560
Location: Quebec - Canada
 Posted:
Jan 07, 2007 - 07:58 AM
We always try to remove unnecesary code, but maybe if it is there is because it need to be there
You can work in this way to optimize YOUR installation, not to use like default release
_________________ TiMaxMAX s.o.s.Fantasia e dinamicità Italiane, qualità e servizi Canadesi Web Services, hosting ed housing professionali
Logan New MD user
Joined: Oct 24, 2003
Posts: 7
bannato
 Posted:
Jan 07, 2007 - 10:11 AM
Thank you for that fast answer.
Yes your right. I think I will try do do something with this I hope it will give good results.
Those observations also mean that limits in scalability are caused rather by limitation of file system then by processor strenght, what is not a good news for me because I wanted to switch for stronger server - but I don't thing there will be any improvement on file system performance.
Greetings !!!
_________________ Otwarta internetowa galeria foto
TiMax Project Manager
Joined: July 31, 2003
Posts: 1560
Location: Quebec - Canada
 Posted:
Jan 08, 2007 - 04:11 AM
Try also to use MDLite, it is more fast and need less memory
_________________ TiMaxMAX s.o.s.Fantasia e dinamicità Italiane, qualità e servizi Canadesi Web Services, hosting ed housing professionali