jruby in a pure java environment

T

Tony Arcieri

[Note: parts of this message were removed to make it a legal post.]

I'm curious about JRuby's adoption as a tool in pure Java places - has
anyone used it in places where all the shipping code had to be in
Java?


Initially we had a native dependency (Nokogiri) but given the environment
we're deploying in having to manually twiddle with symlinks to libxml and
libxslt was met with exasperated sighs.

We've switched to the native Java Nokogiri and now our app ships 100% free
of any native dependencies whatsoever. While a "pure Java" application was
never specifically a requirement for us, we chose to ship one anyway due to
the simplified deployment.

I look forward to the opportunities this offers us in other environments
(e.g. Amazon Elastic Beanstalk)
 
C

Charles Oliver Nutter

I'm curious about JRuby's adoption as a tool in pure Java places - has
anyone used it in places where all the shipping code had to be in
Java?

[asked on stackoverflow
http://stackoverflow.com/questions/4450488/using-jruby-as-a-tool-for-java-programming
but didn't get many answers]

I weary of stackoverflow. For some reason it seems like the myspace of
tech Q/A forums.

Anyway, about your question...

The biggest use case for JRuby by far is deploying a Ruby application
in a pure Java environment. Usually this takes the form of a Rails or
Sinatra app deployed on a Java server, where native dependencies are
completely disallowed. And for those of you struggling with native
dependencies: yes...you can run a Rails app on JRuby without a single
native gem, bundled up once and deployed on any platform without
rebuilding a thing. Ponder that for a moment :)

Of course the other use case is where people simply want to use a
particular Java library because it's the best or only solution for
their problem, or because they don't want to deal with native
dependencies again.

In general, most uses of JRuby are to take advantage of Java libraries
and the JVM...and I think that's where JRuby will continue to shine
for a long time.

Sure, JRuby's a really good Ruby implementation too, and you don't
have to know or touch Java to take advantage of it. And we'll continue
to improve that side of things into the future. But it's not usually
the primary motivating reason for people to use JRuby.

- Charlie
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
474,141
Messages
2,570,815
Members
47,361
Latest member
RogerDuabe

Latest Threads

Top