 |
opencaching.com Geocaching by the community, for the community
|
| View previous topic :: View next topic |
| Author |
Message |
amnesius

Joined: 27 Sep 2003 Posts: 147 Location: ./earth/europe/*
|
Posted: Tue Sep 30, 2003 4:25 pm Post subject: Some general Ideas.. |
|
|
Hi folks,
some ideas came to my mind when i was thinking about the tech. issues of geocaching(dot)com
i think it would be a good idea if most of the pages are static html rendered from templates and database content. This will improve the performance alot. A page can be called by a loader script which performs a short DB query to find out if the static page content hasnt changes lately. If the content has been altered the page will be rendered again, if not the static page will be delivered to the client.
To save bandwith and diskspace you can store the static pages GZIP'd. Allmost all current browsers are capable to handle GZIP'd html. If the browser isn't capable to handle GZIP'd html you can check this with the loader script and unzip the file before sending it to the client.
Depending on the HTML page you have a compression up to 1:7. This is not only saving alot of bandwith it makes modem and mobile phone surfers happy too..
To increase the performance of the PHP execution you can use the free PHP Bytecode Compiler TURCK MM CACHE. ( Seek it at freshmeat.net ). It converts PHP Scripts to Bytecode and stores it on the disk ( or for more performance you can use a RAMDRIVE ). This allows PHP to skip the Parse and compilation of the scripts at any of their executions. This can provide you up to 100% more performance for which you have to pay with some diskspace or some system memory. But its worth trying.
Whats your opinion about it?
Ps: I used all the things mentioned above at several webpages..
Cheers
-Stefan _________________ ~Amnesius |
|
| Back to top |
|
 |
hmarq Site Admin

Joined: 15 Sep 2003 Posts: 351
|
Posted: Tue Sep 30, 2003 7:55 pm Post subject: Re: Some general Ideas.. |
|
|
| amnesius wrote: | Hi folks,
some ideas came to my mind when i was thinking about the tech. issues of geocaching(dot)com
i think it would be a good idea if most of the pages are static html rendered from templates and database content. This will improve the performance alot. A page can be called by a loader script which performs a short DB query to find out if the static page content hasnt changes lately. If the content has been altered the page will be rendered again, if not the static page will be delivered to the client.
To save bandwith and diskspace you can store the static pages GZIP'd. Allmost all current browsers are capable to handle GZIP'd html. If the browser isn't capable to handle GZIP'd html you can check this with the loader script and unzip the file before sending it to the client.
Depending on the HTML page you have a compression up to 1:7. This is not only saving alot of bandwith it makes modem and mobile phone surfers happy too..
To increase the performance of the PHP execution you can use the free PHP Bytecode Compiler TURCK MM CACHE. ( Seek it at freshmeat.net ). It converts PHP Scripts to Bytecode and stores it on the disk ( or for more performance you can use a RAMDRIVE ). This allows PHP to skip the Parse and compilation of the scripts at any of their executions. This can provide you up to 100% more performance for which you have to pay with some diskspace or some system memory. But its worth trying.
Whats your opinion about it?
Ps: I used all the things mentioned above at several webpages..
Cheers
-Stefan |
Yes to everything except the compiler ... That's pretty much how you have to run a site like this ... the only difference being that you don't really have to test when the page loads, you just set conditions on which the page is rebuilt ... one of which might be time, but mostly triggered by events ... the owner changing the page, a user logging the cache would be the two 'recreate' events that would build the static html ...
PHP makes doing the gzip thing trivial using output buffering ... and since it'll only be a handful of scripts that draw from the templates it's pretty easy to both do and control.
I've never seen any huge savings with the various bytecode things ... i was a contractor for Zend when they first rolled all that stuff out, so I had copies and played ... I could see applications where you had lots of code that gets executed, but honestly this type of site is pretty straight forward and more database bound than anything ... which is why the static rendition is so helpful.
All fine ideas ... and even out of the gate we're probably mostly there. |
|
| Back to top |
|
 |
amnesius

Joined: 27 Sep 2003 Posts: 147 Location: ./earth/europe/*
|
Posted: Wed Oct 01, 2003 2:07 am Post subject: |
|
|
| Quote: | | one of which might be time, but mostly triggered by events ... the owner changing the page, a user logging the cache would be the two 'recreate' events that would build the static html |
Yes i thought so too at first. But my idea goes this way to prevent shortages while peakhours. Times when lots of ppl log their finds or post their caches. But maybe your idea is the better one..
Cheers
-Stefan _________________ ~Amnesius |
|
| Back to top |
|
 |
|
Powered by phpBB 2.0.6 © 2001, 2002 phpBB Group
|