Ruby on Rails?

R

Remon van Vliet

John A. Bailo said:
Dr. Dobbs has a /glowing/ article on Ruby on Rails this month.

What do you guys think?

Can it replace .net, php and java?

And be the Open Source OOP web solution that is not bound to Sun or MS?

http://media.rubyonrails.org/presentations/pursuitofbeauty.pdf

I'll be the first to agree that the first few snippets in that PDF look
quite pretty. It's clean looking code of which you can easily predict what
it actually does (which i suppose is in line with Matz' philosophy). This
doesnt apply to the later examples for me though.

That said, i cant say i'm a huge fan of the language itself. I've actually
fiddled with Ruby for a few days a couple of weeks ago and there were just a
lot of language features that i find questionable or just "not nice". That
said, if it is an improvement it'll slowly but surely float to the top of
the most-used languages charts anyway. I'll spend some more time on it,
maybe i'll have to adjust my opinion after a more thorough/lengthy review of
Ruby ;)

As for Ruby on Rails, i dont think it will replace .NET / Java J2EE / PHP
any time soon.

- Remon
 
J

jmcgill

John said:
Dr. Dobbs has a /glowing/ article on Ruby on Rails this month.

What do you guys think?

I think the timing is none too subtle, with the Rails conference coming
up in Chcago next month. (I'm going.)
 
A

asj

John said:
Can it replace .net, php and java?

No. Hype passes unless it has widespread industry or popular backing.
Ruby has neither, although JRuby on Rails is being pushed in JavaOne
this week.

*Posted from Javaland using Opera Mini Java browser on a Nokia 9300.
 
J

jmcgill

John said:
Can it replace .net, php and java?

Can mustard replace ketchup, mayonnaise and soy sauce?

What forces you to think of this in the "dominance" frame, anyway?


Some people program web services in Rails because it is really easy and
it gets the job done well enough. There is a department in my company
that makes all of its services (internal business) in Rails. Every one
of the people in that group is an expert in Java/J2EE and is also a very
experienced C programmer, all with decades of experience. They are
doing web projects in Rails and nobody is complaining. In this world,
that's the bottom line.
 
D

Daniel Dyer

Dr. Dobbs has a /glowing/ article on Ruby on Rails this month.

What do you guys think?

Can it replace .net, php and java?

From what I've seen of Rails, it is most likely to catch on in the areas
where PHP and JavaEE (or .Net) overlap as viable alternatives for web apps
(the kind of smallish web apps that in Java tend to use just a bunch of
servlets or JSPs and a database). Rails will give you more structure than
PHP without the overhead of Java (in terms of verbosity and
configuration). I don't see Rails in its current incarnation threatening
the kind of high-end enterprise areas where Java is currently dominant.

Dan.
 
J

John Gagon

John said:
Dr. Dobbs has a /glowing/ article on Ruby on Rails this month.

What do you guys think?

Can it replace .net, php and java?

These three things are quite different in terms of the whole breadth of
the solution spaces they solve compared to RoR. PHP is about the
closest in terms of covering "the web". Java has other uses that RoR
does not address. Same with .NET iirc. No, I don't think it can replace
them then other than a share of each of them as far as their
involvement with web sites. Maybe I'm wrong and RoR is more but I
thought Ruby was more of the generic language and RoR was the
specialization/libraries for web site creation. As long as some people
out there have invested their mental energy and refused to become jacks
of all languages (there are a lot of language zealots out there), I
don't see RoR replacing or even dominating any time soon. It is a great
technology though. I would agree that the article rather does glow and
perhaps even glitters.
(http://en.wikipedia.org/wiki/Glittering_generalities)

And be the Open Source OOP web solution that is not bound to Sun or MS?

http://media.rubyonrails.org/presentations/pursuitofbeauty.pdf

Nice article. Does have some information that is new to perhaps quite a
few. Nicely presented.

John Gagon
 
O

Oliver Wong

Remon van Vliet said:
[the fact that you can easily predict what it actually does]
doesnt apply to the later examples for me though.

I even had trouble with the early examples.

<example>
class Account < ActiveRecord::Base
validates_presence_of :subdomain, :name, :email_address, :password
validates_uniqueness_of :subdomain
validates_acceptance_of :terms_of_service, :blush:n => :create
validates_confirmation_of :password, :email_address, :blush:n => :create
end
</example>

Okay, so as a human with an understanding of the semantics of the chosen
names, it looks to me like these validates_foo things describes the account.
The :foo stuff looks like it describes the validate_foo things coming right
before it. For example, ":password" is what ":validates_confirmation_of"
actually validates the confirmation of. and ":blush:n => :create" is when the
validation occurs (upon creation of the account, is my interpretation).

But then...

<example>
class Project < ActiveRecord::Base
belongs_to :portfolio
has_one :project_manager, :class_name => "Person"
has_many :milestones, :dependent => true
has_and_belongs_to_many :categories, :join_table "categorization"
</example>

Does ':class_name => "Person"' modify has_one? Or does it modify
:project_manager? If we're going for consistency, then this says to me that
the "class_name" of "has_one" is "Person". If we're going for common sense,
the programmer probably meant to say that project managers are people.

So is this an error in the code? Or is this correct Ruby code? I have no
idea.

<quote>
You can recognize truth by
its beauty and simplicity.
When you get it right, it is
obvious that it is right.

Richard Feynman, Scientist
</quote>

This wasn't at all obvious to me. What was also amusing to me was that
immediately after that quote, the first example given was:

<example>
Account.transaction(david, mary) do
david.withdrawal(100)
mary.deposit(100)
end
</example>

and this is a textbook example of how NOT to do a bank account transaction
system (threading issues, lack of check for sufficient funds, etc.).

- Oliver
 
T

Timo Stamm

asj said:
No. Hype passes unless it has widespread industry or popular backing.
Ruby has neither, although JRuby on Rails is being pushed in JavaOne
this week.

PHP had neither, and it is a de-facto standard today.
 
R

Remon van Vliet

asj said:
No. Hype passes unless it has widespread industry or popular backing.
Ruby has neither, although JRuby on Rails is being pushed in JavaOne
this week.

Is this true?? Why on earth would Sun be interested in pushing new hype
languages at a conference specifically focussed on Java? Or is it
specifically about JRuby rather than Ruby (on Rails)?
 
D

Daniel Dyer

It is? for what?

I wouldn't call it a standard, but PHP hosting is nearly ubiquitous.
Every cheap web host seems to offer PHP + MySQL pre-configured. Java
servlet/JSP hosting by contrast is much more expensive. If Ruby starts to
become as widely deployed as PHP, then Rails becomes a very attractive
choice for the kind of off-the-shelf web-apps that are currently the
domain of PHP (message boards, online communities, content management
systems, etc.).

Dan.
 
A

asj

Timo said:
PHP had neither, and it is a de-facto standard today.

PHP fulfilled a niche that was not there - cheap, easy, open source web
development - in that sense, it had built in pupular backing, and being
bundled with apache, the world's most popular web server didn't hurt
either. That's the niche that ruby is trying for, and PHP is already
there. Is Ruby bundled with anything? Are hosting services rushing to
use it? I've seen it in a very few, but not even close to how
ubiquitous PHP is.
 
T

Timo Stamm

Daniel said:
I wouldn't call it a standard,

From wikipedia.org:

| De facto is a Latin expression that means "in fact" or "in practice".
| It is commonly used in contrast to de jure (which means "by law") when
| referring to matters of law, governance, or technique (such as
| standards), that are found in the common experience as created or
| developed without or against a regulation.

Calling PHP on webservers a standard would be wrong because nobody ever
standardized it oficially. Calling it a "de-facto" standard is perfectly
valid, though.

but PHP hosting is nearly ubiquitous. [...]

Yes.


Timo
 
S

Stephan Eggermont

In comp.lang.java.programmer John A. Bailo said:
Dr. Dobbs has a /glowing/ article on Ruby on Rails this month.

What do you guys think?

Can it replace .net, php and java?

And be the Open Source OOP web solution that is not bound to Sun or MS?

No, the replacement will be seaside on squeak, or something similar.

Stephan
 
R

Robert Klemme

Timo said:
Ruby is actually quite similar to Smalltalk.

.... in certain areas. I'm not sure the claim would hold as a general
statement (too low Smalltalk knowledge here).

Kind regards

robert
 
S

Stephan Eggermont

In comp.lang.java.programmer Timo Stamm said:
Ruby is actually quite similar to Smalltalk.

It is a lot slower, has a weird syntax, and wee isn't as far
developed as seaside.

Stephan
 

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

Top