Hello
I’ve spent a part of the night thinking about all that.. I think I may have found a possible explanation.
First … You have to know that we are at the limit of our hosting (but we can’t afford a bigger one now). So I think we do overwhelmed our SQL engine. This is not a problem with SMf which is very robust … but listen that scenario:
When a visitor ask for a document (either index?id= or index), MODx trys to retrive that document with either the `id` or the `alias` index.
When retreived, you look at permission then you treat it (you look if it is alerady cached or you parse it)….
Now … imagine my SQL that is jammed. You ask for the document but you receive no answer (since SQL as gone away or is not responding). How do you treat it ? I think you may try to handle it as if it was either a 404 or a 401 ? (seems to be a 404 when I look at my logs)
Handling a 404 (or a 401) you try to
1/ look in database which docid is suitable for MODx’ answer
2/ retreive that doc form DB
3/ parse the doc …
but what if the SQL is still jammed ? You even can’t retreive the "not found" handler and your enter your infinite loop
So .. the conclusion now seems :
* my hosting is the primary cause
* MODx can’t handle thing when something goning wrong (sorry, I’ve made too much industriall application where it is normal that robustness is evident)
what can be done ?
- first, I hop the next OO database motor will be more robust … I’ve allready given some clue
- then You have to review how you handel db-query answer … not saying "yes" isn’t saying "no"… when you receive no document for one request … this is not (allways) bescause your facing a 404 but you may are facing a SQL error !
- When you’re facing a SQL error,
- you should avoid every error log that only jam the DB engine more.
- You could send (I the webmaster decided to) an email for telling the situation
- You should retreive from files (not from DB) the correct text to display (Sorry unable to complete the request there was a problem with DB engine) that could be translated
- You event could display a static HTML file
All that possibilities should be placed into a configuration file (not DB)