Sunday, June 1, 2008

MagLev, JRuby, And Rubinius: Who Will Win?

First off, I just want to point out that Giles "Muppetfucker" Bowkett blogged about MagLev in 2007.

Second, Charlie Nutter kinda misses the point:

First off, they demonstrated its distributed object database automatically synchronizing globally-reachable state across multiple VMs. It's an amazing new idea that the world has never really seen...

except that it isn't. This is based on existing OODB technology that Gemstone and others have been promoting for better than a decade. It's cool stuff, no doubt, but it's been available in Gemstone's Smalltalk product and in their Java product for years, and hasn't seen widespread adoption. Maybe it's on the rise, I really don't know. It's certainly cool, but it's certainly not new.

Obviously this is in fact a new thing for Rubyists.

But we can discard that as splitting hairs. The real problem is the sentence before that. What we have here, mainly, is overexposure to Silicon Valley bullshit. Gemstone doesn't need widespread adoption and probably isn't particularly interested in getting it. Gemstone makes cool shit to make money.

The particular flavor of Silicon Valley bullshit we're dealing with here is the idea that what matters is not the ecosystem but the dominant player. This bullshit stems from the most fundamental form of Silicon Valley bullshit of all, the idea that power matters more than money. Maybe in politics, but not in business.

Ironically Charlie's own project, JRuby, has itself been a victim of this very same bullshit. I've seen plenty of otherwise very sharp people sneer unthinkingly at JRuby, making implications that only an idiot would consider JRuby for any purpose when the world will soon have Rubinius - again ignoring the importance of the ecosystem and fixating on the useless question of who will be the dominant player. I even saw somebody in the IRC backchannel at RailsConf implying that Avi Bryant was an asshole and a traitor for putting his time into MagLev instead of contributing patches to Rubinius - as if Rubinius were no longer a project but a cause, and a one true cause at that.

(Of course that was before the MagLev talk. After the MagLev talk, the only thing people were saying about Avi Bryant was a thousand variations on "zomg maglev" and maybe one or two nostalgic refrains of "zomg seaside.")

The point of MagLev is not "we will own the entire planet" but "if you want some cool shit, we got some cool shit, and you can get it, if you pay for it." We're talking about business here - money, not power. The question of who will be the "dominant player" is so completely fucking irrelevant that Tim Bray probably has an opinion about it.

MagLev wouldn't be a serious business proposition if it weren't for Rubinius and JRuby - the Ruby community is already very comfortable with the idea of multiple Ruby implementations. But before this, when we had just a slightly smaller ecosystem, we also had extremely intelligent people wasting their time in unseemingly little "JRuby vs. Rubinius" pissing matches. Not only where these things unnecessary and divisive, they ignored the fact that JRuby gives you things that Rubinius can't, and vice versa. There is no excuse for that kind of bullshit any more. The lesson here is that if you're facing off against somebody to see who's got the bigger dick, you should look up in the sky every now and then just to make sure a dick the size of the Goodyear Blimp hasn't been hanging over your head the whole time.

The flipsides are true and many. For instance, facing off against somebody to see who's got the bigger dick is basically a silly thing to do. MagLev offers things that JRuby and Rubinius cannot, and vice versa. And Rubinius and JRuby become more viable as serious business propositions because of MagLev. They get better credibility, more competition, and ultimately more open source contributions as well.

Gemstone isn't an open source company. Although they're learning about it, they predate the open source movement and don't have a thoroughly steeped open source culture. Somebody in the back of the MagLev presentation yelled "speech or beer?" when the Gemstone guy Bob said there would be a free version. Bob wasn't immersed enough in the open source culture to even understand that question - and the person who yelled it had a very aggressive tone of voice. People who are old enough to remember that Microsoft tried to destroy Linux can still be very partisan about open source, and there were a lot of people muttering angrily about the fact that MagLev won't be open source, but the thing is, almost all of them were using MacBooks while they did it.

Apple harnesses open source but puts a spin on top, and it's that spin that you pay the big bucks for. MagLev is the same damn thing. Most of the muttering was not actual physical muttering but IRC muttering. Somebody pointed out to me afterwards how funny this was - I'm so outraged that this software isn't free, I'm going to go on IRC with my MacBook and type some furious words on these special, comfortable, elegantly designed Apple keys!

Like Apple, MagLev will very probably target a market segment which is willing to shell out extra bucks but smart enough to make sure they get what they pay for. That's good for open source Ruby implementations as well. Nobody's going to ask if Ruby is enterprise-ready when they see that it runs on the same rock-solid system which has powered a gigantor JP Morgan financial application for decades.

And nobody in their right minds is going to reinvent the wheel at Gemstone for MagLev - it's very likely you'll see Rubinus, JRuby, and RubySpec patches resulting from MagLev, because open source enriches the ecosystem. It seems highly likely that MagLev will be able to leverage Rubinius code, and they're already using RubySpec. Not only that, but the Smalltalk world already has an open source alternative to Gemstone, and if we in the Ruby world create one too, it'll probably leverage JRuby, or Rubinius, or both.

It's not about dominant players any more. It's about ecosystems.

When you enrich the ecosystem, everybody wins.