6 ms·
I'm surprised people use vert.x -- I thought nodejs "won" the love of the hivemind
by niggler 14y ago
I'm surprised people use vert.x -- I thought nodejs "won" the love of the hivemind
- scanr 14y agoI think vert.x looks pretty cool and was just about to try it out before this. I'm doing some work that requires a neat Java based NIO web server. I've done a lot of work on top of Netty directly but vert.x looks like a nice higher level abstraction (e.g. routing etc.). nodejs is great but having the JVM and it's vast set of libraries is pretty compelling.
- pootch 14y agoYeah and that 8GB max heap (due to GC pauses) of the JVM is to DIE FOR~
- andrewvc 14y agoWell, that's the beauty of OSS, the work isn't lost, it just may need to be forked.
- jbooth 14y agoI'd respectfully suggest that what you actually need is a java-based performant web server, whether that's NIO or a threadpool and accept loop.
- scanr 14y agoThat may well be the case. I haven't benchmarked regular IO vs. NIO recently. Certainly when I did before, there wasn't too much in it but I did get more reliable latency from NIO and the rest of the stack is non-blocking so it's a neat fit. In theory NIO scales better than regular IO for the 100,000 connections case but that's not one that I need in my particular scenario.
- spullara 14y agoTry webbit.
- koko775 14y agoConsider Finagle (from Twitter), perhaps?
- trimbo 14y agoNot sure why you were downvoted, you bring up a good point that should be explained. Vert.x is "polyglot" (i.e. write in various JVM languages) and multi-threaded, even clustered, easily. For people who are building services and care about these things, it's a boon. Our team has been planning to use Vert.x for future services, but this development certainly raises concerns. I understand it can be forked, but I would rather see the two companies working together rather than battling it out.
- justincormack 14y agoI downvoted because software doesnt "win" it is an ongoing process, and vertx had unique differences and advantages which are useful for some people. The idea that node.js just "won" and nothing else is used is basically just bogus.
- niggler 14y agoIt "won" in the same way that Facebook "won". Yes, there are other platforms, but node definitely captured a much larger portion of the mindshare of developers.
- rdtsc 14y agoMaybe nodejs won the love of a lot of kids that know how to program in Javascript. Maybe it didn't win the love of seasoned C++, Java, and Erlang programmers. Sometimes blog exposure and cool sites and presentations don't necessarily equal serious real world usage.
- niggler 14y agoI recommend you take some time and look at the libuv and node code -- it's a pretty minimal layer sitting atop v8 (a high-performance javascript engine that is used in google chrome) that is reasonably well-designed and suited for (and, incidentally, actually used in) real world applications. Many real companies leverage node; on the other hand, I haven't heard of a company outside of vmware using vert.x. After my initial comment, I revisited vert.x and found its performance leaving much to be desired: even the simplest javascript arithmetic exercises are nearly two orders of magnitude faster in node compared to vert.x (try it for yourself using something like the gamma function: https://github.com/substack/gamma.js/blob/master/index.js https://github.com/substack/gamma.js/blob/master/index.js)
- rdtsc 14y ago> I recommend you take some time and look at the libuv and node code Alright I did. Conclusion: I like libuv and I don't like node, maybe because I don't like nested callbacks and I don't like Javascript. > I haven't heard of a company outside of vmware using vert.x. Neither have I but it seems most serious back end servers are not written in node either. Is Amazon using node, what about Google? > even the simplest javascript arithmetic exercises are nearly two orders of magnitude faster in node compared to vert.x Not sure if arithmetic exercises on v8 show anything. If anything that is the probably the wrong to benchmark unless node is supposed to be used for scientific calculations.
- niggler 14y ago> maybe because I don't like nested callbacks and I don't like Javascript. I'm an assembly hacker, but recently found that JavaScript really improved over the past five years (I suspect, to a great extent, because of v8). The newer ES5 and proposed ES6 standards add a bunch of features geared toward raw data manipulation (like Buffers and Views -- one way to implement contiguous blocks of memory). As for callback hell, there are tools to help you out. There are node modules implementing fibers, and there are utilities like async.waterfall (https://github.com/caolan/async https://github.com/caolan/async) that flatten the callback pyramid. > most serious back end servers are not written in node either. Define "serious back end servers". Most architectures involve a plethora of software servers (we have passed the age of a single apache server hosting requests years ago), and many companies use node in their stack (I remember seeing an HN post about how LinkedIn saw node.js performance far exceed their older ruby-on-rails platform) As for google and amazon, at that scale I'm sure they are using some custom server code (possibly in a proprietary language) on custom hardware. > Not sure if arithmetic exercises on v8 show anything. You can run a similar test using `ab` on custom servers, but the results are fairly inconclusive due to the fact that the dominating factor is the network stack (and not the event reactor model or implementation). Arithmetic benchmarks are a proxy to measure the distance to bare metal.