Is Rails the Right Choice?

We are a group of developers that are about to start a project and so
we are searching for the best tools and languages for the job. The
project is essentially a “server” web application that holds data in
XML, and answer to queries on that data through a REST interface, and
a “client” web application that queries the server’s data and displays
the results.
But we have some restrictions that we can’t do anything about (so
please don’t discuss these choices):

  1. We already have the URLs and XSDs for the REST interface, but the
    first are quite different from a correct REST implementation (no GET /
    person, but GET /getperson, and so on).
  2. The philosophy behind this project is “Use the XML technologies as
    much as possible”, so a major requirement is to not use a db at all
    (no berkeley db xml, please).

So the questions are:

  1. is ActiveResource flexible enough to allow us to customize URLs and
    XMLs for the REST interface, in the “server” and in the “client”?
  2. is possible to do a Rails application without db? Are there any ORM
    things that will do the same job for XML data instead? If not, is
    possible to do that for mere mortals (with xpath/dom/sax as the
    preferred ways)?
  3. is possible for RoR to validate the XML of every single REST query
    (input and output) using XSD?
  4. is possible to render views using xslt? or better render in xml,
    leaving the xslt work to the browser?

And the 10-million dollars question: is Rails the Right Choice for
that project? Is better suitable to write both the “server” and the
“client” in Rails, or do just one (the “client” I think) in Rails and
the “server” in another language/framework?
If it’s not the RIght Choice for anything (“server” and “client”),
there are any alternatives that will fit better for the job?

Sorry for the long post.
Thanks!

On Apr 24, 9:39 am, Carmine P. [email protected] wrote:

person, but GET /getperson, and so on).
2. The philosophy behind this project is “Use the XML technologies as
much as possible”, so a major requirement is to not use a db at all
(no berkeley db xml, please).

So the questions are:

  1. is ActiveResource flexible enough to allow us to customize URLs and
    XMLs for the REST interface, in the “server” and in the “client”?

you should be able to do this. you will have to do a little bit more
work (to change from the defaults to what you want) but i think it
would work (obviously talking in generalities here).

  1. is possible to do a Rails application without db? Are there any ORM
    things that will do the same job for XML data instead? If not, is
    possible to do that for mere mortals (with xpath/dom/sax as the
    preferred ways)?

You don’t have to have a database. There are a few projects like ROXML
which I suppose you could describe as an ORM for xml.
There are also specialised xml databases (eg mark logic, and i think
ibm’s db9 does this too)

  1. is possible for RoR to validate the XML of every single REST query
    (input and output) using XSD?

Nothing builtin, but i’m sure that you could write before/after
filters that would shove data through xmllint or libxml

  1. is possible to render views using xslt? or better render in xml,
    leaving the xslt work to the browser?

you can render xml views. many moons ago an app I worked on rendered
xml and used an after_filter to apply an xslt stylesheet to it (the
plan had initially been for client side xslt but apparently there were
browser compatibility issues)

Fred

On Apr 24, 4:39 am, Carmine P. [email protected] wrote:

  1. The philosophy behind this project is “Use the XML technologies as
    much as possible”, so a major requirement is to not use a db at all
    (no berkeley db xml, please).

I know that you said not to discuss it, but seriously, why on earth
would this be a requirement?

Your other requirements specify that you’ll be search this “XML-not-
DB” for data, possibly using parameters sent by the client. To me, it
sounds awfully similar to a… database. The only thing using XML for
storage will get you is buzzword-compliance, and slow results. Even
with a fast XPath parser, why throw away decades of effort to build
scalable, reliable databases?

Actually, I’m most amazed that you’re even allowed to consider Ruby.
I’d have guessed that any management system that specifies all the
URLs and imposes arbitrary restrictions would have specified an
implementation language as well. Like, say, COBOL '68 on VMS handling
EBCDIC…

–Matt J.

On Fri, Apr 24, 2009 at 4:39 AM, Carmine P. [email protected]
wrote:

  1. The philosophy behind this project is “Use the XML technologies as
    much as possible”, so a major requirement is to not use a db at all
    (no berkeley db xml, please).

I would check out Exists http://exist.sourceforge.net It should meet
your
requirements as an XML technology and is fully accessible through
RESTful
protocols.

Michael

Il giorno 26/apr/09, alle ore 17:53, Matt J. ha scritto:

I know that you said not to discuss it, but seriously, why on earth
would this be a requirement?

You’re right, but it’s a university project.