Update on Site Problems

PipesMagazine Approved Sponsor

.

.
Status
Not open for further replies.

admin

Smoking a Pipe Right Now
Staff member
Nov 16, 2008
7,982
349
St. Petersburg, FL
I have removed the new programming we did last week in the forums for email notifications for private messages and favorites notifications.
I suspect that is was causing a massive amount of database calls that maxed out the resources on the server.
I don't think it's the programmers fault. I read somewhere that BBPress, the script we use, is inefficiently programmed from the core, and looks up every single database record for the email function, causing an overload.
I read this in a developers forum, and a guy explained how he custom re-wrote it and fixed it.
Now if I can only find that post again.
I am speculating a bit, but the problems happened after the new programming. If the site continues to run fine now, then I was right.

 

admin

Smoking a Pipe Right Now
Staff member
Nov 16, 2008
7,982
349
St. Petersburg, FL
I found it.
We re-architected part of this plugin. After a new post this plugin was loading every single user record, then iterating through them to check the metadata for each user and see if the user had flagged the topic as a favorite. Tens of thousands of database queries.
Instead of using the stored list of favorite topic_ids in the user meta-dataspace, we solved the problem by adding functions that manage the storing of user_ids in the topic meta-space. So the number of database queries is 1.
Pretty retarded. I guess the guys that wrote the original programming never had a very busy, high-traffic site.
Having 10,000 database queries, when you should have only 1 is certainly going to be an issue.

 

mluyckx

Preferred Member
Dec 5, 2011
1,958
0
Texas
Thanks for staying on top of it Kevin.
I see too much bad database design... Even in software that costs 1,000's of $. Keeps me busy at least.

 

admin

Smoking a Pipe Right Now
Staff member
Nov 16, 2008
7,982
349
St. Petersburg, FL
I called the owner of the hosting company and said; "Sorry for being a dick yesterday." I really reamed him out big time.

 

admin

Smoking a Pipe Right Now
Staff member
Nov 16, 2008
7,982
349
St. Petersburg, FL
Hmmm. PM has been flying for me since making the change, but I was off working on Cigar Chronicles and found it to still be timing out. I think it needed a database refresh, which we did, and it's flying now too.
Perhaps the problem with CC was bogging down PM when you guy experienced the most recent problems.
So let's watch it for this point on, and let me know if anything takes more than 6 - 7 seconds to load. Thanks.

 

chopz

Senior Member
Oct 14, 2011
352
0
if i ever use the word "re-architected" in a sentence please someone shoot me for terminal douchebaggery.

 

admin

Smoking a Pipe Right Now
Staff member
Nov 16, 2008
7,982
349
St. Petersburg, FL
I'm going offline for the next 12 hours or so.
If the site breaks down while I'm away, please feel free to do me a favor and go here:
https://www.rackco.com/support.php
Enter your name in the chat box and tell them:
pipesmagazine.com is down, or slow, or hanging, whatever the case may be.
If you want to help with this, make a copy of this offline, as when the site is down, you obviously won't be able to see this.

 
Status
Not open for further replies.