in reply to Re: Does Catalyst Borrow from Rails?
in thread Does Catalyst Borrow from Rails?

I would enjoy it if you elaborated on "did not do..." Which features did you see in RoR that the catalyst folks chose to skip? why do you think?

-Paul

Replies are listed 'Best First'.
Re^3: Does Catalyst Borrow from Rails?
by phaylon (Curate) on Feb 07, 2007 at 14:33 UTC
    I never really used Rails, but there were some discussions about that matter. And I don't mean "features" alone, but rather all design decisions in general. AFAIK Catalyst's dispatching is way more advanced than Rails routes (if my memory doesn't fool me and they call it that). The ActiveRecord vs. DBIx-Class discussions also bring up some points regularly. As said, I can't really provide details, because of my lack of knowledge about Rails. That's why I use a framework, I don't have to have the knowledge myself :) Well, that and I don't like Ruby's syntax, but that's rather personal.

    Ordinary morality is for ordinary people. -- Aleister Crowley
      Catalyst creates routes, just like Rails. It just does so through method decoration as opposed to a configuration mapping. There are excellent reasons to use both mechanisms and there is (was?) a project to bring Rails-style routes to both Catalyst and CGI::Application. (I think C::A now has routes, but I'm not sure about Catalyst.)

      The biggest benefit of routes, imho, is that you can see everything all at once. I've spent time trying to figure out why my Catalyst routing wasn't working. Catalyst also has a few hacks in how the routing is done in order to support all the different situations that have been thrown at it. Rails does, too - just different ones.

      To my mind, Catalyst truly is the best of both worlds - I have the power of CPAN married to the power of Rails.


      My criteria for good software:
      1. Does it work?
      2. Can someone else come in, make a change, and be reasonably certain no bugs were introduced?
        Catalyst creates routes, just like Rails.
        Could you elaborate on that? Maybe I didn't understand what routes are then. I am aware that all frameworks map resources to some kind of action, function or method, but the way they do this, as well as the flexibility, are what matters. Does Rails have a pendant to what Catalyst calls a Chained dispatch type? Does it have an equal potential as uri_for at his hand?
        I think C::A now has routes, but I'm not sure about Catalyst.
        I think you mean "Rails-style routes" here, because otherwise this would contradict your first statement.
        I've spent time trying to figure out why my Catalyst routing wasn't working.
        Again, no idea what "routing" means in Catalyst sense. You mean your actions weren't found under the locations you expected? I usually just check the debug output and see where my error was :)
        To my mind, Catalyst truly is the best of both worlds - I have the power of CPAN married to the power of Rails.
        I can understand that. Though for me, nothing in Rails really appeals to me. My design decisions (or environmental constraints) mostly don't conform to what DHH sees as the right way to do things. And my being more comfortable with Perl syntax than the Ruby one (they're not that different, but it's the small things) is one of the reasons I never really used Rails. Other than that: Full Ack, Catalyst is the best :)

        Ordinary morality is for ordinary people. -- Aleister Crowley