News for hackers. Stuff that matters.
Re:High Performance TCP Proxy Server by matthewaveryusa on Saturday April 22, 2017 @12:26PM (#14173240)
Again, this is a really cool 300 loc snippet. No need to pull in the jvm if you're going to do something simple.

As for performance, a reproducible benchmark is the minimum requirement to even start the conversation.

Re:High Performance TCP Proxy Server by eropple on Saturday April 22, 2017 @02:11PM (#14173804)
And yet by "pulling in the JVM" (which is a rounding error in 2017), it's remarkably easy to generate a proxy that actually works as people expect a TCP proxy to work. This doesn't even so much as wait for connections to drain before terminating. This "300-line snippet" (which is reliant on Asio, which is not 300 lines by any stretch) is, as near as I can tell, not viable in real-world conditions and the spirited defenses of it that put it as competitive with real-world, battle-tested solutions are profoundly weird.

(Similarly, because I don't really care about JVM versus not, HAProxy--which I'd probably use for something like this because I have better things to do with my programming time--is 90Kloc because it has stuff to do and does it right. Simple is only better if simple can actually get the job done.)

Re:High Performance TCP Proxy Server by tyingq on Saturday April 22, 2017 @12:41PM (#14173317)
Not sure if the 300 loc is really a fair comparison, as it is using ASIO (https://think-async.com/) under the covers, which is far more than 300 loc.