

From Java to Rails – what do I need to know? - bucma

I&#x27;m trying to make the move from corporate java development to Ruby on Rails development, and I&#x27;m trying to put together a list of things I need to learn.<p>For context, what I know &amp; don&#x27;t know already in that domain:<p>Know: ruby itself, a decent amount of html, some css, a tiny bit of javascript.  I&#x27;ve messed around a little bit with wicket &amp; spring on the java web dev side, although I&#x27;m more comfortable with swing and backend-y things.<p>Don&#x27;t really know: any advanced javascript or CSS tricks; Framework-style programming in general seems a bit awkward for me.<p>So- any good ideas of what I should be looking at beyond rails tutorials?<p>Thanks!
======
matt_s
Familiar shoes I've walked in. Build something more than the typical blog or
book inventory site you see referenced in tutorials. If you can't think of
something to build, then think of one of your corporate Java apps and build
that in Ruby/Rails from scratch. Or if you want a side project then pick
something and literally copy it in your own way. Like a photo sharing site or
whatever.

Things to include in your example app so you can learn the ins/outs of how
rails does it:

\- Nested models: comments on photos and how to organize the models, many to
many relationships

\- Rendering Partials: you can factor out pages into partials and essentially
load them anywhere in the app

\- Gems ecosystem: check out rubytoolbox (.com I think) for categories of
gems. These are like Java JAR files you can include via Maven. The popularity
and activity level are good ways to assess usefulness (outside of
requirements)

\- Host your own server: learn how Rails apps run on a server and different
options for running it. There are providers out there like Heroku where you
can just deploy to them but I think it is best to understand how these work.
You probably understand how Tomcat or other Java containers work, where to
look for log files, how it might interoperate with Apache HTTPD, etc.

------
haidrali
I have been working in both Rails and Java(Android). First one thing which
should be very clear to you is Java is a language and Rails is a framework
based upon Ruby language just like Spring/Hibernate.

Ruby standalone is nothing its power comes when you put Rails on top of it
while Java standalone still is powerful concurrent, class-based, object-
oriented language

Rails is immensely powerful framework developed keeping in mind every aspect
of web development with ever growing large open source community you might
need need to put all of your focus in mastering CSS/JavaScript ( yes you still
need these things while moving to Rails ) instead i would recommend you learn
Rails philosophy which is

-getting things done with minimal code and in a beautiful way using gems

I think above will be enough for you to start

Note: I have said you might not need to put all of your focus in mastering
CSS/JavaScript but these are just when you are starting JavaScript is FUTURE
really

~~~
lcedp
Do you program for both Java/Android and Ruby currently? I'm developing for
Android but also I'm generally like Ruby and I have an opportunity to get into
free Rails courses. Does it make much sense to know both things from the
career benefits point of view? Rails as a backend for Android app maybe? Or
should I just continue improving my Android skills

------
sethherr
I made a base rails app for a pattern I've been using recently.

It might be helpful to take a look at it and get it running? I think getting a
few apps running locally so that you have at least somewhere to start is
useful.

[https://news.ycombinator.com/item?id=9090818](https://news.ycombinator.com/item?id=9090818)

------
throwa
If you don't want to use only online tutorials and videos then look at
[http://training.wizebee.com/rails-course](http://training.wizebee.com/rails-
course), where you will a have someone teaching you what you need to know.

------
zephyr4434
You might want to look at coffeescript. If you like Ruby, you'd probably like
the coffeescript syntax for writing javascript, which should be helpful in web
app development. Rails has out-of-the-box support for .coffee files.

~~~
bzalasky
Along these lines, you could also check out Sprockets ES6
([https://github.com/josh/sprockets-es6](https://github.com/josh/sprockets-
es6)).

------
bucma
Thanks Everybody for the suggestions

