• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

node.js vs Java backend

 
Ranch Hand
Posts: 44
jQuery Spring Java
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hello,

What are the pros and cons of node.js when compared to a Java backend, such as Jetty? I am looking for something very high-level, e.g. "Use Java for data-intensive processing" or "Learning curve of asynchronous programming for Java developers is very steep". It would be valuable if the answer touched on performance, productivity, adoption and tooling of these two backend technologies.

Thanks,

Alec
 
Author
Posts: 15
5
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Alec Swan wrote:Hello,

What are the pros and cons of node.js when compared to a Java backend, such as Jetty? I am looking for something very high-level, e.g. "Use Java for data-intensive processing" or "Learning curve of asynchronous programming for Java developers is very steep". It would be valuable if the answer touched on performance, productivity, adoption and tooling of these two backend technologies.

Thanks,

Alec



Hi Alec,

My knowledge of Java isn't too in-depth, but I'll give this question a shot. A lot of Java frameworks rely, as far as I know, on threading for concurrency. This can be more expensive, in terms of CPU and memory usage, than using an event loop, like Node.js does. So if high concurrency is something you need, then you might want to avoid traditional Java web frameworks. However if you know Java, continuing to use Java may be the right thing to do. There's a project called Vert.x which employs the same event-driven strategy as Node.js to get high concurrency, but it can be programmed in Java (or JavaScript, Ruby, Groovy, and Python). Vert.x isn't Node.js compatible, though, so you won't be able to use Node.js modules. There's a new project, however, called Nodedyn (http://nodyn.io/) that aims for compatibility with Node.js, but runs using the JVM. This could end up being useful for folks with a lot of experience tuning the JVM.

Cheers,
Mike
 
Consider Paul's rocket mass heater.
reply
    Bookmark Topic Watch Topic
  • New Topic