开发者

Dynamic Languages on / off the Java JVM [closed]

As it currently stands, this question is not a good fit for our Q&A format. We expect answers to be supported by facts, references, or expertise, but this question will likely solicit debate, arguments, polling开发者_如何学运维, or extended discussion. If you feel that this question can be improved and possibly reopened, visit the help center for guidance. Closed 11 years ago.

I'm interested in learning a dynamic language after at least 10 years on the Java platform. There are two choices that I was considering. One, learning one such as Clojure / Groovy that ride on top of the Java JVM. Secondly, a language off the JVM, which would include Ruby / Rails or Erlang.

Having knowing alot about the Java side, I'd like to choose a JVM based solution, but considering an off the JVM solution.

My question is:

  • What advantages / disadvantages would I get by choosing a language off of the Java JVM?

One of my biggest pain points is deployment memory footprint. I'd like to have a solution that allows low memory consumption, because most cloud / ISP providers require high dollar for anything greater the 512 MB / server. I've been so used to using High Memory JVM's which just don't work well with my costs. Maybe this isn't a concern for using clojure or groovy, but I'd expect a high memory footprint since it's running on the JVM.

I've already started using Ruby / Rails lately and I've been impressed with it.


If you go off the JVM then you have a good tool you can use in the cases where the JVM is poorly suited, like command line utilities where JVM startup time is really annoying.

If you go with Clojure you get both, with the clojure compiler you can produce classes for the JVM and with the ClojureScript compiler you can produce javascript that will run on very nearly anything.

My personal and therefore unverifiable advice is to go with the option that will expand your programming mind cough clojure but I am personally rather biased.


You could try JRuby to support ruby on and off a JVM.

I wouldn't assume that using JVM means using lots of memory. This depends on how you use the JVM. Using a profiler and more compact data structures can minimise memory usage. You can look at using C++, but if you are not careful C++ can use more memory. (But not if you know what you are doing)

How much memory you use is more about how you develop your program than which language you use.


For a low footprint solution, you may wish to consider JavaScript coupled with the V8 JS engine and Node.js technology

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜