I have a fairly simple program with a single HTTP GET call to a Node.js webserver that returns the entirety of its underlying Mongo database. This query returns a good bit of data, with a JSON array response of ~460,000 entities.
When running the application in Visual Studio .Net 4.0, the query takes approximately 15-20 seconds. However when running in Mono (checked with versions 2.10.1, 3.0.0, 3.4.0, 3.6.0, and 4.0.3) in multiple different environments, the query takes at least an order of magnitude longer. Using Wireshark to look at network traffic showed a massive amount of TCP Window Update and TCP ZeroWindow packets when running the app in Mono, exactly zero of these packets when running natively in .Net. So I suspect Mono's TCP receiver has some sort of buffer issues but honestly I don't know. I've tried changing the DefaultStreamBufferSize under System.Runtime.Remoting.Channels.Tcp.TcpMessageIO.cs from 1000 byte array to 8192, but saw no improvement in performance. A user yesterday suggested checking if it was a compression issue, but the webserver is not compressing the http packets at all so that can't be the problem. Any suggestions on what could be the issue here? It's some sort of scaling issue. Here's some timing numbers based on number of returned entries: Mono Run: Returned Entries | Time 10k | .5s 100k | 5.8s 200k | 19s 300k | 45s 400k | 79s .Net Run: 10k | .4s 100k | 3.5s 200k | 6.6s 300k | 9.8s 400k | 12.9s As you can see, .Net scales linearly with increasing return count, whereas Mono has some scaling problems the more data is returned. -- View this message in context: http://mono.1490590.n4.nabble.com/Large-HTTP-GET-request-issues-with-mono-tp4666378.html Sent from the Mono - General mailing list archive at Nabble.com. _______________________________________________ Mono-list maillist - [email protected] http://lists.ximian.com/mailman/listinfo/mono-list
