OSCon Day 1 Evening (or Ruby on "Rails")

So I went to the Ruby on Rails (did someone say [http://www.answers.com/main/ntquery?method=4&dsid=502&deid=196991922&gwp=8&curtab=502_1&linktext=Meaning%20%231 rail]?) talk in the afternoon. I had some issues with it. The first problem was that they didn’t provide any written documentation. When your learning about coding, getting some code is always a bonus. Especially when the presentation is just a guy sitting at the computer hacking code in a (hard to read) editor. Also his examples all used my$ql, I would have preferred to see postgresql, but was willing to overlook that, until we started talking about scaffolding. Scaffolding with regards to databases has some issues imo. The whole idea of the convention for primary key coumns all being named id is scary. I am actually a table_id kind of guy for two reasons, first dervied tables cant be built as (id id id), not that you would want to do this because then you would have three columns that were pretty much ambiguous. The counter to this, creating foreign keys named table_id, isnt that great either, because you then have pk does not equal fk names, which makes it tough to do things like work with the USING clause…. I guess the point is that if you set up a bunch of object->relational mapping, you don’t have to deal with things like the USING clause, but for “complex” stuff (where you need 5+ table joins). The speaker goes as far to say as much as the database should be nothing more than a dump data bucket… which I guess I would think so too if I was a my$ql guy and an application developer, much like he is. He also thinks that multiple applications hitting against your database is silly, which is a really narrow minded point of view, and one that scares me from the point of wanting to trust a system that this guy has built. For the record, I don’t think it is all doom and gloom, Robby has shown some [http://www.robbyonrails.com/articles/2005/07/25/the-legacy-of-databases-with-rails more advanced stuff] in his blog. Actually thats probably an important point. The speaker said that he thought rails was really good for doing greenfield development, but not so good for doing development against legacy systems (especially wrt database schemas). This seems fairly problematic since I would guess a big part of where you want uptake on your system is from people porting php/python/perl interfaces into ruby, who probably can’t change thier data model. (Or don’t want to, redesigning your data model is kind of a big barrier to entry IMO). However, since Robby seems to be actually using it in the context of having to deal with legacy systems, it makes me think his book will probably be better suited for those folks who arnt just trying to build there own blog system from scratch, but instead work on evolving systems or are extending system for unintended uses. (know anyone like that?) (Note I ran into Vivek Khera, who also attended, and reassured me that my thoughts on this were not insane) I think rails has the chops for this (for example, could you set up an after_destroy vacuum method?), it would be nice to see it pushed in this direction. OTOH, scaffolding as it relates to generally writing code seems handy, setting up a lot of the basic stuff your going to need, but I have to wonder if I feel that way because I am a database guy, so I tend to be more accepting of thing outside that realm. Outside of that, rails has a lot of good features, in the sense that it is a mature framework that has easy ways to do most of the things you need to do in web applications (sorting, passing data around, spitting our custom errors, handling post/get vars, writing unit test). The thing that strikes me about it is that it’s not so much that it is any better than other systems that delve into this stuff (smarty/mason/whathaveyou), but since ruby is still new, people who take it up are writing all thier code with it, making it a defacto standard, which makes it powerful compared to other systems which tend to be somewhat niche systems. A good corallary to this is something like [http://pecl.php.net/package/PDO PDO] in php. How long will it take for php users to swap to PDO ? Maybe never. But what if php3 had had PDO out of the gate? I bet everyone would be using it now. One thing that does stand out is that it has a lot of support for AJAX stuff built in, which makes it very easy to add whiz bang features into your web apps, something that seems lacking in php/perl/ado.net as far as i have seen. Hacking javascript by hand, especially across multiple DOM’s, is so much a pain, this is actually a killer feature. It doesn’t make it dead simple (the presenter ran into several errors showing us an example of the fade away blog comment deletions) but certainly makes it an order of magnitude simpler, and thats all you can ask for. Oh, the hot snack update… we now have lemonade, which is a bonus. Brownies are good to