Jump to content
Sign in to follow this  
Brit

Server Throttling

Recommended Posts

My webhost sent me an email today saying that they temporarily (for one hour) disabled the database connected to the empires of steel game. They said there was excessive traffic and it was causing problems. So, if you weren't able to access the server earlier, that's why.

The traffic was related to PBEM games. I suspect that what might be happening is that someone has their game up and running all the time, checking for game updates every minute or so. Or maybe some players are running through the first few dozen turns of a PBEM game very quickly. Either way, I'll have to do something to slow down the amount of traffic players are using. And, remember that PBEM games aren't the only type of multiplayer games. The "regular" multiplayer game doesn't use the game's webserver.

Share this post


Link to post
Share on other sites

Oops. This happened again - my webhost temporarily suspended access to the empiresofsteel website. This time, my web-host says it's because of the PBEM game "Empire40-Mar7". I may have to take a look at this issue and/or upgrade my webhost account.

Edit: the "Empire40-Mar7" game doesn't seem to be taking that much bandwidth, it looks like maybe it was just the one that 'broke the camel's back'.

Edit #2: I think I've got this issue sorted out now. One of the PBEM functions was putting excessive strain on the server.

Share this post


Link to post
Share on other sites

Sorry about my PBEM game taking up your server Brit! That March 07 game is me and a buddy. But if there is another way to do PBEM, like do the turn and then email the turn to each other or something, we can do that too. Can you explain what you meant by "regular PBEM"?

Share this post


Link to post
Share on other sites

I originally thought maybe people were playing lots of turns in a row, and that was causing problems. I look a look at the events, and there were only about 200 game-events that day. I think the problem was caused by the excessive number of old events in the database (roughly 23,000 of them), causing the server to slow down. There is a part in the code that looks for duplicate events, which means looking through all the old events each time a new event is uploaded. I deleted a 85% of the old stuff, setup a system to automatically delete old events, and did some other stuff to speed things up, so hopefully it won't be a problem anymore. So, the biggest part of the problem was inefficient code on my side of things. I hope that fixes things, especially since my webhost is threatening to kick me off their server for excessive use.

> "Can you explain what you meant by "regular PBEM"?"

I mean regular multiplayer - which is the type of game where everyone is online at the same time.

Share this post


Link to post
Share on other sites
Sign in to follow this  

×
×
  • Create New...