Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Should I be using Rails or Ruby for this website application? How?

I'm very new to web programming (or actually, very old to it, since the last time I messed with the web was HTML 1.1), but now need to deploy a web application quickly. It seems like every time I turn around, there's new acronyms and technologies to learn (JSON, XMLRPC, GWT, Javascript, Rails, etc).

Here's what my app must do:

  1. Given a username and password, authenticate (easy enough, everything does that, apparently).
  2. Allow the user to upload a large glob of data for processing.
  3. Process that data.
  4. Allow the user to download their processed data.

I've already got Java scripts and a database for handling the data. On one machine, I can run a series of command-line programs to process an incoming datablock and put the results back into a mysql database. That is already present and working.

I want to construct a web front-end to this task, using these existing and tested methods. I'm currently leaning to this approach:

  1. Have two machines, a database machine and a web server. That approach allows for later scalability, if necessary, but also requires that I can't assume that the programs that I use to access the data and manipulate it are locally stored.
  2. Use a Ruby DRb application to create a server and a client. The client would pass data to the server which would in turn call these applications.
  3. Use some other Ruby interface to interact with the DRb for the web frontend.

Here's my problem: it looks like most Ruby applications for the web automatically try to build some kind of local database. All the Rails tutorials I've found start with making your own database and interacting with that, which is exactly what I don't want to do.

Is Rails the right technology for me, or using Ruby DRb? Is there some other technology I should be exploring?

If Rails or Ruby is the Right Thing here, what should I be looking at? I already have the Programming Ruby book, and have used that for some of the backend stuff as well as getting basic DRb stuff working.

like image 741
mmr Avatar asked Jan 21 '10 19:01

mmr


People also ask

What is Ruby on Rails & why you should use it for your web application?

Ruby on Rails is used in all types of industries to build web apps and services. This includes applications like marketing websites, CMSs, eCommerce sites, and custom web applications. It's a popular web framework for startups because its ease of use makes for quick application development with small teams.

Is Ruby on Rails good for web development?

“Ruby on Rails is one of the most powerful and popular web development frameworks available, used by sites like Twitter, GitHub, Airbnb, and Hulu.

Is Ruby good for web apps?

If you plan to focus on building web applications, Ruby is popular and flexible. There is a very strong community built upon it and they are always on the bleeding edge of development. If you are interested in building web applications and would like to learn a language that's used more generally, try Python.

Why should I choose Ruby on Rails?

Some of the key factors which make companies choose Ruby on Rails are the gem of libraries, user-friendly code and well-controlled framework, cost-saving, offers frontend and backend solutions, uses MVC pattern and DRY that saves time and increases RoR developers' efficiency.


2 Answers

Sounds like Rails might be a bit heavyweight for your situation. Perhaps Sinatra might be a better fit? It's an ultra-lightweight framework: a hello world app might look something like:

require 'sinatra'
get '/' do
  "Hello World!"
end
like image 60
Mike Woodhouse Avatar answered Sep 23 '22 05:09

Mike Woodhouse


Rails is fine. You can have development and test databases on your local machine and the production database on a remote machine. It doesn't have to be the web server. Get a copy of Agile Web Development with Rails. It'll teach you all you need to know.

like image 32
Mick Avatar answered Sep 23 '22 05:09

Mick