Server Exception Handling

Started by
2 comments, last by SeiryuEnder 11 years, 5 months ago
Hi,

I'm currently researching exception handling, and will be implementing it on a heavily threaded game server in the near future.

Here is what I will need:

  • Safely unwind stack, high server stability
  • Low overhead
  • Works well in a highly threaded architecture

While I am researching and have used EH before, I haven't gotten very in-depth with it and am not yet very familiar with what happens under the hood. Are there any red flags I should know about, any good book references for this sort of thing, or any ideas about how I can more effectively implement EH rather than just toggling some /EH_ flags? I realize this thread is a bit open ended, the problem I suppose is that I don't yet know what questions I should be asking and hope to pick the brains of those more experienced with this sort of thing.

Thanks~!
Advertisement
Some questions -
What language are you using, what are you using exceptions for, what are you using threads for?

Some questions -
What language are you using, what are you using exceptions for, what are you using threads for?


The thread has a C++ tag, now theres just 2 questions left :)

o3o


what are you using exceptions for, what are you using threads for?


Sorry, didn't have much time last night.

Our server is using a thread pool, when we receive a network request we assign a thread to handle it. This can include sql queries, movement updates, game objectives, etc.

Ideally our exception handling will be as comprehensive as possible so as to quietly handle any soft hardware or database failures. At the very least it will be used to resolve external problems. It'd be nice to use asserts to fix any programming errors and EH to handle any external problems, however due to the nature of servers we prize stability over all else. An offline is 0% efficient, so we're willing to sacrifice some performance while we fix the broken things.

This topic is closed to new replies.

Advertisement