Earlier quoted context omitted.
JRuby is fast for a Ruby implementation, but it's still far, far slower than Scala or Java itself. http://shootout.alioth.debian.org/u32/benchmark.php?test=all...
A lot of the pain a site like Twitter will have comes from GC (they wrote their own Ruby GC), and JRuby has a much better garbage collector over MRI and probably better than Twitter's.
Twitter: From Ruby on Rails to the JVM [video]
81–90 of 95 posts
Re: Twitter: From Ruby on Rails to the JVM [video]
#82Earlier quoted context omitted.
Yes, its not an ideal solution for the long term, but its something easy you can do to scale quickly if you have this architecture. It'll make sure your site stays up. Afterwards, you can spend the time doing it properly when things have calmed down a little. That's a lot easier than scaling something like Twitter.
No, sites go down all the time and need to rebooted, reconfigured, redeployed, strangled, etc. by a human who has to watch the servers 24 hours a day. I'm ignorant to the number of customers that Shopify is hosting these stores for, but let's say for example that one human can monitor 100 virtual machines during an eight-hour shift and you have 500 vm's running at the same time over a series of physical servers. That…
Let's run some numbers though, using your assumptions:
500 VMs @ $179 per customer (business class licence) means a little over $1,000,000. At that point, you'd be right---it wouldn't scale.
However, this is a business and not an HR exercise. So you could easily hire less people, and have less reliability. For a business like Shopify, I imagine their best customers are those who pay the $99 plan, accept a transaction cost, and other limitations. These customers can be piled onto the same VM together, and probably don't have such a huge throughput that a few minutes of downtime means money lost.
Re: Twitter: From Ruby on Rails to the JVM [video]
#83when you need many concurrent users then dont use ROR but use JVM or C++ or Scala instead,
if you need to build a fast prototype build on ROR or PHP etc.
Re: Twitter: From Ruby on Rails to the JVM [video]
#84Earlier quoted context omitted.
No, sites go down all the time and need to rebooted, reconfigured, redeployed, strangled, etc. by a human who has to watch the servers 24 hours a day. I'm ignorant to the number of customers that Shopify is hosting these stores for, but let's say for example that one human can monitor 100 virtual machines during an eight-hour shift and you have 500 vm's running at the same time over a series of physical servers. That…
I doubt that every single customer has to be on their own VM. It's more likely that many people share the same VM, and only larger customers need their own VM. Let's run some numbers though, using your assumptions: 500 VMs @ $179 per customer (business class licence) means a little over $1,000,000. At that point, you'd be right---it wouldn't scale. However, this is a business and not an HR exercise. So you could easi…
If your business has to be up and running 100% of the time, those are the minimal numbers needed to run the operation I've described. I cite a real word example, with real people and real money, the afterwards part if you will, which I'm currently working on to replace, not an hr exercise. And yes, it doesn't scale and it's very costly to replace, and one of the main reasons it was built in such a manner is because the original architect never thought it would have to scale and there are licensing considerations, something rarely mentioned around these parts. Licensing can really fuck things up.
Re: Twitter: From Ruby on Rails to the JVM [video]
#85With the release of Java 7 (invokedynamic) the performance of these dynamic languages (like ruby and python) may become much less of a factor (JRuby and Jython). At least that's what the JRuby folks imply: http://www.engineyard.com/blog/2011/jruby-1-6-released-now-w... Punch Line from Link: "There’s a very real chance that invokedynamic could improve JRuby performance many times, putting us on par with our statically…
http://anonscm.debian.org/viewvc/shootout/shootout/website/w...
Re: Twitter: From Ruby on Rails to the JVM [video]
#86Earlier quoted context omitted.
I do get that a dynamic language like Ruby will always be slower than a language like Java, which has primitives and where many things, including static method calls, are solved at compile time. But citing the Alioth.Debian benchmarks? Really? Dude, take a look at the source-code of those benchmarks sometimes -- they are completely useless ;)
They show the right order-of-magnitude differences. Taking them more seriously than that is a mistake.
Re: Twitter: From Ruby on Rails to the JVM [video]
#87Earlier quoted context omitted.
Surprised no other person brought this up.
Ontwik clearly provides some sort of service, if only to dredge up YouTube videos that we've otherwise missed.. but I can't help but feel there's a "better way" for these videos to be discovered than a site that just embeds and adds no editorial context.
Re: Twitter: From Ruby on Rails to the JVM [video]
#88Earlier quoted context omitted.
Until node gets some type of bind-fork-accept mechanism (built in) to utilize more than one cpu in a native and simple fashion (cluster/multi-node are close), I feel it will not gain the same level of traction that java has. People also have opinions about java(scala/clojure) vs javascript from a language preference standpoint. I think it is too early to tell what impact this will have. However, many developers I kno…
I noticed that the people who have a strong distaste for Java are largely application-developers. In most cases, these developers usually just work with the available libraries or APIs to build a website backed by database (some of them are consultants that build similar apps over and over again). Back-end developers seem to (maybe?) prefer to use Java.
People are still using C and C++ to write low level code. Databases, package managers, games, etc. Then there are the 'application developers' as you named them, writing http service endpoints, web apps, and the like.
It seems java still owns the colossal corporate stacks. I hear things like "it is easier to hire" and "java is faster/better for extreme large scale". If you think about all the languages and tools available, only the first makes much sense.
* C/C++/D is faster than java.
* statically compiled code is easier to deploy.
* Erlang is arguably more scalable than java.
* Haskel/Ada is 'safer' than java.
* I think several languages are more fun to write in than java. Ruby, python, golang, coffeescript, etc, etc.
So java may not be the best language for large scale, but maybe one of the best or good enough? When combined with the first point of ease of hiring, I can certainly see why large companies are attracted to it. If your language of choice lends itself to your workers being more easily replaceable, then as a company that is probably better/safer.
Other than that, I can't see why someone would prefer to use java. I don't work in/at/for huge companies though.
I admit that my own personal 'java bias' is based on dated interactions with java. Whenever I hear 'java' I think: good performance (vm), eats memory like candy, painful ecosystem of xml files and outdated/abandoned random libraries. I have tried dabbling in scala, and while I enjoyed the language to a fair extent, I still found myself wrestling with the JVM and the ecosystem (library version incompatibilities, obscure compiler errors, namespace wrangling, etc).
Re: Twitter: From Ruby on Rails to the JVM [video]
#89Earlier quoted context omitted.
I noticed that the people who have a strong distaste for Java are largely application-developers. In most cases, these developers usually just work with the available libraries or APIs to build a website backed by database (some of them are consultants that build similar apps over and over again). Back-end developers seem to (maybe?) prefer to use Java.
I don't know if my anecdotal evidence bears this out, but I admit that it is just that...anecdotal. People are still using C and C++ to write low level code. Databases, package managers, games, etc. Then there are the 'application developers' as you named them, writing http service endpoints, web apps, and the like. It seems java still owns the colossal corporate stacks. I hear things like "it is easier to hire" and…
Re: Twitter: From Ruby on Rails to the JVM [video]
#90Earlier quoted context omitted.
I noticed that the people who have a strong distaste for Java are largely application-developers. In most cases, these developers usually just work with the available libraries or APIs to build a website backed by database (some of them are consultants that build similar apps over and over again). Back-end developers seem to (maybe?) prefer to use Java.
I don't know if my anecdotal evidence bears this out, but I admit that it is just that...anecdotal. People are still using C and C++ to write low level code. Databases, package managers, games, etc. Then there are the 'application developers' as you named them, writing http service endpoints, web apps, and the like. It seems java still owns the colossal corporate stacks. I hear things like "it is easier to hire" and…
I don't deny the reality that people are still writing C/C++ code in the field of embedded devices, games, something that requires fast performance with a very low memory usage. On the other hand, there are a few NoSQL solutions built using Java: HBase, Neo4J, Cassandra.
In some cases, JVM Hotspot optimizes code on-par with C/C++. I don't know much about D performance. If the speed improvement is not night-and-day for projects other than being mentioned above, and if writing readable code is much better in Java, I'm not sure if we should compare C/C++ vs Java. On the other hand, many people seem to come out and say that Ruby is _very_ slow. Is it heaven-and-earth slow?
There are advantages and disadvantages of compiled vs dynamic code when it comes to deployment. It all depends on the tools and ecosystem too sometime.
How is Erlang more scalable than Java? In what area? horizontal vs vertical scaling? developer's productivity (or team performance) scale? performance? speed? Erlang seems to excel in a niche area (in a positive speaking).
What about Haskell/Ada, how are they safer than Java? Do they have better type-systems? handles NULL better than Java? Bulletproof from developers? detect more bugs?
Keep in mind that Java ecosystems have grown and matured a lot since 2004. The tools and libraries are staggering. Most of your concerns are no longer relevant except "eats memory like candy" in most Java desktop apps. Having said that, have you heard about Java ME? that thing runs in mobile devices albeit a different distribution of JVM.
Outdated/abandoned random libraries seem to happen in our neighboring ecosystems: Ruby (and Rails).
I have to admit that sometime other languages are more "fun" to dabble with. I use Python and Ruby. I like Python because I don't have to argue when it comes to code-style. Pythonic (PEP-8) or GTFO. It's not that I hate innovation or artistic coders, it's just that I'm a discipline person. Best practices in most cases, pragmatics when needed, hacks when the world ends tomorrow.
Companies chose Java for varieties of reasons and yes, one of them is the available pool of talents. I'm sure we all have heard the old phrase "enterprise developers". Some of them are bad, while others are quite sharp when it comes to the typical enterprise stack. Some of them can design systems/libraries quite well. Spring Framework comes to mind. Google Guice, Google Guava, Android are next (yep, crazybob used to do EJB and enterprise Java stuff yet he's one of the sharpest Java dude I've known).
I noticed that some of the well-run enterprise systems do have a better infrastructure planning thus forcing people involved around it to know better when it comes to certain technology choices. I'm sure there are web startups out there that just keep on hacking PHP code and use MySQL without having plans for backups, recoveries, etc.
Of course these are anecdotal experiences of mine.