hellswraith
Feb 1st, 2004, 03:30 PM
Ok, I have to implement a system that is basically a messaging system. A admin will send a message, and the server is responsible for distributing out that message to sometimes over a thousand people at one time. That server must also get messages back from the client apps so it can time stamp responses, etc. The communications is going to be pretty simple messages, nothing like file transfers or anthing.
What I have started with has been a async socket example I have found on the net. I understand it well, but timing the sending of 1000 messages, and receiving 1000+ responses within 1 second is scaring me a little. I get 991 responses back right off the bat, and get 9 errors. This is pretty good. If I add in some error handling in the client side and enter a for loop to keep trying to send the response, I am getting all responses back.
Ok, this is all good at this point, but now here comes the kicker, I am going to have to save these messages in the database. I can solve all these problems with things like threading...
My question is, am I missing a simpler architecture? Should I look at something else before I go to far?
What I have started with has been a async socket example I have found on the net. I understand it well, but timing the sending of 1000 messages, and receiving 1000+ responses within 1 second is scaring me a little. I get 991 responses back right off the bat, and get 9 errors. This is pretty good. If I add in some error handling in the client side and enter a for loop to keep trying to send the response, I am getting all responses back.
Ok, this is all good at this point, but now here comes the kicker, I am going to have to save these messages in the database. I can solve all these problems with things like threading...
My question is, am I missing a simpler architecture? Should I look at something else before I go to far?