jruby vs ruby

21 views
Skip to first unread message

Avi

unread,
Sep 21, 2012, 4:47:07 AM9/21/12
to rubyonra...@googlegroups.com
Hello,

Currently in my rails application, I am using ruby 1.9.3.  There is a requirement for which I need to use jruby.
If I am using jruby, then I can't use ruby.
Will there be any affect if I switch from ruby to jruby in my application ?
Will the rails application behave normally ?
Any code changes I need to do for that ?

Mauro

unread,
Sep 21, 2012, 6:53:10 AM9/21/12
to rubyonra...@googlegroups.com
Hi.
I use jruby in all my applications the advantage is that you can mix
java code if you want oherwise you can use pure ruby syntax.

avinash behera

unread,
Sep 21, 2012, 7:07:51 AM9/21/12
to rubyonra...@googlegroups.com
Will there be any affect on ruby code if we change from ruby to jruby ?


--
You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group.
To post to this group, send email to rubyonra...@googlegroups.com.
To unsubscribe from this group, send email to rubyonrails-ta...@googlegroups.com.



--
Thanks & Regards,
Avinash Behera
M-09538712979

Mauro

unread,
Sep 21, 2012, 7:16:01 AM9/21/12
to rubyonra...@googlegroups.com
On 21 September 2012 13:07, avinash behera <aavinas...@gmail.com> wrote:
> Will there be any affect on ruby code if we change from ruby to jruby ?

I think no, you have to control your gems, if you use jruby you have to add:

# the javascript engine for execjs gem
platforms :jruby do
group :assets do
gem 'therubyrhino'
end
end

Mauro

unread,
Sep 21, 2012, 7:27:34 AM9/21/12
to rubyonra...@googlegroups.com
To create a new app using jruby for rails 3:

jruby -S rails new myapp -m http://jruby.org/rails3.rb

avinash behera

unread,
Sep 21, 2012, 8:57:15 AM9/21/12
to rubyonra...@googlegroups.com
Thanks.

--
You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group.
To post to this group, send email to rubyonra...@googlegroups.com.
To unsubscribe from this group, send email to rubyonrails-ta...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.


Reply all
Reply to author
Forward
0 new messages