Jump to content

  • Log In with Google      Sign In   
  • Create Account

Banner advertising on our site currently available from just $5!

1. Learn about the promo. 2. Sign up for GDNet+. 3. Set up your advert!


Member Since 21 Feb 2008
Offline Last Active Feb 20 2015 09:33 AM

Posts I've Made

In Topic: GonzoNet - high level library for large scale robust networking

01 January 2015 - 12:40 PM

So I rewrote GonzoNet and my servers to use BlockingCollection instead of ArrayList and ConcurrentDictionary instead of Dictionary.

However, I'm pretty sure I read on MSDN somewhere (I can't find the article right now) that I should be using BlockingCollection.GetConsumingEnumerable() when doing a foreach loop, because the standard foreach iterator will block threads.

So... how would I then readd items into the collection after I'm done consuming them?

Could I add them to a temp collection and replace the original one with the temp? Would that be safe?

In Topic: How2Ensure UDP-Packets reach target (high performance)?

10 December 2014 - 04:05 AM

If your per-packet data is small, another thing done in some games is to load onto each packet not just the current data, but piggyback the one previously sent data block (using sequence id's)  so that if some packets get dropped, the missing data is usually sent the next packet anyway in the normal stream --  that can eliminate alot of the resend delays  (AGAIN only if the per transmission packets are small because you would effectively be doubling your packet size and want to be well under your typical UDP MTU (frequently 512bytes)


Finally, I asked about packet size. He thinks the notion of a 512-byte optimal MTU is pretty much at least 5 years out of date. He sees almost no problems with a max packet size of 1400 bytes, and fragmentation just isn't an issue.

In Topic: GonzoNet - high level library for large scale robust networking

10 December 2014 - 04:01 AM

Josh Petrie, thanks for pointing out the license issues. I updated the headers for the files that were missing it, and sent a couple mails to the people who wrote the code for the ones where I deliberately didn't put a license.

If they don't reply, can I put in License.md that these files are NOT covered by the license?


As for your MMO question, Project Dollhouse is an MMO - or rather a remake of one. The userbase is such that the I'll probably never get above 1000 simultaneous players, but I'm absolutely confident that GonzoNet could handle more. I'm going to write a test case to prove that.

In Topic: GonzoNet - high level library for large scale robust networking

09 December 2014 - 10:59 AM

Lock-free queues are generally better where you can (safely) use them.

Perhaps I should ask the question another way:
- Why should I use your library instead of straight async sockets?
- Why should I use your library (or trust you) as opposed to some other library (and the author of that library.)
For example, for C#, the Lidgren library has been around quite a while, and has been hardened by being used for real in several existing games.

Note that I'm not questioning you -- I'm trying to help you formulate your market communications in a way that's clear!


1. Easy - because using straight async sockets means you're probably going to end up writing some kind of wrapper on your own anyway. I already did that! :)

2. GonzoNet has already been used in Project Dollhouse, which has 331,180 LOC (including GonzoNet) and been found to work quite nicely. However, I need to write more test cases to come up with more hard data!

PS: Thanks for guiding me onto lock free queues! :)

In Topic: GonzoNet - high level library for large scale robust networking

09 December 2014 - 10:14 AM

As for asynchronous IO, this library is written directly on top of .NETs asynch sockets.

I already stated that in the OP.