Monthly Archives: June 2006

Sex, Drugs, and Rock n’ Roll (and Laszlo on Rails) w/Mike Pence

Mike Pence, self-employed (and sometimes self-unemployed) professional web surfer delivered “Sex, Drugs, and Rock n’ Roll (and Laszlo on Rails)” this morning at RailsConf.

The talk began with the “Where are we headed?” question. Users are expecting a much more interactive, responsive, and good looking interface than they were even just a few years ago. Flash (and now alternatively DHTML) based Laszlo provides all the graphics support – prototype based tools, in a constraint based – inheritance enabled API, that you need to create your site.

Mike answered the anti-Flash portion of the audience with “Don’t hate the player, hate the game”. Loosely translated: Don’t hate Flash because some people abuse it. It can be a powerful tool and is widely distributed/available throughout the browser-user community. As I had quickly mentioned earlier, a DHTML engine has recently become available for Laszlo as well. The demo Mike gave (LZ Pics) illustrated a responsive Laszlo app leveraging the DHTML backend.

Much of the talk centered around demos available at openlaszlo.com. Check out that site for plenty of cool demos and illustrations (especially Laszlo in 10 Minutes, if you’re new).

The actual intersection of Laszlo/Rails was not covered in a whole lot of depth, but more info can be found here and here.

And more on the thought that went into developing this specific talk here.

2 Comments

Filed under ajax, rails

RailsConf – Day 2

Another great day in Chicago. It's kind of a catch-22: the content is great and there's always something going I want to see… but 12 hour days of sitting and listening are more than I can take!

There were two sessions today that I really enjoyed. The "Ajax On Rails" presentation, with full post from me today – so you can check that out there. The other was "Testing Migrations" with Glenn Vanderburg. While he (admittedly) didn't have all the answers, he shared some incites regarding his experience setting up these tests. Among other things he really stressed the importance of testing your 'downward' migrations – instead of waiting to test them when you need them (when everything's going wrong and you can't afford for them to fail!). He did make the point that at the moment testing migrations is not the cleanest thing possible – and it may not be worth testing as thoroughly as you might elsewhere.

Last year I had a realization at a conference: We were listening to a keynote while the hotel staff was picking up dishes from the tables. I don't remember the joke or even who delivered it but I do remember thinking it was funny – and I guarantee you that it was incredibly nerdy – everyone had a good laugh… then I thought about it a second and realized just how dorky those servers must have thought we were (and how wrong were they? probably not very!). On that note, I give you: the joke of the day:

During the introduction to his session, Steven Hammond delivered the following… "I should mention that I am the manager of a team of Java developers. Which to this group pretty much makes me the equivalent of a Dark Sith Lord". I guarantee any hotel employee that heard that + the laugh that followed will be telling that story at the bar tonight.

The day ended with a keynote from DHH.  He reiterated that Rails is not intended to (and should not be intended to) be everything to everyone.  By not wandering too far from CRUD some surprisingly powerful thing have happened already and will continue to happen.  The primary illustration offered was tieing CRUD operations to HTTP in a more seamless fashion (i.e. if it's a get request, just do the read).

Probably the most notabable announcement was the introduction of ActiveResource.  ActiveResource is a response to the realization that not all applications are simply database backed.  Some will require MQ series, LDAP, and a multitude of countless others, I'm sure.

Leave a comment

Filed under rails

Ajax On Rails w/Justin Gehtland

Are we still at the point where a talk on ajax must start with the "What is ajax?" question? Well, at least the explanations seem to be getting shorter 🙂

Justin spent the majority of the presentation showing uncluttered examples of various Rails/Ajax/Prototype capabilities. Auto-complete search, drag-drop, and the like. These were delivered in a "if you haven't played with this yet" sort of way but he also managed to keep it quick enough – and drop in enough 'even if you've done this before you may not know about this' tidbits to keep the more experienced portion of the audience interested.

There was some talk on RJS and he spent some time on the always requested ajax topics… How do you deal with JavaScript disabled? What if a user has an old browser? How do you handle the introduction of new idioms?

The presentation ended with a bang as he demo'd creating an application with the soon to be released Streamlined. Streamlined is an open source framework, developed by Relevance LLC, to bring the simplicity of ActiveRecord to the view layer (coincidentally, this is #2 of the "3 Unsolved Problems" posed in Dave Thomas keynote yesterday). This is really slick – a lot of functionality – good looking (although they are looking for a designer to contribute some improvements) – and best of all: _very_ quick and powerful. I'm definitely looking forward to this being released at OSCON.

Leave a comment

Filed under ajax, rails, Ruby, Uncategorized

RailsConf – Day 1

Rob and I woke up early and made the trip to Chicago for RailsConf. The conference has the general feel of other Jay Zimmerman directed conferences I've attended.

Following a fairly brief welcome from Chad Fowler, Rich Kilmer and David Black (Ruby Central guys), Dave Thomas took the stage to deliver his keynote. The concept of the talk came from an address given at the International Congress of Mathmaticians in 1900, by David Hilbert. In that talk Hilbert outlined 23 Unsolved Problems in the field, basically providing an outline of what would be studied in the 20th century. For the sake of time constraints, Thomas was able to skim his list down to 3 Unsolved Problems:

  1. Data Integration
  2. Real World CRUD (aka. "Better Scaffolding"
  3. Deployment

My favorite (and certainly most memorable) session of the day was "AC/DC, Stravinsky, and Rails" with Adam Keys. I have to say, I never thought I'd hear AC/DC played on an accordian at a conference! The talk compared and contrasted the good and bad of each. AC/DC has the appeal of consistency; It's easy to follow, easy to play, and you just generally know what you're going to get. Stravinsky is on the other end of the spectrum (esp 'Rite Of Spring'); Beautiful in the complex details; Intentionally complex and difficult to play. Rails of course was cast somewhere in the middle. Capable of being beautifully simple while also being able to get down and dirty to handle a hairy problem.

The evening featured two great keynotes. The first was Martin Fowler discussing why Ruby works for him. I say "discussing" intentionally – his style was quite conversational and engaging. He began with the disclaimer that this may be the strangest keynote ever – He was talking at a RubyOnRails conference although he has never actually used Rails! Something tells me he knows more about it than he lets on 🙂 but the talk centered largely on Rails (at a high level) and Ruby itself. He discussed in depth Ruby/Rails ability to free the programmer from technical implementation plumbing, allowing them to concentrate their efforts on tackling real business problems.

To end out the night (for me… I didn't stick around for the band) was a keynote from Paul Graham on the pros and cons of being an industry "outsider". That is: the advantages Microsoft (today) has over some guy working in his garage – and conversely the advantages the guy in the garage has on Microsoft. Before getting into it he warned us: "I'm going to contradict both the New Testament and Yoda". As with his other talks, this was very entertaining and was a great close to the day.

Leave a comment

Filed under rails, Ruby

Nostalgia

I can tell you what I don’t miss about the Java -> Ruby switch…

Ruby:
4.days.ago

****

Java:
Start with java.util.Date, then use the java.util.DateFormat to… no, wait.

Um, I think you need a java.util.Calendar… so check out the API for java.util.GregorianCalendar and call the getInstance() method passing a java.util.TimeZone… no, that can’t be it.

Oh man, my head hurts: let’s just leave this at: “I don’t miss it”.

1 Comment

Filed under rails, Ruby

Remove A Shared Cookie

What's the worst part of making cookies? Cleaning up.

Initially, I had set up code to set a cookie in the simplest fashion possible:

cookies[:my_cookie] = {:value => 'test', :expires => 1.year.from_now}

Cleanup was a snap:

cookies.delete :my_cookie

That was working great but to add some usability we decided that we wanted the cookie to be shared between multiple sub domains on our site. This was simple as well, as we could just add a single arg to set the domain to something a bit more general:

cookies[:my_cookie] = {:domain => '.thedomain.com', :value => 'test', :expires => 1.year.from_now}

Awesome. Immediately, you can sign into foo.thedomain.com and bar.thedomain.com would know you as soon as you came in, instead of making you re-authenticate… but there seems to be an issue with the cleanup now. Looks like the explicit change in domain is causing a problem.

Not a big deal either… instead of using delete, I am just expiring the cookie now. This allows me to specify the domain while still accomplishing the goal of removing the cookie.

cookies[:my_cookie] = {:domain => '.thedomain.com', :expires => Time.now}

Leave a comment

Filed under Cookies, rails, Ruby