On Enterprise Ruby

Image and market share aside (although those are important
considerations), what real limitations does Ruby have for large
scale apps ?

  1. SOAP. This is a biggy. It’s the top of my list of “real
    hesitations before recommending Ruby”. Large apps need to talk to
    other apps. Often, this is via SOAP. Now, soap4r is buggy, poorly
    documented, and worse of all, has very incomplete WSDL support.

  2. Immaturity of Libraries. How many of the libraries that your
    project depends on have version numbers < 1.0? 'Nuff said.

And there’s also some serious cultural issues:

  1. Clever code. Kent Beck says that when he uses a clever trick, he
    feels bad, that’s he wasn’t capable of using a simple, well known
    solution. Yet I see a lot of Rubyists - esp. Railers - who seem to
    get a kick from programatically redefining a class or using
    method_missing to avoid a comma somewhere. Come back to that 3 years
    later, and good luck.

  2. Arrogance. All those “databases are stupid, referential integrity
    is for wimps, and CIOs should be fired” posts. Yuck! To me, the
    rampant arrogance, combined with immaturity, is the greatest long term
    risk to the health of Rails. Luckily, there’s been a lot of
    improvement here, with people recognizing that, yes, if you’re
    trusting your app with millions of dollars, you can’t deal with it
    like you do with your blog.

On 27 Mar 2007, at 16:43, Alexey V. wrote:

strategic
IT decisions, lots of money to throw at IT problems (much more than
a Web
2.0 startup), and a zoo of systems and applications, spanning the
last 25
years of the history of computing. Some of those applications need
to share
data and otherwise cooperate.

About right, I’d say, except that many / all of those application
need to share data in my experience (utilising every single approach
to sharing available: from shared file systems or registries, through
to DBs and IP protocols, and no doubt lots of in house stuff). You’ve
also got multiple businesses under one roof, all pulling in different
directions and all with their own political and technical agendas and
allegiances. And you’ve usually got some large and very poor code
bases, and almost all of an application’s lines will turn out to
interconnection glue when you look at them.

:slight_smile: There are some interesting challenges here.

Cheers,
Benj

On Wed, 28 Mar 2007, S. Robert J. wrote:

  1. Immaturity of Libraries. How many of the libraries that your
    project depends on have version numbers < 1.0? 'Nuff said.

So, we’ll all just add 1.0 to existing version numbers, and then the
libraries will be mature.

  1. Clever code. Kent Beck says that when he uses a clever trick, he
    feels bad, that’s he wasn’t capable of using a simple, well known
    solution. Yet I see a lot of Rubyists - esp. Railers - who seem to
    get a kick from programatically redefining a class or using
    method_missing to avoid a comma somewhere. Come back to that 3 years
    later, and good luck.

Eh. There’s a HUGE difference between leveraging language features such
as open classes versus being clever just for the sake of being clever,
and
Ruby certainly doesn’t have a corner on that market, either.

  1. Arrogance. All those “databases are stupid, referential integrity
    is for wimps, and CIOs should be fired” posts. Yuck! To me, the
    rampant arrogance, combined with immaturity, is the greatest long term
    risk to the health of Rails. Luckily, there’s been a lot of

And, fortunately, there’s a lot more to Ruby than the Rails world, too.

Kirk H.

S. Robert J. wrote:

Image and market share aside (although those are important
considerations), what real limitations does Ruby have for large
scale apps ?

  1. SOAP. This is a biggy. It’s the top of my list of “real
    hesitations before recommending Ruby”. Large apps need to talk to
    other apps. Often, this is via SOAP. Now, soap4r is buggy, poorly
    documented, and worse of all, has very incomplete WSDL support.
    Who’s working on this?

On 3/27/07, S. Robert J. [email protected] wrote:

method_missing to avoid a comma somewhere. Come back to that 3 years
later, and good luck.

For the record, I hear that .NET version 3 is trying to implement open
classes, so on top of the responses already given, this is a completely
moot
point

  1. Arrogance. All those "databases are stupid, referential integrity

is for wimps, and CIOs should be fired" posts. Yuck! To me, the
rampant arrogance, combined with immaturity, is the greatest long term
risk to the health of Rails. Luckily, there’s been a lot of
improvement here, with people recognizing that, yes, if you’re
trusting your app with millions of dollars, you can’t deal with it
like you do with your blog.

databases are stupid? RI is for wimps? Please, oh please show me posts
that
say this! I would LOVE to talk to someone who seriously thinks this way!

What you probably saw, and heartily decided to misread was someone
saying
in a specific case that a database was stupid because it added too
much
complexity to a project.

As for arrogance, the only arrogance I see are people like you,
unfortunately. All you Java and C# people who have this odd fetish of
trying
to discredit and bash any language that is even slightly different and
for
some reason becoming popular. Dynamic Typing?! OH NOES You can’t trust a
program without static typing! Open Classes! feignt. No, the arrogance
is
on your side, the people like you who are hurting this industry with a
complete inability to adapt to, learn, and develop new ideas.

We like to call ourselves Pragmatic. Look into it, and if you haven’t
yet,
go buy Pragmatic Programmer and read it over and over again. You just
may
learn something.

Tell me, have you even tried Ruby or Rails for more than a day? To be
honest, you’re not saying a single thing new that I haven’t seen on blog
posts or articles in the past 2 years of people who refuse to try Ruby
because it’s different, it’s new, and it’s going to complicate their
life
(how is of course never discussed, they are just so sure of it).

I’ll say again, Ruby is most definitely ready for prime time and has
been
for many years now. It’s people like you who are hampering the inclusion
of
this great language into the greater software world, mostly, I think,
because you people are afraid of change, deathly afraid. Well here’s a
news
flash: Software changes daily, and I really pity those people who have
missed out on this seemingly obvious fact.

Jason

On Wed, Mar 28, 2007 at 10:04:08PM +0900, Jason R. wrote:

later, and good luck.

For the record, I hear that .NET version 3 is trying to implement open
classes, so on top of the responses already given, this is a completely
moot point

There are several things wrong with that statement. First, plans for
.NET
have nothing to do with the relative merits of open classes, though I’d
be
interested in reading about what is being planned concerning open
classes
in .NET if you have a citation. Second, the issue is not open classes
themselves, which can be used effectively and appropriately, but as an
example (along with method_missing) of features that are often misused
in
the name of cleverness and at the expense of maintainability.

way!
http://www.loudthinking.com/arc/000516.html

It’s a post by DHH, primary author of the “opinionated” Rails code. Like
it
or not, he is a mover and shaker in the Ruby world and in this article
he
says, “…I consider stored procedures and constraints vile and reckless
destroyers of coherence.”

What you probably saw, and heartily decided to misread was someone saying
in a specific case that a database was stupid because it added too much
complexity to a project.

The post I refer to above is based on the naive assumption that there is
such a thing as an “application database” that is distinct from an
“integration database.” Anyone who has worked in any enterprise (defined
as
a company whose core business is not software but has custom software
needs) knows that every database is an integration database. There will
eventually be a need for multiple applications to interact with the
data.

The common response is that the application for which the database is
its
“application database” is responsible for providing access to the data
to
other applications via web services. This is a reinvention of the wheel,
not to mention an unnecessary layer of abstraction. RDBMSs have been
successfully, effectively, and efficiently supporting various
authentication and permission models for decades, not to mention
supporting
constraints to maintain data integrity. It is foolish, not to mention
arrogant, to propose writing new, unproven code to implement what
already
exists and works well.

As for arrogance, the only arrogance I see are people like you,
unfortunately. All you Java and C# people who have this odd fetish of
trying to discredit and bash any language that is even slightly different
and for some reason becoming popular. Dynamic Typing?! OH NOES You can’t
trust a program without static typing! Open Classes! feignt. No, the
arrogance is on your side, the people like you who are hurting this
industry with a complete inability to adapt to, learn, and develop new
ideas.

Wow, where did all that come from? Ruby is a great language, no
question.
It is the right tool for many jobs. It could be better, though, and it
could be the right tool for more jobs with some improvements. Most of
the
improvements I’ve seen suggested have to do with libraries (e.g. soap4r)
and coding discipline.

You aren’t likely to see many people on this list suggesting that it
needs
static typing, nor that open classes were inherently bad, nor even
saying
that it needs to be more like C# or Java at the language level. The
ability
to integrate with existing systems, however, requires a lot of library
code
that does exist in the Java and C# world and is missing, buggy, and/or
inefficient in the Ruby world. When these libraries exist in an
efficient
and dependable form enterprise adoption will be smoother and more
common.

We like to call ourselves Pragmatic. Look into it, and if you haven’t
yet, go buy Pragmatic Programmer and read it over and over again. You
just may learn something.

Tell me, have you even tried Ruby or Rails for more than a day? To be
honest, you’re not saying a single thing new that I haven’t seen on blog
posts or articles in the past 2 years of people who refuse to try Ruby
because it’s different, it’s new, and it’s going to complicate their life
(how is of course never discussed, they are just so sure of it).

Paragraphs like the two above go a long way toward explaining where
accusations of arrogance come from.

I’ll say again, Ruby is most definitely ready for prime time and has been
for many years now. It’s people like you who are hampering the inclusion
of this great language into the greater software world, mostly, I think,
because you people are afraid of change, deathly afraid. Well here’s a
news flash: Software changes daily, and I really pity those people who
have missed out on this seemingly obvious fact.

I’ve learned and used dozens of languages. I’ve even enjoyed many of
them,
including Ruby. I understand Ruby, JavaScript, C, C#, and C++ deeply (as
well as a few other mini-languages like awk and SQL). They each have
their
strengths and weaknesses which make them each the right tool for certain
kinds of jobs. There is, unsurprisingly, some overlap. I’ve made money
programming some of the languages I know, including Ruby. I am currently
employed developing a large Ruby on Rails site, though not really for an
“enterprise” by the definition I gave above.

At a previous job, however, I was working in VB.NET on a massive
internal,
mission-critical piece of software for a genuine “enterprise” using a
vast
database (both in schema and in number of rows) that was accessed by
multiple applications. Every DB interaction was through stored
procedures
for security and accountability reasons. They weren’t using any
constraints, but they should have been and the lack of constraints
resulted
in invalid and corrupt data that had to be detected and cleared manually
on
a regular basis. Though one of the applications was a web app, Ruby on
Rails would have been the wrong tool. In fact, there was no part of the
massive system that would have been well-served by Ruby. It required too
much integration with existing systems in ways that Ruby doesn’t do
well.
Someday, perhaps, Ruby will have the library support to make it the
right
tool, but not yet.

To be clear, I like Ruby and I think it is the right tool for a variety
of
profitable work, including what I am doing now. By the same token, I
think
that many of the problems that “enterprises” need to solve are
ill-served
by Ruby and its present ecosystem (e.g. library support). I also think
that
ecosystem can be improved, if we put in the time and effort to do so.

Jason
–Greg

http://www.loudthinking.com/arc/000516.html

It’s a post by DHH, primary author of the “opinionated” Rails code. Like
it
or not, he is a mover and shaker in the Ruby world and in this article he
says, “…I consider stored procedures and constraints vile and reckless
destroyers of coherence.”

For the record, I do agree mostly with this blog post. In terms of
quick
development, and mostly in testability, stored procedures are evil. I’ve
worked in a complex integrated Oracle environment before, I’ll just say
that
it’s something I will never, ever do again. Writing untestable code, of
any
kind, is the one thing I absolutely HATE to do.

That said, I don’t agree on the same stance for database referential
integrity. The database is in place to hold data and to make sure
relationships exist and are correct, and as such means have been put in
place (constraints, referential integrity) to help with this. I can very
easily see situations where multiple apps access the same database, so
yes,
the database needs to know something about relationships (and this stuff
can be tested).

However, if your Rails application is the only one who will be hitting
the
database, then constraints and RI can be used but are unnecessary.

Jason

However, if your Rails application is the only one who will
be hitting the database, then constraints and RI can be used
but are unnecessary.

I disagree; if nothing else, they act as sanity tests for ActiveRecord
and your domain objects.

  • donald

Wow, some excellent discussion has been generated. I’d like to
clarify a few things, from my point of view:

  1. I use Ruby extensively. I use Rails extensively. I’m using them
    currently for a large health care project. I’ve also used them
    previously in other projects. I think they’re great.

  2. The problems I’ve raised are problems that I’ve encountered, in my
    personal experience, with Ruby, and with Rails. I’m pained by the
    attitude that “Ruby (±Rails) is perfect, and pointing out any
    advantages of other platforms is heresy, subject to excommunication”.
    We need to be able to see our weaknesses in order to grow. Isolation
    brings stagnation.

  3. Library maturity. Some suggested that we could solve the maturity
    problem by raising the version numbers. I think that suggestion
    expresses the problem that I’m raising better than I ever could.

  4. Clever code: Please read what I wrote. Dynamic typing is
    wonderful. Open classes can be used for good or evil. But clever
    code is always bad. What’s the difference? If you use the power of
    the language to better convey the inherent patterns, that is good.
    But, if you violate expectations, possibly saving a line or two, but
    obscuring what’s happening underneath, that is bad. Some examples of
    the latter are abusive method_missing use, and gratutitous runtime
    redefinition of classes.

  5. Databases. I got two responses here.

  • Some saying “yes, referential intergrity is indeed worthless”. I
    doubt anyone saying this ever worked on a database that a) stores
    millions of records b) must last many years or c) has very little
    tolerance for failure. Believe me, eBay has developed their own
    database layer in Java, to handle massive scalability and
    parallelization. That’s not the same thing as just haphazardly
    throwing things into a “dumb, persistent hash”.

  • and some saying “no one ever said that”. To this, I not only offer
    the posts cited by others, but the responses to this thread itself. I
    will point out that there’s been a lot of community wide improvement
    here - a lot of ignorance has been overcome. DHH has certainly come
    around on this, and it’s to his credit.

Solutions?
Well, the cultural issues are the most dangerous - esp. the clever
code issue. But, as an individual, you’re not forced here.

I’d really, really, really like to see a decent soap4r - I’d even be
willing to sponsor. Ruby prides itself - rightfully so - on how
“there is no step 3”. Here’s one issue we’re the opposite is true.
Consuming a Web Service with a complex WSDL is child’s play in .NET,
but takes a lot of work to get right using soap4r. (Sometimes, I just
give up, and capture the XML off the wire, and template it!).

Perhaps JRuby will address these and library issues, but I think JRuby
is targeted more towards using Ruby to talk to Java, not enhancing
Ruby in its own right. Perhaps over time, as more people adopt Ruby,
all of these issues will be addressed more…

On 3/27/07, S. Robert J. [email protected] wrote:

Image and market share aside (although those are important
considerations), what real limitations does Ruby have for large
scale apps ?

  1. SOAP. This is a biggy. It’s the top of my list of “real
    hesitations before recommending Ruby”. Large apps need to talk to
    other apps. Often, this is via SOAP. Now, soap4r is buggy, poorly
    documented, and worse of all, has very incomplete WSDL support.

Tell me about a single library that has complete WSDL support. I’ve
been working with several Java libraries, .Net library, the customized
SAP Java library, and several other minor ones, and they all provide
some subset of WSDL spec and they all have interoperability problems.
soap4r has a very descent WSDL support as long as you don’t go beyond
rpc/encoded style.

  1. Immaturity of Libraries. How many of the libraries that your
    project depends on have version numbers < 1.0? 'Nuff said.

You don’t go too far with this attitude. I know several libraries with
version 0.x that have more features and less bugs than ones that carry
[1-9]+.x version tag.

And there’s also some serious cultural issues:

  1. Clever code. Kent Beck says that when he uses a clever trick, he
    feels bad, that’s he wasn’t capable of using a simple, well known
    solution. Yet I see a lot of Rubyists - esp. Railers - who seem to
    get a kick from programatically redefining a class or using
    method_missing to avoid a comma somewhere. Come back to that 3 years
    later, and good luck.

I’ve no problem with a clever code. I’ve problem with an obscure code.

  1. Arrogance. All those “databases are stupid, referential integrity
    is for wimps, and CIOs should be fired” posts. Yuck! To me, the
    rampant arrogance, combined with immaturity, is the greatest long term
    risk to the health of Rails. Luckily, there’s been a lot of
    improvement here, with people recognizing that, yes, if you’re
    trusting your app with millions of dollars, you can’t deal with it
    like you do with your blog.

Take ebay.com as an example. They use neither the referential
integrity nor the database’s transactional support. I guess from your
prospective this company is immature and arrogant.

On Mar 27, 2007, at 8:05 PM, S. Robert J. wrote:

  1. SOAP. This is a biggy. It’s the top of my list of “real
    hesitations before recommending Ruby”. Large apps need to talk to
    other apps. Often, this is via SOAP. Now, soap4r is buggy, poorly
    documented, and worse of all, has very incomplete WSDL support.

I have to agree on this one and it make me sad.

I’ve had to use this library three times in the last month and all
three have been insanely painful. It is easier to just capture a
well-formed request and fill it out as a template and this is tragic.

This has become the number one standard library I really want to see
redone.

  1. Immaturity of Libraries. How many of the libraries that your
    project depends on have version numbers < 1.0? 'Nuff said.

And then you lost all of my respect…

James Edward G. II

S. Robert J. wrote:

Perhaps JRuby will address these and library issues, but I think JRuby
is targeted more towards using Ruby to talk to Java, not enhancing
Ruby in its own right. Perhaps over time, as more people adopt Ruby,
all of these issues will be addressed more…

Au contraire…JRuby aims to be the best Ruby possible on the JVM. If
that ultimately means we solve some issues (threading, performance,
unicode, scaling) before/better than the C implementation, so be it. But
it will still be Ruby, and we intend to run all the same apps unmodified
(or as close to unmodified as possible).

  • Charlie

On Thu, 29 Mar 2007, Charles Oliver N. wrote:

unmodified as possible).
I think Robert was hinting toward the idea that once JRuby is “usable”
(however that might be defined) it will have access to Java’s mature
libraries, instead of using Ruby’s XML, SOAP, … (others?), which are
not
as far as Java’s.
*t

How much work is it to get to a good soap4r?

Aur

On Thu, 29 Mar 2007, SonOfLilit wrote:

How much work is it to get to a good soap4r?

Look at the code. Last time I was debuging it I didn’t stumble over a
single (!) line of comments - but maybe I wasn’t looking well enough, or
my memory might be flawed. Anyway - I gave up.

And if you want to hack on SOAP you better know the specs (in addition
to
the XML ones), which isn’t a small bite either.

So I guess my answer is: it’s not trivial.
*t

On 3/29/07, Tomas P.'s Mailing L. [email protected] wrote:

scaling) before/better than the C implementation, so be it. But it will still
be Ruby, and we intend to run all the same apps unmodified (or as close to
unmodified as possible).

I think Robert was hinting toward the idea that once JRuby is “usable”
(however that might be defined) it will have access to Java’s mature
libraries, instead of using Ruby’s XML, SOAP, … (others?), which are not
as far as Java’s.
*t

On JRuby ‘usability’: I was at a Spring (the Java DI framework)
conference
recently where Spring global transaction support (i.e. really difficult
to do,
even in Java, enterprisey stuff, go-to-jail-if-you-get-it-wrong etc.
etc.) got
dependency injected into Java code, and then bubbled up the call stack
to Ruby code running on top of it. All through JRuby.

Good enough for me.

Also consider that the Java library space is not a mature superset of
the
Ruby library space. Ruby brings a lot of interesting techniques to Java
developers. By using both you have increased the amount of tools
available to you.

OK, I’d like to ask about technology problems. Specific obstacles that
make
Ruby either less appealing, or not at all feasible on some corporate IT
projects.

So far, only messaging was mentioned on this thread.

The other thing people on ThoughtWorks Ruby projects complained about
was
continuous integration. CruiseControl.rb is our solution to that
problem.

We also hear some bitching about production deployment. I think with the
advent of Mongrel it’s much less of an issue, but it’s been a fast
moving
target over the last couple of years, and new people find it hard to
figure
out the current state of the art.

What else?

Tomas P.'s Mailing L. wrote:

I think Robert was hinting toward the idea that once JRuby is “usable”
(however that might be defined) it will have access to Java’s mature
libraries, instead of using Ruby’s XML, SOAP, … (others?), which are
not as far as Java’s.
*t

Sure, I understand that…and I agree with Richard that Ruby’s libraries
also bring a few gems to the table as well. I just intended to dispel
any rumor that JRuby was “just about bringing Ruby to Java”, since it is
also our goal to make as great a standalone Ruby as we can.

  • Charlie

Call me a reactionary, but if we all just agree to ignore them
they’re bound to go away eventually.

I think you’re right. This is really something the programming
language ecosystem will handle automagically. If you look at the main
programming languages used at all the hip Web 2.0 startups, they’re
using Lisp for user interface scripting and Smalltalk for their web
framework. The Smalltalk they’re using runs on Unix and sometimes
quacks like Perl, and the Lisp they’re using has this weird syntax
based on Java, but the long and the short of it is that quality wins.
Let the bloatware monkeys do what they want. It’s their money to lose.

I think even messaging has become less and less of a detriment.
Reliable Messaging from Assaf Arkin gives you a solid pure-Ruby option
and stomp gives you the ability to talk to ActiveMQ servers (and
there’s a new library that’s being worked on for the new fangled
messaging dealies from Java).

All in all, I think messaging is less of a detriment.

Though, soap4r has made me kill small animals before out of
frustration. That should probably be fixed, eh? Google SoC anyone
(even though it’s too late)? :wink:

–Jeremy

On 3/29/07, Alexey V. [email protected] wrote:

advent of Mongrel it’s much less of an issue, but it’s been a fast moving
target over the last couple of years, and new people find it hard to figure
out the current state of the art.

What else?


Alex Verkhovsky


http://www.jeremymcanally.com/

My free Ruby e-book:
http://www.humblelittlerubybook.com/book/

My blogs:

http://www.rubyinpractice.com/