Extra database queries

Discussions and support about the different URL Rewriting techniques for phpBB2.

Moderator: Moderators


Extra database queries

Postby emielvenlo » Mon May 21, 2007 8:44 am

One of my forums is becomeming extremely succesfull. With 20.000 to 30.000 visits a day on a 4 month old forum :)
But the downside is that i have a lot of database problems. The forum reports: could not connect to database. I was wondering how much extra database queries zerodupe+advanced mod rewrite would generate? Is it +- 5% extra or maybe 100% extra?

I am considering migrating to a more expensive host that can more easy cope with the load, but i was just wondering.
User avatar
emielvenlo
PR0
PR0
 
Posts: 82
Joined: Sun Jan 21, 2007 10:01 am

Advertisement

Postby HB » Mon May 21, 2007 10:52 am

Short answer: There's no overhead.

Long answer: OK OK, there are a couple edge cases that can add SQL calls (e.g., generating injected title URLs for search results), but otherwise there are no added SQL calls. As a simplified explanation of the approach, the code caches the required id mapping tables in a global variable in the places that they were already read (e.g., caching the forum id to forum title entries while processing the forums in viewforum.php). The append_sid function in sessions.php is already called to handle last minute session information; the phpBB SEO mods use the fact that it is always called for all URLs to handle URL rewriting, using the cached mapping tables created earlier.
Dan Kehn
HB
phpBB SEO Team
phpBB SEO Team
 
Posts: 1107
Joined: Mon Oct 16, 2006 2:25 am

Postby emielvenlo » Mon May 21, 2007 11:40 am

Oke, thank you!

Then i just have to find a new host :)
User avatar
emielvenlo
PR0
PR0
 
Posts: 82
Joined: Sun Jan 21, 2007 10:01 am

Postby dcz » Wed May 23, 2007 11:46 am

By the way nice shot, what a growth :shock:

The zero duplicates as well implies some queries under specific conditions.

For example, if you try http://www.phpbb-seo.com/boards/viewforum.php?f=33 the mod will need to know what is forum n°33 title to inject it in the url.

But, these redirection only massively occurs when you change all your url at a time, for example when installing the url rewriting after you forum previously went decently indexed with the regular urls. This phase does not last since bots will "understand" they should now only use the new urls.

So when there is no url migration going on, it's only a rare occurrence when the redirection gets activated. The last post link does imply some extra SQL when followed as well, but we'll soon release the no duplicate mod to fully get rid of posts URL ;)


What is for sure is you really can think about finding a better hosting, because your site growth will require it soon in all cases.

++
Useful links :
SEO Forum || SEO Directory || SEO phpBB || Search
____________________

Liens Utiles :
Forum référencement || Annuaire référencement || Référencement phpBB || Recherche
dcz
Admin
Admin
 
Posts: 19909
Joined: Fri Apr 28, 2006 9:03 pm


Return to phpBB2 mod Rewrite

Who is online

Users browsing this forum: No registered users and 2 guests


 
cron